Merge pull request #729 from wtfrank/charting-submit
authorMarek Safar <marek.safar@gmail.com>
Tue, 13 Aug 2013 19:42:18 +0000 (12:42 -0700)
committerMarek Safar <marek.safar@gmail.com>
Tue, 13 Aug 2013 19:42:18 +0000 (12:42 -0700)
Continued implementation of Charting namespace

468 files changed:
configure.in [changed mode: 0644->0755]
eglib/src/giconv.c
eglib/src/gstring.c
libgc/alloc.c
libgc/obj_map.c
libgc/ptr_chck.c
mcs/build/gensources.sh
mcs/build/library.make
mcs/build/profiles/mobile_static.make [new file with mode: 0644]
mcs/build/profiles/monotouch.make
mcs/build/profiles/monotouch_runtime.make
mcs/build/rules.make
mcs/class/Facades/System.Linq.Expressions/TypeForwarders.cs
mcs/class/Makefile
mcs/class/Mono.Posix/Test/Mono.Unix/ReadlinkTest.cs
mcs/class/System.ComponentModel.Composition.4.5/Makefile
mcs/class/System.ComponentModel.Composition.4.5/src/ComponentModel/Microsoft/Internal/GenerationServices.cs
mcs/class/System.ComponentModel.Composition.4.5/src/ComponentModel/System/ComponentModel/Composition/MetadataViewGenerator.cs
mcs/class/System.ComponentModel.Composition.4.5/src/ComponentModel/System/ComponentModel/Composition/MetadataViewProvider.cs
mcs/class/System.ComponentModel.Composition.4.5/src/ComponentModel/System/ComponentModel/Composition/Primitives/ExportedDelegate.cs
mcs/class/System.ComponentModel.DataAnnotations/Makefile
mcs/class/System.ComponentModel.DataAnnotations/mobile_static_System.ComponentModel.DataAnnotations.dll.sources [new file with mode: 0644]
mcs/class/System.Core/Makefile
mcs/class/System.Core/System.IO.MemoryMappedFiles/MemoryMappedFile.cs
mcs/class/System.Core/System.Linq.Expressions/BinaryExpression.cs
mcs/class/System.Core/System.Linq.Expressions/ConditionalExpression.cs
mcs/class/System.Core/System.Linq.Expressions/ConstantExpression.cs
mcs/class/System.Core/System.Linq.Expressions/ElementInit.cs
mcs/class/System.Core/System.Linq.Expressions/Expression.cs
mcs/class/System.Core/System.Linq.Expressions/ExpressionVisitor.cs
mcs/class/System.Core/System.Linq.Expressions/Extensions.cs
mcs/class/System.Core/System.Linq.Expressions/LambdaExpression.cs
mcs/class/System.Core/System.Linq.Expressions/MemberAssignment.cs
mcs/class/System.Core/System.Linq.Expressions/MemberBinding.cs
mcs/class/System.Core/System.Linq.Expressions/MemberExpression.cs
mcs/class/System.Core/System.Linq.Expressions/MemberListBinding.cs
mcs/class/System.Core/System.Linq.Expressions/MemberMemberBinding.cs
mcs/class/System.Core/System.Linq.Expressions/MethodCallExpression.cs
mcs/class/System.Core/System.Linq.Expressions/NewArrayExpression.cs
mcs/class/System.Core/System.Linq.Expressions/NewExpression.cs
mcs/class/System.Core/System.Linq.Expressions/ParameterExpression.cs
mcs/class/System.Core/System.Linq.Expressions/TypeBinaryExpression.cs
mcs/class/System.Core/System.Linq.Expressions/UnaryExpression.cs
mcs/class/System.Core/System/TimeZoneInfo.AdjustmentRule.cs
mcs/class/System.Core/System/TimeZoneInfo.Android.cs
mcs/class/System.Core/System/TimeZoneInfo.TransitionTime.cs
mcs/class/System.Core/System/TimeZoneInfo.cs
mcs/class/System.Core/Test/System/TimeZoneInfo.AdjustmentRuleTest.cs
mcs/class/System.Core/Test/System/TimeZoneInfo.TransitionTimeTest.cs
mcs/class/System.Core/Test/System/TimeZoneInfoTest.cs
mcs/class/System.Core/mobile_static_System.Core.dll.sources [new file with mode: 0644]
mcs/class/System.Data.Services.Client/mobile_static_System.Data.Services.Client.dll.sources [new file with mode: 0644]
mcs/class/System.Data/Makefile
mcs/class/System.Data/System.Data.Common/DataContainer.cs
mcs/class/System.Data/System.Data/DataRowCollection.cs
mcs/class/System.Data/mobile_static_System.Data.dll.sources [new file with mode: 0644]
mcs/class/System.DirectoryServices.Protocols/Assembly/AssemblyInfo.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/AsqResponseControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/AuthType.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/BerConverter.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/CompareResponse.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/CrossDomainMoveControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DeleteResponse.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DereferenceAlias.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DereferenceConnectionCallback.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DirSyncRequestControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DirSyncResponseControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DirectoryAttributeModification.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DirectoryAttributeOperation.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DirectoryControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DirectoryIdentifier.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DirectoryNotificationControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DirectoryOperation.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DirectoryResponse.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DirectorySynchronizationOptions.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DomainScopeControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DsmlDirectoryIdentifier.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DsmlDocumentProcessing.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DsmlErrorProcessing.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DsmlErrorResponse.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/DsmlResponseOrder.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/ErrorResponseCategory.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/ExtendedDNControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/ExtendedDNFlag.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/ExtendedResponse.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/LazyCommitControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/LdapDirectoryIdentifier.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/LocatorFlags.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/ModifyDNResponse.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/ModifyResponse.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/PageResultRequestControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/PageResultResponseControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/PartialResultProcessing.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/PermissiveModifyControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/ReferralCallback.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/ReferralChasingOptions.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/ResultCode.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/SearchOption.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/SearchResultEntry.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/SearchResultReference.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/SearchScope.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/SecurityDescriptorFlagControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/SecurityMasks.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/SecurityProtocol.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/ShowDeletedControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/SortKey.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/SortRequestControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/SortResponseControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/TreeDeleteControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/VerifyNameControl.cs
mcs/class/System.DirectoryServices.Protocols/System.DirectoryServices.Protocols/VlvResponseControl.cs
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchema.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaClass.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaClassCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaProperty.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaPropertyCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySecurity.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectoryServerDownException.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySite.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteLink.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteLinkBridge.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteLinkCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySubnet.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySubnetCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ApplicationPartition.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ApplicationPartitionCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DirectoryContext.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DirectoryEntryConfiguration.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DirectoryServer.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DirectoryServerCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/Domain.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DomainCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DomainCollisionOptions.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DomainController.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DomainControllerCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/Forest.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustCollisionException.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustCollisionType.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustDomainInfoCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustDomainInformation.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustRelationshipCollision.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustRelationshipCollisionCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustRelationshipInformation.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/GlobalCatalog.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/GlobalCatalogCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlyActiveDirectorySchemaClassCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlyActiveDirectorySchemaPropertyCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlyDirectoryServerCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlySiteCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlySiteLinkBridgeCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlySiteLinkCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationConnection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationConnectionCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationCursor.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationCursorCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationFailure.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationFailureCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationNeighborCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationOperation.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationOperationCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationOperationInformation.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationSecurityLevel.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/SecurityMasks.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/SyncFromAllServersErrorInformation.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/SyncFromAllServersOperationException.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/SyncUpdateCallback.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TopLevelName.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TopLevelNameCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TopLevelNameCollisionOptions.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TrustRelationshipInformation.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TrustRelationshipInformationCollection.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices.dll.sources
mcs/class/System.DirectoryServices/System.DirectoryServices/ActiveDirectoryAccessRule.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/ActiveDirectoryAuditRule.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/ActiveDirectoryRights.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/ActiveDirectorySecurityInheritance.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/DirectoryServicesCOMException.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/DirectorySynchronization.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/DirectorySynchronizationOptions.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/DirectoryVirtualListView.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/DirectoryVirtualListViewContext.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/ExtendedDN.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/ExtendedRightAccessRule.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/ListChildrenAccessRule.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/PasswordEncodingMethod.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/PropertyAccess.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/PropertyAccessRule.cs [new file with mode: 0644]
mcs/class/System.DirectoryServices/System.DirectoryServices/PropertySetAccessRule.cs [new file with mode: 0644]
mcs/class/System.Interactive.Async/Assembly/AssemblyInfo.cs [new file with mode: 0644]
mcs/class/System.Interactive.Async/Makefile [new file with mode: 0644]
mcs/class/System.Interactive.Async/System.Interactive.Async.dll.sources [new file with mode: 0644]
mcs/class/System.Interactive.Async/more_build_args [new file with mode: 0644]
mcs/class/System.Interactive.Providers/Assembly/AssemblyInfo.cs [new file with mode: 0644]
mcs/class/System.Interactive.Providers/Makefile [new file with mode: 0644]
mcs/class/System.Interactive.Providers/System.Interactive.Providers.dll.sources [new file with mode: 0644]
mcs/class/System.Interactive.Providers/more_build_args [new file with mode: 0644]
mcs/class/System.Interactive/Assembly/AssemblyInfo.cs [new file with mode: 0644]
mcs/class/System.Interactive/Makefile [new file with mode: 0644]
mcs/class/System.Interactive/System.Interactive.dll.sources [new file with mode: 0644]
mcs/class/System.Interactive/more_build_args [new file with mode: 0644]
mcs/class/System.Net/Assembly/TypeForwarders.cs
mcs/class/System.Net/System.Net.dll.sources
mcs/class/System.Net/System.Net/DnsPermission.cs [deleted file]
mcs/class/System.Runtime.Serialization/mobile_static_System.Runtime.Serialization.dll.sources [new file with mode: 0644]
mcs/class/System.ServiceModel.Web/System.Runtime.Serialization.Json/TypeMap.cs
mcs/class/System.ServiceModel.Web/Test/System.Runtime.Serialization.Json/DataContractJsonSerializerTest.cs
mcs/class/System.ServiceModel.Web/mobile_static_System.ServiceModel.Web.dll.sources [new file with mode: 0644]
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeAnd.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeArgument.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeArgumentReference.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeArithmeticOperation.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeArrayItem.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeArrayLength.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeAssignment.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeBinaryComparison.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeBinaryOperation.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeBlock.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeBuilder.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeCast.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeClass.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeCustomAttribute.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeDecrement.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeEquals.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeExpression.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeFieldReference.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeFor.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeForeach.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeGenerationHelper.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeIf.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeIncrement.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeIs.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeItem.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeLiteral.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeMethod.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeMethodCall.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeModule.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeNew.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeNewArray.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeNotEquals.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeOr.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeProperty.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodePropertyReference.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeReturn.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeSelect.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeSelfIncrement.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeTryBlock.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeUnaryOperation.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeValueReference.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeVariableDeclaration.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeVariableReference.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeWhen.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeWhile.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/CodeWriter.cs
mcs/class/System.ServiceModel/Mono.CodeGeneration/Exp.cs
mcs/class/System.ServiceModel/System.ServiceModel.Description/ContractDescriptionGenerator.cs
mcs/class/System.ServiceModel/System.ServiceModel/ChannelFactory_1.cs
mcs/class/System.ServiceModel/System.ServiceModel/ClientProxyGenerator.cs
mcs/class/System.ServiceModel/System.ServiceModel/FaultException_1.cs
mcs/class/System.ServiceModel/mobile_static_System.ServiceModel.dll.sources [new file with mode: 0644]
mcs/class/System.Transactions/Makefile
mcs/class/System.Web.Services/Makefile
mcs/class/System.Web.Services/mobile_static_System.Web.Services.dll.sources [new file with mode: 0644]
mcs/class/System.XML/Mono.Xml.Schema/XsdValidatingReader.cs
mcs/class/System.XML/Mono.Xml.Xsl/XslStylesheet.cs
mcs/class/System.XML/System.Xml.Schema/BuiltInDatatype.cs
mcs/class/System.XML/System.Xml.Schema/XmlAtomicValue.cs
mcs/class/System.XML/System.Xml.Schema/XmlSchemaSet.cs
mcs/class/System.XML/System.Xml.Schema/XmlSchemaValidator.cs
mcs/class/System.XML/System.Xml.Serialization/MapCodeGenerator.cs
mcs/class/System.XML/System.Xml.Serialization/XmlSchemaImporter.cs
mcs/class/System.XML/System.Xml/XQueryConvert.cs
mcs/class/System.XML/System.Xml/XmlConvert.cs
mcs/class/System.XML/Test/System.Xml.Schema/XmlSchemaDatatypeTests.cs
mcs/class/System.XML/Test/System.Xml.Schema/XmlSchemaSetTests.cs
mcs/class/System.XML/Test/System.Xml.Schema/XmlSchemaValidatorTests.cs
mcs/class/System.XML/Test/System.Xml.Xsl/XslTransformTests.cs
mcs/class/System.XML/mobile_static_System.Xml.dll.sources [new file with mode: 0644]
mcs/class/System.Xml.Linq/System.Xml.Linq/XElement.cs
mcs/class/System.Xml.Linq/System.Xml.Linq/XNode.cs
mcs/class/System.Xml.Linq/System.Xml.Linq/XUtil.cs
mcs/class/System.Xml.Linq/Test/System.Xml.Linq/XElementTest.cs
mcs/class/System/Makefile
mcs/class/System/Microsoft.CSharp/CSharpCodeGenerator.cs
mcs/class/System/System.CodeDom/CodeNamespace.cs
mcs/class/System/System.Collections.ObjectModel/ObservableCollection.cs
mcs/class/System/System.IO.Compression/DeflateStream.cs
mcs/class/System/Test/Microsoft.CSharp/CodeGeneratorFromCompileUnitTest.cs
mcs/class/System/mobile_static_System.dll.sources [new file with mode: 0644]
mcs/class/WindowsBase/System.Collections.ObjectModel/ObservableCollection.cs
mcs/class/build-rx-dll-sources.sh
mcs/class/corlib/System.Reflection/Binder.cs
mcs/class/corlib/System.Security.Cryptography/RSACryptoServiceProvider.cs
mcs/class/corlib/System.Text/Decoder.cs
mcs/class/corlib/System.Threading/SynchronizationContext.cs
mcs/class/corlib/System/Console.cs
mcs/class/corlib/System/Guid.cs
mcs/class/corlib/System/Variant.cs
mcs/class/corlib/Test/System.Globalization/CultureInfoTest.cs
mcs/class/corlib/Test/System.Reflection/BinderTests.cs
mcs/class/corlib/Test/System.Security.Cryptography/RSACryptoServiceProviderTest.cs
mcs/class/corlib/mobile_static_corlib.dll.sources [new file with mode: 0644]
mcs/errors/cs0177-13.cs [new file with mode: 0644]
mcs/errors/cs0452-11.cs [new file with mode: 0644]
mcs/errors/cs1750-4.cs [new file with mode: 0644]
mcs/jay/jay.vcxproj
mcs/mcs/anonymous.cs
mcs/mcs/class.cs
mcs/mcs/codegen.cs
mcs/mcs/constant.cs
mcs/mcs/convert.cs
mcs/mcs/ecore.cs
mcs/mcs/generic.cs
mcs/mcs/import.cs
mcs/mcs/parameter.cs
mcs/mcs/statement.cs
mcs/mcs/typemanager.cs
mcs/mcs/typespec.cs
mcs/tests/gtest-592.cs [new file with mode: 0644]
mcs/tests/gtest-optional-28.cs [new file with mode: 0644]
mcs/tests/test-debug-11-ref.xml
mcs/tests/test-debug-28-ref.xml [new file with mode: 0644]
mcs/tests/test-debug-28.cs [new file with mode: 0644]
mcs/tests/test-partial-32.cs [new file with mode: 0644]
mcs/tests/ver-il-net_4_5.xml
mcs/tools/linker/Mono.Linker.Steps/BlacklistStep.cs
mcs/tools/linker/Mono.Linker.Steps/OutputStep.cs
mcs/tools/linker/Mono.Linker.Steps/SweepStep.cs
mcs/tools/linker/Mono.Linker/AssemblyAction.cs
mcs/tools/mdoc/Resources/monodoc-ecma.xsd
mcs/tools/tuner/Mono.Tuner/PreserveSoapHttpClients.cs
mono-core.spec.in
mono/dis/declsec.c [changed mode: 0644->0755]
mono/dis/dis-cil.c [changed mode: 0644->0755]
mono/dis/dump.c [changed mode: 0644->0755]
mono/dis/get.c [changed mode: 0644->0755]
mono/dis/util.c [changed mode: 0644->0755]
mono/dis/util.h [changed mode: 0644->0755]
mono/io-layer/io-layer.h [changed mode: 0644->0755]
mono/io-layer/messages.c
mono/metadata/appdomain.h
mono/metadata/assembly.c
mono/metadata/assembly.h
mono/metadata/cil-coff.h
mono/metadata/class-internals.h
mono/metadata/class.h
mono/metadata/cominterop.h
mono/metadata/console-win32.c
mono/metadata/debug-helpers.h
mono/metadata/debug-mono-symfile.h
mono/metadata/domain-internals.h
mono/metadata/environment.h
mono/metadata/exception.h
mono/metadata/gc-internal.h
mono/metadata/image.c
mono/metadata/image.h
mono/metadata/loader.h
mono/metadata/marshal.c
mono/metadata/marshal.h
mono/metadata/mempool.h
mono/metadata/metadata-internals.h
mono/metadata/metadata.h
mono/metadata/monitor.c
mono/metadata/monitor.h
mono/metadata/mono-config.h
mono/metadata/mono-debug-debugger.h
mono/metadata/mono-debug.h
mono/metadata/mono-gc.h
mono/metadata/mono-hash.h
mono/metadata/mono-mlist.h
mono/metadata/object-internals.h
mono/metadata/object.c
mono/metadata/object.h
mono/metadata/opcodes.h
mono/metadata/process.c [changed mode: 0644->0755]
mono/metadata/profiler.h
mono/metadata/reflection.h
mono/metadata/security-core-clr.h
mono/metadata/sgen-archdep.h [changed mode: 0644->0755]
mono/metadata/sgen-gc.c
mono/metadata/sgen-gc.h
mono/metadata/sgen-los.c
mono/metadata/sgen-marksweep.c [changed mode: 0644->0755]
mono/metadata/sgen-memory-governor.c
mono/metadata/sgen-os-posix.c
mono/metadata/sgen-os-win32.c [changed mode: 0644->0755]
mono/metadata/sgen-stw.c [changed mode: 0644->0755]
mono/metadata/threadpool.c
mono/metadata/threadpool.h
mono/metadata/threads-types.h
mono/metadata/threads.c [changed mode: 0644->0755]
mono/metadata/threads.h
mono/metadata/tpool-epoll.c
mono/metadata/tpool-kqueue.c
mono/metadata/tpool-poll.c
mono/metadata/verify.h
mono/mini/Makefile.am.in [changed mode: 0644->0755]
mono/mini/aot-compiler.c [changed mode: 0644->0755]
mono/mini/debug-mini.h
mono/mini/debugger-agent.c [changed mode: 0644->0755]
mono/mini/decompose.c
mono/mini/exceptions-amd64.c
mono/mini/exceptions-x86.c
mono/mini/gshared.cs
mono/mini/jit-icalls.c
mono/mini/jit-icalls.h
mono/mini/jit.h
mono/mini/main.c [changed mode: 0644->0755]
mono/mini/method-to-ir.c
mono/mini/mini-amd64.c
mono/mini/mini-gc.c [changed mode: 0644->0755]
mono/mini/mini-llvm.c
mono/mini/mini-s390x.h
mono/mini/mini-windows.c
mono/mini/mini-x86.c [changed mode: 0644->0755]
mono/mini/mini.c
mono/mini/mini.h
mono/tests/Makefile.am
mono/tests/bug-348522.2.cs [changed mode: 0644->0755]
mono/tests/bug-438454.cs [changed mode: 0644->0755]
mono/tests/debug-casts.cs [new file with mode: 0644]
mono/tests/finalizer-exception.cs
mono/tests/gc-descriptors/Makefile.am [changed mode: 0644->0755]
mono/tests/test-driver
mono/utils/dlmalloc.c
mono/utils/mono-codeman.h
mono/utils/mono-context.h [changed mode: 0644->0755]
mono/utils/mono-counters.h
mono/utils/mono-digest.h
mono/utils/mono-dl-fallback.h
mono/utils/mono-embed.h
mono/utils/mono-error.h
mono/utils/mono-hwcap-arm.c
mono/utils/mono-logger.h
mono/utils/mono-math.h
mono/utils/mono-membar.h
mono/utils/mono-mmap.h
mono/utils/mono-path.h
mono/utils/mono-poll.h
mono/utils/mono-proclib.c
mono/utils/mono-property-hash.h
mono/utils/mono-publib.h
mono/utils/mono-semaphore.h
mono/utils/mono-uri.h
mono/utils/monobitset.h
mono/utils/strenc.h
mono/utils/strtod.c
msvc/eglib.vcxproj
msvc/genmdesc.vcxproj
msvc/libgc.vcxproj
msvc/libmono.vcxproj
msvc/libmonoruntime.vcxproj
msvc/libmonoutils.vcxproj
msvc/libtest.vcxproj
msvc/mono.vcxproj
msvc/monodiet.vcxproj
msvc/monodis.vcxproj
msvc/monograph.vcxproj
msvc/monoposixhelper.vcxproj
msvc/pedump.vcxproj
msvc/profiler-codeanalyst.vcxproj
msvc/profiler-cov.vcxproj
msvc/profiler-logging.vcxproj
msvc/profiler-vtune.vcxproj
msvc/test-invoke.vcxproj
msvc/test-metadata.vcxproj
msvc/test_eglib.vcxproj
msvc/teste.vcxproj

old mode 100644 (file)
new mode 100755 (executable)
index f42ce96..6ff0a75
@@ -105,22 +105,6 @@ case "$host" in
                        if test "x$host" == "x$build" -a "x$host" == "x$target"; then
                                AC_DEFINE(TARGET_WIN32,1,[Target OS is Win32])
                        fi
-                       #
-                       # gcc-3/g++-3 are from the gcc-core/gcc-g++ cygwin packages.
-                       # Other gcc packages will not work:
-                       # - the gcc-4 packages no longer support -mno-cygwin
-                       # - the mingw-gcc packages produce executables which depends on a libgcc<...>
-                       # dll, which means we would have to distribute that file too.
-                       #
-                       if test "x$CC" != "x"; then
-                               AC_ERROR(Don't set CC. mono can only be compiled with gcc-3 from the 'gcc-core' package)
-                       fi
-                       CC="gcc-3.exe -mno-cygwin -g"
-                       CXX="g++-3.exe -mno-cygwin -g"
-                       # So libgc configure gets -mno-cygwin
-                       export CC
-                       export CXX
-                       CFLAGS_FOR_EGLIB="$CFLAGS_FOR_EGLIB -mno-cygwin"
                else
                        target_win32=yes
                        AC_DEFINE(TARGET_WIN32,1,[Target OS is Win32/MinGW])
@@ -491,6 +475,12 @@ AC_TRY_LINK([#include <math.h>], [
        # We'll have to use signals
        AC_MSG_RESULT(no)
 ])
+# mingw
+AC_CHECK_FUNCS(_finite, , AC_MSG_CHECKING(for _finite in math.h)
+       AC_TRY_LINK([#include <math.h>], 
+       [ _finite(0.0); ], 
+       AC_DEFINE(HAVE__FINITE, 1, [Have _finite in -lm]) AC_MSG_RESULT(yes),
+       AC_MSG_RESULT(no)))
 
 # for Linux statfs support
 AC_CHECK_HEADERS(linux/magic.h)
@@ -1585,6 +1575,10 @@ if test x$target_win32 = xno; then
                AC_MSG_RESULT(disabled)
        else
                AC_TRY_RUN([
+                       #ifdef __clang__
+                       #error "__thread does not currently work with clang"
+                       #endif
+                       
                        #include <pthread.h>
                        __thread int i;
                        static int res1, res2;
@@ -2492,7 +2486,7 @@ case "$host" in
                        have_visibility_hidden=no
                        sgen_supported=true
                        ;;
-                 cygwin*)
+                 mingw*|cygwin*)
                        sgen_supported=true
                        have_visibility_hidden=no                 
                        ;;
@@ -3280,7 +3274,7 @@ AM_CONDITIONAL(MIPS, test x$TARGET = xMIPS)
 AM_CONDITIONAL(POWERPC, test x$TARGET = xPOWERPC)
 AM_CONDITIONAL(POWERPC64, test x$TARGET = xPOWERPC64)
 AM_CONDITIONAL(ARM, test x$TARGET = xARM)
-AM_CONDITIONAL(S390X, test x$TARGET = xS390x)
+AM_CONDITIONAL(S390X, test x$TARGET = xS390X)
 AM_CONDITIONAL(HOST_X86, test x$HOST = xX86)
 AM_CONDITIONAL(HOST_AMD64, test x$HOST = xAMD64)
 AM_CONDITIONAL(HOST_ARM, test x$HOST = xARM)
index 9fe0edd3324fc1857cde28612bcc90b01aec8bfa..f70a417f5be0454c06dc6f63e39bd601cfa4923c 100644 (file)
@@ -174,14 +174,34 @@ gsize
 g_iconv (GIConv cd, gchar **inbytes, gsize *inbytesleft,
         gchar **outbytes, gsize *outbytesleft)
 {
-       size_t inleft, outleft;
+       gsize inleft, outleft;
        char *inptr, *outptr;
        gunichar c;
        int rc = 0;
        
 #ifdef HAVE_ICONV
-       if (cd->cd != (iconv_t) -1)
-               return iconv (cd->cd, inbytes, inbytesleft, outbytes, outbytesleft);
+       if (cd->cd != (iconv_t) -1) {
+               /* Note: gsize may have a different size than size_t, so we need to
+                  remap inbytesleft and outbytesleft to size_t's. */
+               size_t *outleftptr, *inleftptr;
+               size_t n_outleft, n_inleft;
+               
+               if (inbytesleft) {
+                       n_inleft = *inbytesleft;
+                       inleftptr = &n_inleft;
+               } else {
+                       inleftptr = NULL;
+               }
+               
+               if (outbytesleft) {
+                       n_outleft = *outbytesleft;
+                       outleftptr = &n_outleft;
+               } else {
+                       outleftptr = NULL;
+               }
+               
+               return iconv (cd->cd, inbytes, inleftptr, outbytes, outleftptr);
+       }
 #endif
        
        if (outbytes == NULL || outbytesleft == NULL) {
@@ -640,7 +660,7 @@ gchar *
 g_convert (const gchar *str, gssize len, const gchar *to_charset, const gchar *from_charset,
           gsize *bytes_read, gsize *bytes_written, GError **err)
 {
-       size_t outsize, outused, outleft, inleft, grow, rc;
+       gsize outsize, outused, outleft, inleft, grow, rc;
        char *result, *outbuf, *inbuf;
        gboolean flush = FALSE;
        gboolean done = FALSE;
@@ -676,7 +696,7 @@ g_convert (const gchar *str, gssize len, const gchar *to_charset, const gchar *f
                else
                        rc = g_iconv (cd, NULL, NULL, &outbuf, &outleft);
                
-               if (rc == (size_t) -1) {
+               if (rc == (gsize) -1) {
                        switch (errno) {
                        case E2BIG:
                                /* grow our result buffer */
index 9df5d73c28ef89a6bb83a7976cf88c1d97cfadf4..ba75789bc80788719d2e9ffaf972e835a88f6887 100644 (file)
@@ -235,9 +235,8 @@ g_string_truncate (GString *string, gsize len)
        g_return_val_if_fail (string != NULL, string);
 
        /* Silent return */
-       if (len < 0 || len >= string->len) {
+       if (len >= string->len)
                return string;
-       }
        
        string->len = len;
        string->str[len] = 0;
index 9ec6992352ad893b381dff712b37791359a183e8..b6bc1832c994da99c04ecbaa475200159c9103f4 100644 (file)
@@ -969,7 +969,7 @@ word n;
       }
 #   endif
     expansion_slop = WORDS_TO_BYTES(min_words_allocd()) + 4*MAXHINCR*HBLKSIZE;
-    if (GC_last_heap_addr == 0 && !((word)space & SIGNB)
+    if ((GC_last_heap_addr == 0 && !((word)space & SIGNB))
         || (GC_last_heap_addr != 0 && GC_last_heap_addr < (ptr_t)space)) {
         /* Assume the heap is growing up */
         GC_greatest_plausible_heap_addr =
index 39993451cc7107651810adccfa5f73747edab341..49f6add1553dcf2ea94d829a3b54a6498202783f 100644 (file)
@@ -22,7 +22,7 @@
 # include "private/gc_priv.h"
 
 map_entry_type * GC_invalid_map = 0;
-static max_valid_offset = 0;
+static word max_valid_offset = 0;
 
 /* Invalidate the object map associated with a block.  Free blocks     */
 /* are identified by invalid maps.                                     */
index d83d730d3433f5f29b2da36e1c97013869b92394..621a45f0346fead0739260b7866053d199ef76ff 100644 (file)
@@ -165,7 +165,7 @@ void (*GC_is_valid_displacement_print_proc) GC_PROTO((GC_PTR)) =
     pdispl = HBLKDISPL(p);
     map_entry = MAP_ENTRY((hhdr -> hb_map), pdispl);
     if (map_entry == OBJ_INVALID
-       || sz > MAXOBJBYTES && (ptr_t)p >= (ptr_t)h + sz) {
+       || (sz > MAXOBJBYTES && (ptr_t)p >= (ptr_t)h + sz)) {
        goto fail;
     }
     return(p);
index 153cba9f89214d0c4f10f88440cc337491d1488c..bc76b711d39879770af0f547f8186669c295c245 100644 (file)
@@ -4,6 +4,7 @@ outfile=$1
 incfile=$2
 excfile=$3
 extfile=$4
+extexcfile=$5
 
 process_includes_1() {
     sed -e '/^[ \t]*$/d' -e '/^[ \t]*#/d' $1 > $2
@@ -39,16 +40,24 @@ fi
 sort -u $outfile.inc > $outfile.inc_s
 rm -f $outfile.inc
 
-if test -z "$excfile"; then
-    mv $outfile.inc_s $outfile
-else
+
+if test -n "$excfile"; then
     process_includes $excfile $outfile.exc
+fi
 
-    sort -u $outfile.exc > $outfile.exc_s
-    rm -f $outfile.exc
+if test -n "$extexcfile"; then
+    process_includes $extexcfile $outfile.ext_exc
+       cat $outfile.ext_exc >> $outfile.exc
+       rm -f $outfile.ext_exc
+fi
 
+if test -f $outfile.exc; then
+       sort -u $outfile.exc > $outfile.exc_s
+       rm -f $outfile.exc
     sort -m $outfile.inc_s $outfile.exc_s | uniq -u > $outfile
     rm -f $outfile.inc_s $outfile.exc_s
+else
+       mv $outfile.inc_s $outfile
 fi
 
 
index 8c43d43d62c7f98804ae3ff663b560380a534883..fdd94d023f316a4b56d93dc229d2641a7e75a2cd 100644 (file)
@@ -23,11 +23,18 @@ else
 EXTENSION_include = $(wildcard $(PROFILE)_opt_$(LIBRARY).sources)
 endif
 
+
+ifdef EXTENSION_MODULE
+EXTENSION_exclude = $(wildcard $(topdir)/../../mono-extensions/mcs/$(thisdir)/$(PROFILE)_$(LIBRARY).exclude.sources)
+else
+EXTENSION_exclude = $(wildcard $(PROFILE)_opt_$(LIBRARY).exclude.sources)
+endif
+
 # Note, gensources.sh can create a $(sourcefile).makefrag if it sees any '#include's
 # We don't include it in the dependencies since it isn't always created
 $(sourcefile): $(PROFILE_sources) $(PROFILE_excludes) $(topdir)/build/gensources.sh $(EXTENSION_include)
        @echo Creating the per profile list $@ ...
-       $(SHELL) $(topdir)/build/gensources.sh $@ '$(PROFILE_sources)' '$(PROFILE_excludes)' '$(EXTENSION_include)'
+       $(SHELL) $(topdir)/build/gensources.sh $@ '$(PROFILE_sources)' '$(PROFILE_excludes)' '$(EXTENSION_include)' '$(EXTENSION_exclude)'
 endif
 
 PLATFORM_excludes := $(wildcard $(LIBRARY).$(PLATFORM)-excludes)
diff --git a/mcs/build/profiles/mobile_static.make b/mcs/build/profiles/mobile_static.make
new file mode 100644 (file)
index 0000000..5950566
--- /dev/null
@@ -0,0 +1,20 @@
+#! -*- makefile -*-
+
+BOOTSTRAP_PROFILE = build
+
+BOOTSTRAP_MCS = MONO_PATH="$(topdir)/class/lib/$(BOOTSTRAP_PROFILE)$(PLATFORM_PATH_SEPARATOR)$$MONO_PATH" $(INTERNAL_GMCS)
+MCS = MONO_PATH="$(topdir)/class/lib/$(BOOTSTRAP_PROFILE)$(PLATFORM_PATH_SEPARATOR)$$MONO_PATH" $(INTERNAL_GMCS)
+
+# Use system resgen as we don't want local System.Windows.Forms dependency
+RESGEN = resgen2
+
+profile-check:
+       @:
+
+DEFAULT_REFERENCES = -r:mscorlib.dll
+PROFILE_MCS_FLAGS = -d:NET_1_1 -d:NET_2_0 -d:NET_2_1 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -d:MOBILE -d:FULL_AOT_RUNTIME -d:DISABLE_REMOTING -d:DISABLE_COM -nowarn:1699 -nostdlib -lib:$(topdir)/class/lib/$(PROFILE) $(DEFAULT_REFERENCES) $(PLATFORM_DEBUG_FLAGS)
+FRAMEWORK_VERSION = 2.1
+NO_TEST = yes
+
+# the tuner takes care of the install
+NO_INSTALL = yes
index d49b255f8615f327f087a096cbf3d2ad3f9b5281..b841a1027ae77586dd2bc67ee774493311eba346 100644 (file)
@@ -12,9 +12,9 @@ profile-check:
        @:
 
 DEFAULT_REFERENCES = -r:mscorlib.dll
-PROFILE_MCS_FLAGS = -d:NET_1_1 -d:NET_2_0 -d:NET_2_1 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -d:MOBILE -d:MONOTOUCH -d:DISABLE_REMOTING -nowarn:1699 -nostdlib -lib:$(topdir)/class/lib/$(PROFILE) $(DEFAULT_REFERENCES) $(PLATFORM_DEBUG_FLAGS)
+PROFILE_MCS_FLAGS = -d:NET_1_1 -d:NET_2_0 -d:NET_2_1 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -d:MOBILE -d:MONOTOUCH -d:DISABLE_REMOTING -d:DISABLE_COM -d:FULL_AOT_RUNTIME -nowarn:1699 -nostdlib -lib:$(topdir)/class/lib/$(PROFILE) $(DEFAULT_REFERENCES) $(PLATFORM_DEBUG_FLAGS)
 FRAMEWORK_VERSION = 2.1
 NO_TEST = yes
 
 # the tuner takes care of the install
-NO_INSTALL = yes
+NO_INSTALL = yes
\ No newline at end of file
index 0cdda1928475ce2c0b2ea18e6fbfbfd04294a5e5..9f82811018f495c016c9ee62ab9e73a00dc38648 100644 (file)
@@ -14,9 +14,9 @@ profile-check:
        @:
 
 DEFAULT_REFERENCES = -r:mscorlib.dll
-PROFILE_MCS_FLAGS = -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:$(topdir)/class/lib/$(PROFILE) $(DEFAULT_REFERENCES) $(PLATFORM_DEBUG_FLAGS)
+PROFILE_MCS_FLAGS = -d:NET_1_1 -d:NET_2_0 -d:NET_2_1 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -d:MOBILE -d:MONOTOUCH -nowarn:1699 -nostdlib -lib:$(topdir)/class/lib/$(PROFILE) $(DEFAULT_REFERENCES) $(PLATFORM_DEBUG_FLAGS)
 
-FRAMEWORK_VERSION = 4.5
+FRAMEWORK_VERSION = 2.1
 
 # This is utility build only
 NO_INSTALL = yes
index 7c7a36c353e4bb00cebc57d6dbd04f2c853cae8b..5ed34b8ff1ac9b583c3ef3b3d1c526eaa1f7079e 100644 (file)
@@ -80,7 +80,6 @@ include $(topdir)/build/config-default.make
 # Default PLATFORM and PROFILE if they're not already defined.
 
 ifndef PLATFORM
-$(info *** PLATFORM is not defined.)
 ifeq ($(OS),Windows_NT)
 $(info *** Assuming PLATFORM is 'win32'.)
 PLATFORM = win32
index ea174d80d1c974ef8103f82ee5a1260932775f9d..1f5818bde9bcb24d4348a8259aebb0d27954de57 100644 (file)
@@ -54,7 +54,7 @@
 [assembly: System.Runtime.CompilerServices.TypeForwardedToAttribute(typeof(System.Linq.Expressions.TypeBinaryExpression))]
 [assembly: System.Runtime.CompilerServices.TypeForwardedToAttribute(typeof(System.Linq.Expressions.UnaryExpression))]
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 [assembly: System.Runtime.CompilerServices.TypeForwardedToAttribute(typeof(System.Linq.Expressions.BlockExpression))]
 [assembly: System.Runtime.CompilerServices.TypeForwardedToAttribute(typeof(System.Linq.Expressions.CatchBlock))]
 [assembly: System.Runtime.CompilerServices.TypeForwardedToAttribute(typeof(System.Linq.Expressions.DebugInfoExpression))]
index 67eeae47cbf2bc4486ef9fd79f608a13408aaae6..414b282411fd98da15d7f7cb7075b4c69d381e0a 100644 (file)
@@ -68,6 +68,7 @@ common_dirs := \
        Novell.Directory.Ldap           \
        Mono.Security.Win32             \
        System.DirectoryServices        \
+       System.DirectoryServices.Protocols      \
        RabbitMQ.Client                 \
        Mono.Messaging                  \
        System.Messaging                \
@@ -164,33 +165,7 @@ monodroid_dirs := \
        System.Net.Http
 
 monotouch_runtime_dirs := \
-       corlib \
-       System \
-       System.XML      \
-       Mono.Posix \
-       System.Core \
-       Mono.Security                   \
-       System \
-       System.Security                 \
-       System.Configuration            \
-       System                          \
-       System.XML                      \
-       $(resgen_dir)                   \
-       System.Drawing                  \
-       System.Transactions             \
-       System.EnterpriseServices       \
-       Mono.Data.Tds                   \
-       System.Data                     \
-       Accessibility                   \
-       Mono.WebBrowser                 \
-       System.Runtime.Serialization.Formatters.Soap \
-       Managed.Windows.Forms           \
-       Mono.Data.Sqlite                \
-       System.Web.ApplicationServices  \
-       System.Web \
-       Mono.Web \
-       System.Web.Services \
-       System.Web
+       corlib
 
 net_3_5_only_dirs := \
        Microsoft.Build.Framework       \
@@ -257,6 +232,7 @@ net_2_0_SUBDIRS := $(common_dirs) $(net_2_0_dirs) $(net_2_0_only_dirs) aot-compi
 monodroid_SUBDIRS := $(mobile_dirs) $(monodroid_dirs)
 monotouch_SUBDIRS := $(mobile_dirs)
 monotouch_runtime_SUBDIRS := $(monotouch_runtime_dirs)
+mobile_static_SUBDIRS := $(mobile_dirs)
 mobile_SUBDIRS := $(mobile_dirs)
 net_3_5_SUBDIRS := $(net_3_5_only_dirs)
 net_4_0_SUBDIRS := $(common_dirs) $(net_2_0_dirs) $(net_4_0_dirs) $(net_4_0_only_dirs)
index d50b2d5f2b08e1358f57b4c8c799accb7e04c86b..2dd81619705c9a33f1265fb324f3a4f9b56b060a 100644 (file)
@@ -241,6 +241,9 @@ namespace MonoTests.Mono.Unix
                [Test]
                public void readlinkat_char ()
                {
+                       if (!HaveReadlinkAt)
+                               return;
+
                        foreach (string s in Targets) {
                                CreateLink (s);
 
index 947cdc7973dd197d34c47d5dc8814977c2fdf524..6c5d3683ba48a5bff957bec5a83978ef0de8fe4a 100644 (file)
@@ -12,7 +12,7 @@ CLEAN_FILES += $(STRING_MESSAGES)
 EXTRA_DISTFILES = \
        src/ComponentModel/Strings.resx
        
-VALID_PROFILE := $(filter net_4_0 net_4_5 monotouch monodroid, $(PROFILE))
+VALID_PROFILE := $(filter net_4_0 net_4_5 monotouch monodroid mobile_static, $(PROFILE))
 ifndef VALID_PROFILE
 LIBRARY_NAME = dummy-System.ComponentModel.Composition.dll
 NO_INSTALL = yes
index b6ac428a3c86c489c18e30e91a549bd7fb9e782c..c7451bf98fcbc8db42583189263512695e929690 100644 (file)
@@ -1,4 +1,4 @@
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 // -----------------------------------------------------------------------
 // Copyright (c) Microsoft Corporation.  All rights reserved.
 // -----------------------------------------------------------------------
index 9199e0ede3e7e668208f52f954843912789600dd..28c8a94840bfaf9186d44d132c66d289836290d7 100644 (file)
@@ -1,4 +1,4 @@
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 // -----------------------------------------------------------------------
 // Copyright (c) Microsoft Corporation.  All rights reserved.
 // -----------------------------------------------------------------------
index 3ac6fd6859822b45da8ef5d88711090308aa2eb1..e1e7dd5692ec3f302cb6db9de9e73332f1c42e8c 100644 (file)
@@ -32,7 +32,7 @@ namespace System.ComponentModel.Composition
                 {
                     if(!metadataViewType.IsAttributeDefined<MetadataViewImplementationAttribute>())
                     {
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
                         try
                         {
                             proxyType = MetadataViewGenerator.GenerateView(metadataViewType);
@@ -87,7 +87,7 @@ namespace System.ComponentModel.Composition
                 }
                 catch (TargetInvocationException ex)
                 {
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
                     //Unwrap known failures that we want to present as CompositionContractMismatchException
                     if(metadataViewType.IsInterface)
                     {
index 18d81e994bbbafcb3f72deef2e983b23de5b9035..799406c57d7588ba92e7d1ab05e51c7509aeb92c 100644 (file)
@@ -42,7 +42,7 @@ namespace System.ComponentModel.Composition.Primitives
 
         private Type CreateStandardDelegateType()
         {
-#if MONOTOUCH
+#if FULL_AOT_RUNTIME
             throw new NotImplementedException ();
 #else
             ParameterInfo[] parameters = this._method.GetParameters();
index f0f90784e4237aa6f124e821356c9e2de89cdcff..9564b81d88b0fcf436e732a151e8deb00ac5aa09 100644 (file)
@@ -18,7 +18,7 @@ endif
 TEST_MCS_FLAGS = $(LIB_MCS_FLAGS)
 
 # This is a .NET 3.5+ assembly
-VALID_PROFILE := $(filter net_2_0 net_4_0 net_4_5 monotouch monodroid, $(PROFILE))
+VALID_PROFILE := $(filter net_2_0 net_4_0 net_4_5 monotouch monodroid mobile_static, $(PROFILE))
 ifndef VALID_PROFILE
 LIBRARY_NAME = dummy-System.ComponentModel.DataAnnotations.dll
 NO_INSTALL = yes
diff --git a/mcs/class/System.ComponentModel.DataAnnotations/mobile_static_System.ComponentModel.DataAnnotations.dll.sources b/mcs/class/System.ComponentModel.DataAnnotations/mobile_static_System.ComponentModel.DataAnnotations.dll.sources
new file mode 100644 (file)
index 0000000..3de14f5
--- /dev/null
@@ -0,0 +1 @@
+#include net_4_5_System.ComponentModel.DataAnnotations.dll.sources
index 0b3e9865cf872b893587e3cc262998da24c8de67..22252d68b9f44d0503f3a381dcaf75e5cea7d101 100644 (file)
@@ -14,10 +14,6 @@ ifeq (monodroid, $(PROFILE))
 LIB_MCS_FLAGS += -d:FEATURE_CORE_DLR,FEATURE_REFEMIT,ANDROID
 endif
 
-ifeq (monotouch, $(PROFILE))
-LIB_MCS_FLAGS += -d:FULL_AOT_RUNTIME
-endif
-
 ifeq (4, $(FRAMEWORK_VERSION_MAJOR))
 LIB_MCS_FLAGS += -d:FEATURE_CORE_DLR,FEATURE_REFEMIT,FEATURE_PDBEMIT
 endif
index 005f0882ac6054af1f4e178830065b0ee32aa6a7..014cde469fa40cfd79d48db94249e05397586bba 100644 (file)
@@ -236,8 +236,18 @@ namespace System.IO.MemoryMappedFiles
                [DllImport ("libc", SetLastError=true)]
                static extern int open (string path, int flags, int access);
 
+#if MONODROID
+               [DllImport ("__Internal")]
+               static extern int monodroid_getpagesize ();
+
+               static int getpagesize ()
+               {
+                       return monodroid_getpagesize ();
+               }
+#else
                [DllImport ("libc")]
                static extern int getpagesize ();
+#endif
 
                [MethodImplAttribute (MethodImplOptions.InternalCall)]
                static extern long mono_filesize_from_path (string str);
index 143f57513f47f7ba7c38307bf8729162d48b5d95..03f5f5ee492870bb104c560872620fffbc2e7fe6 100644 (file)
@@ -35,7 +35,9 @@
 
 using System;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index 6d6d5dd60eca27dfa7da896d430566048555c914..6b1ba6ced51d3d444726d3f9f10a420398d7a773 100644 (file)
@@ -27,7 +27,9 @@
 //
 
 using System;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index 38a7b3cab66116f54649681a2016c64a5b4de9af..10dd69ce8f6aaacf4768b62328749ca99a09fad4 100644 (file)
@@ -33,7 +33,9 @@
 
 using System;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index 2069927b3066aed4119802c8272b32e1ee243406..b0013419f66ac34c66c551c325d47af42db2054f 100644 (file)
@@ -29,7 +29,9 @@
 using System;
 using System.Collections.ObjectModel;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index 8106c60f47d2607cc8ef501c40d95438fc5e6deb..f79156284c2ef6e037613f1117aa09b5d698b815 100644 (file)
@@ -34,7 +34,9 @@ using System.Collections.ObjectModel;
 using System.Globalization;
 using System.Linq;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index f8e81498d15d0c104cbea8693d488fafb4d23802..3a44b594c9a7acb0860198da976179c4cec22cfe 100644 (file)
@@ -31,7 +31,7 @@ using System.Collections.ObjectModel;
 
 namespace System.Linq.Expressions {
 
-#if MONOTOUCH
+#if FULL_AOT_RUNTIME
        public
 #endif
        abstract class ExpressionVisitor {
index 0f4eadfd3428136e3ac4df8660c88a9f3a9d6967..3b76fe170e0eb2174e929f59ea3df6ec37f13822 100644 (file)
@@ -29,7 +29,9 @@
 using System;
 using System.Collections.Generic;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 using System.Runtime.CompilerServices;
 
 namespace System.Linq.Expressions {
index 92a40c6d4b7f220bf1591ba48ff3b976b833fd00..6e873b0c9b2d8b12c37a7362b4e0aaa9ff7e6620 100644 (file)
@@ -31,7 +31,10 @@ using System;
 using System.Collections.ObjectModel;
 using System.Collections.Generic;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
+
 
 namespace System.Linq.Expressions {
 
@@ -82,7 +85,7 @@ namespace System.Linq.Expressions {
 
                public Delegate Compile ()
                {
-#if TARGET_JVM || MONOTOUCH
+#if FULL_AOT_RUNTIME
                        return new System.Linq.jvm.Runner (this).CreateDelegate ();
 #else
                        var context = new CompilationContext ();
@@ -91,7 +94,7 @@ namespace System.Linq.Expressions {
 #endif
                }
 
-#if TARGET_JVM || MONOTOUCH
+#if FULL_AOT_RUNTIME
                internal Delegate Compile (System.Linq.jvm.ExpressionInterpreter interpreter)
                {
                        return new System.Linq.jvm.Runner (this, interpreter).CreateDelegate ();
index cf58105456810d348056be60d01d7f53ee5c1221..87329224dc215e059fc62116fac6c8b49ed2c34e 100644 (file)
@@ -28,7 +28,9 @@
 
 using System;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 using System.Text;
 
 namespace System.Linq.Expressions {
index bf0c6835c3fb9c351301af610b557d0881cbb1eb..8f6e026eee1d2b042d6c3af2256a72e394515e33 100644 (file)
@@ -28,7 +28,9 @@
 
 using System;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index 1a0255f4ea776b9f1fc36d7fc4d2a95919a1cab6..b7483d4fdc4b5db0810c44470e2059b748657f8d 100644 (file)
@@ -28,7 +28,9 @@
 
 using System;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index 3c320e63e30a2c4e375287fb3b633507d40caebc..51d16028b4304875e0480773efde79fd46870c2c 100644 (file)
@@ -29,7 +29,9 @@
 using System;
 using System.Collections.ObjectModel;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index ec10de5c5266d8fb05bb1d76e9ac076f85b0a61e..414acf3aa6592422b6a37f374491b62dd8ba206d 100644 (file)
@@ -29,7 +29,9 @@
 using System;
 using System.Collections.ObjectModel;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index 7f898689c0a796adb10d6fd09d2bab77d2683f2c..0e1e7d7d467e09caf59333b29b0e5b9f1cb8a664 100644 (file)
@@ -29,7 +29,9 @@
 using System;
 using System.Collections.ObjectModel;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index c30bec70537a335bae16f82adc8511281d05fd10..68ac8b6d770f16a2b07304030e54ea58a305c0a5 100644 (file)
@@ -30,7 +30,9 @@ using System;
 using System.Collections.ObjectModel;
 using System.Linq;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index 005d17569ec8d9c4943cd897e927b59b4bb0973d..48499f3d2e2af27db4b80f7e04ed4c8f675707ef 100644 (file)
@@ -29,7 +29,9 @@
 using System;
 using System.Collections.ObjectModel;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index 94bd0ea4475dd02c125aa06473877b73481f9300..3fce527e11cabd51063be272b508c88cc9f6316d 100644 (file)
@@ -28,7 +28,9 @@
 //
 
 using System;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index 2629c96c4f20e9c94d7198cfd29edbf4434f81a9..77f91e044d49a37e4f9d5b5a06f9aa5d58ea9b75 100644 (file)
@@ -27,7 +27,9 @@
 //
 
 using System;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index 4f6f9cb890d679651918e0c48e23a76d984df4d8..13a1a5a9b3c372e9a836ab9b4e82e504c1ae0d94 100644 (file)
@@ -28,7 +28,9 @@
 
 using System;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Linq.Expressions {
 
index d3c16f4fdef29d289cf79bfbd500806458d9f9c6..637d0c400dffd8384193b9dd29ed72f867654d6c 100644 (file)
@@ -74,6 +74,17 @@ namespace System
                                return new AdjustmentRule (dateStart, dateEnd, daylightDelta, daylightTransitionStart, daylightTransitionEnd);
                        }
 
+                       private AdjustmentRule (SerializationInfo info, StreamingContext context)
+                       {
+                               if (info == null)
+                                       throw new ArgumentNullException ("info");
+                               dateStart = (DateTime) info.GetValue ("DateStart", typeof (DateTime));
+                               dateEnd = (DateTime) info.GetValue ("DateEnd", typeof (DateTime));
+                               daylightDelta = (TimeSpan) info.GetValue ("DaylightDelta", typeof (TimeSpan));
+                               daylightTransitionStart = (TimeZoneInfo.TransitionTime) info.GetValue ("DaylightTransitionStart", typeof (TimeZoneInfo.TransitionTime));
+                               daylightTransitionEnd = (TimeZoneInfo.TransitionTime) info.GetValue ("DaylightTransitionEnd", typeof (TimeZoneInfo.TransitionTime));
+                       }
+                       
                        private AdjustmentRule (
                                DateTime dateStart,
                                DateTime dateEnd,
@@ -130,7 +141,13 @@ namespace System
                        public void GetObjectData (SerializationInfo info, StreamingContext context)
 #endif
                        {
-                               throw new NotImplementedException ();
+                               if (info == null)
+                                       throw new ArgumentNullException ("info");
+                               info.AddValue ("DateStart", DateStart);
+                               info.AddValue ("DateEnd", DateEnd);
+                               info.AddValue ("DaylightDelta", DaylightDelta);
+                               info.AddValue ("DaylightTransitionStart", DaylightTransitionStart);
+                               info.AddValue ("DaylightTransitionEnd", DaylightTransitionEnd);
                        }
 #if NET_4_0
                        void IDeserializationCallback.OnDeserialization (object sender)
@@ -138,7 +155,38 @@ namespace System
                        public void OnDeserialization (object sender)
 #endif
                        {
-                               throw new NotImplementedException ();
+                               try {
+                                       TimeZoneInfo.AdjustmentRule.Validate (dateStart, dateEnd, daylightDelta, 
+                                                                             daylightTransitionStart, daylightTransitionEnd);
+                               } catch (ArgumentException ex) {
+                                       throw new SerializationException ("invalid serialization data", ex);
+                               }
+                       }
+
+                       private static void Validate (
+                               DateTime dateStart,
+                               DateTime dateEnd,
+                               TimeSpan daylightDelta,
+                               TransitionTime daylightTransitionStart,
+                               TransitionTime daylightTransitionEnd)
+                       {
+                               if (dateStart.Kind != DateTimeKind.Unspecified || dateEnd.Kind != DateTimeKind.Unspecified)
+                                       throw new ArgumentException ("the Kind property of dateStart or dateEnd parameter does not equal DateTimeKind.Unspecified");
+
+                               if (daylightTransitionStart == daylightTransitionEnd)
+                                       throw new ArgumentException ("daylightTransitionStart parameter cannot equal daylightTransitionEnd parameter");
+
+                               if (dateStart.Ticks % TimeSpan.TicksPerDay != 0 || dateEnd.Ticks % TimeSpan.TicksPerDay != 0)
+                                       throw new ArgumentException ("dateStart or dateEnd parameter includes a time of day value");
+
+                               if (dateEnd < dateStart)
+                                       throw new ArgumentOutOfRangeException ("dateEnd is earlier than dateStart");
+
+                               if (daylightDelta > new TimeSpan (14, 0, 0) || daylightDelta < new TimeSpan (-14, 0, 0))
+                                       throw new ArgumentOutOfRangeException ("daylightDelta is less than -14 or greater than 14 hours");
+
+                               if (daylightDelta.Ticks % TimeSpan.TicksPerSecond != 0)
+                                       throw new ArgumentOutOfRangeException ("daylightDelta parameter does not represent a whole number of seconds");
                        }
                }
        }
index 498df578696ef3dc31a28ea843b7d26d62828d40..a21edd6c93ee74a1f66de8d7b9fa5cf91d3fa983 100644 (file)
@@ -29,10 +29,231 @@ using System.Text;
 
 namespace System {
 
+       interface IAndroidTimeZoneDB {
+               IEnumerable<string>   GetAvailableIds ();
+               byte[]                GetTimeZoneData (string id);
+       }
+
+       [StructLayout (LayoutKind.Sequential, Pack=1)]
+       unsafe struct AndroidTzDataHeader {
+               public fixed byte signature [12];
+               public int        indexOffset;
+               public int        dataOffset;
+               public int        zoneTabOffset;
+       }
+
+       [StructLayout (LayoutKind.Sequential, Pack=1)]
+       unsafe struct AndroidTzDataEntry {
+               public fixed byte id [40];
+               public int        byteOffset;
+               public int        length;
+               public int        rawUtcOffset;
+       }
+
+       /*
+        * Android v4.3 Timezone support infrastructure.
+        *
+        * This is a C# port of libcore.util.ZoneInfoDB:
+        *
+        *    https://android.googlesource.com/platform/libcore/+/master/luni/src/main/java/libcore/util/ZoneInfoDB.java
+        *
+        * This is needed in order to read Android v4.3 tzdata files.
+        */
+       sealed class AndroidTzData : IAndroidTimeZoneDB {
+
+               internal static readonly string[] Paths = new string[]{
+                       Environment.GetEnvironmentVariable ("ANDROID_DATA") + "/misc/zoneinfo/tzdata",
+                       Environment.GetEnvironmentVariable ("ANDROID_ROOT") + "/usr/share/zoneinfo/tzdata",
+               };
+
+               string    tzdataPath;
+               Stream    data;
+               string    version;
+               string    zoneTab;
+
+               string[]  ids;
+               int[]     byteOffsets;
+               int[]     lengths;
+
+               public AndroidTzData (params string[] paths)
+               {
+                       foreach (var path in paths)
+                               if (LoadData (path)) {
+                                       tzdataPath = path;
+                                       return;
+                               }
+
+                       Console.Error.WriteLine ("Couldn't find any tzdata!");
+                       tzdataPath  = "/";
+                       version     = "missing";
+                       zoneTab     = "# Emergency fallback data.\n";
+                       ids         = new[]{ "GMT" };
+               }
+
+               public string Version {
+                       get {return version;}
+               }
+
+               public string ZoneTab {
+                       get {return zoneTab;}
+               }
+
+               bool LoadData (string path)
+               {
+                       if (!File.Exists (path))
+                               return false;
+                       try {
+                               data = File.OpenRead (path);
+                       } catch (IOException) {
+                               return false;
+                       } catch (UnauthorizedAccessException) {
+                               return false;
+                       }
+
+                       try {
+                               ReadHeader ();
+                               return true;
+                       } catch (Exception e) {
+                               Console.Error.WriteLine ("tzdata file \"{0}\" was present but invalid: {1}", path, e);
+                       }
+                       return false;
+               }
+
+               unsafe void ReadHeader ()
+               {
+                       int size   = System.Math.Max (Marshal.SizeOf (typeof (AndroidTzDataHeader)), Marshal.SizeOf (typeof (AndroidTzDataEntry)));
+                       var buffer = new byte [size];
+                       var header = ReadAt<AndroidTzDataHeader>(0, buffer);
+
+                       header.indexOffset    = NetworkToHostOrder (header.indexOffset);
+                       header.dataOffset     = NetworkToHostOrder (header.dataOffset);
+                       header.zoneTabOffset  = NetworkToHostOrder (header.zoneTabOffset);
+
+                       sbyte* s = (sbyte*) header.signature;
+                       string magic = new string (s, 0, 6, Encoding.ASCII);
+                       if (magic != "tzdata" || header.signature [11] != 0) {
+                               var b = new StringBuilder ();
+                               b.Append ("bad tzdata magic:");
+                               for (int i = 0; i < 12; ++i) {
+                                       b.Append (" ").Append (((byte) s [i]).ToString ("x2"));
+                               }
+                               throw new InvalidOperationException ("bad tzdata magic: " + b.ToString ());
+                       }
+
+                       version = new string (s, 6, 5, Encoding.ASCII);
+
+                       ReadIndex (header.indexOffset, header.dataOffset, buffer);
+                       ReadZoneTab (header.zoneTabOffset, checked ((int) data.Length) - header.zoneTabOffset);
+               }
+
+               unsafe T ReadAt<T> (long position, byte[] buffer)
+                       where T : struct
+               {
+                       int size = Marshal.SizeOf (typeof (T));
+                       if (buffer.Length < size)
+                               throw new InvalidOperationException ("Internal error: buffer too small");
+
+                       data.Position = position;
+                       int r;
+                       if ((r = data.Read (buffer, 0, size)) < size)
+                               throw new InvalidOperationException (
+                                               string.Format ("Error reading '{0}': read {1} bytes, expected {2}", tzdataPath, r, size));
+
+                       fixed (byte* b = buffer)
+                               return (T) Marshal.PtrToStructure ((IntPtr) b, typeof (T));
+               }
+
+               static int NetworkToHostOrder (int value)
+               {
+                       if (!BitConverter.IsLittleEndian)
+                               return value;
+
+                       return
+                               (((value >> 24) & 0xFF) |
+                                ((value >> 08) & 0xFF00) |
+                                ((value << 08) & 0xFF0000) |
+                                ((value << 24)));
+               }
+
+               unsafe void ReadIndex (int indexOffset, int dataOffset, byte[] buffer)
+               {
+                       int indexSize   = dataOffset - indexOffset;
+                       int entryCount  = indexSize / Marshal.SizeOf (typeof (AndroidTzDataEntry));
+                       int entrySize   = Marshal.SizeOf (typeof (AndroidTzDataEntry));
+
+                       byteOffsets   = new int [entryCount];
+                       ids           = new string [entryCount];
+                       lengths       = new int [entryCount];
+
+                       for (int i = 0; i < entryCount; ++i) {
+                               var entry = ReadAt<AndroidTzDataEntry>(indexOffset + (entrySize*i), buffer);
+                               var p     = (sbyte*) entry.id;
+
+                               byteOffsets [i]   = NetworkToHostOrder (entry.byteOffset) + dataOffset;
+                               ids [i]           = new string (p, 0, GetStringLength (p, 40), Encoding.ASCII);
+                               lengths [i]       = NetworkToHostOrder (entry.length);
+
+                               if (lengths [i] < Marshal.SizeOf (typeof (AndroidTzDataHeader)))
+                                       throw new InvalidOperationException ("Length in index file < sizeof(tzhead)");
+                       }
+               }
+
+               static unsafe int GetStringLength (sbyte* s, int maxLength)
+               {
+                       int len;
+                       for (len = 0; len < maxLength; len++, s++) {
+                               if (*s == 0)
+                                       break;
+                       }
+                       return len;
+               }
+
+               unsafe void ReadZoneTab (int zoneTabOffset, int zoneTabSize)
+               {
+                       byte[] zoneTab = new byte [zoneTabSize];
+
+                       data.Position = zoneTabOffset;
+
+                       int r;
+                       if ((r = data.Read (zoneTab, 0, zoneTab.Length)) < zoneTab.Length)
+                               throw new InvalidOperationException (
+                                               string.Format ("Error reading zonetab: read {0} bytes, expected {1}", r, zoneTabSize));
+
+                       this.zoneTab = Encoding.ASCII.GetString (zoneTab, 0, zoneTab.Length);
+               }
+
+               public IEnumerable<string> GetAvailableIds ()
+               {
+                       return ids;
+               }
+
+               public byte[] GetTimeZoneData (string id)
+               {
+                       int i = Array.BinarySearch (ids, id, StringComparer.Ordinal);
+                       if (i < 0)
+                               return null;
+
+                       int offset = byteOffsets [i];
+                       int length = lengths [i];
+                       var buffer = new byte [length];
+
+                       lock (data) {
+                               data.Position = offset;
+                               int r;
+                               if ((r = data.Read (buffer, 0, buffer.Length)) < buffer.Length)
+                                       throw new InvalidOperationException (
+                                                       string.Format ("Unable to fully read from file '{0}' at offset {1} length {2}; read {3} bytes expected {4}.",
+                                                               tzdataPath, offset, length, r, buffer.Length));
+                       }
+
+                       return buffer;
+               }
+       }
+
        partial class TimeZoneInfo {
 
                /*
-                * Android Timezone support infrastructure.
+                * Android < v4.3 Timezone support infrastructure.
                 *
                 * This is a C# port of org.apache.harmony.luni.internal.util.ZoneInfoDB:
                 *
@@ -48,34 +269,35 @@ namespace System {
                 * which succinctly describes why we can't just use the LIBC implementation in
                 * TimeZoneInfo.cs -- the "standard Unixy" directory structure is NOT used.
                 */
-               static class ZoneInfoDB {
+               sealed class ZoneInfoDB : IAndroidTimeZoneDB {
                        const int TimeZoneNameLength  = 40;
                        const int TimeZoneIntSize     = 4;
 
-                       static readonly string ZoneDirectoryName  = Environment.GetEnvironmentVariable ("ANDROID_ROOT") + "/usr/share/zoneinfo/";
-                       static readonly string ZoneFileName       = ZoneDirectoryName + "zoneinfo.dat";
-                       static readonly string IndexFileName      = ZoneDirectoryName + "zoneinfo.idx";
-                       const           string DefaultVersion     = "2007h";
-                       static readonly string VersionFileName    = ZoneDirectoryName + "zoneinfo.version";
+                       internal static readonly string ZoneDirectoryName  = Environment.GetEnvironmentVariable ("ANDROID_ROOT") + "/usr/share/zoneinfo/";
 
-                       static readonly object _lock = new object ();
+                       const    string ZoneFileName       = "zoneinfo.dat";
+                       const    string IndexFileName      = "zoneinfo.idx";
+                       const    string DefaultVersion     = "2007h";
+                       const    string VersionFileName    = "zoneinfo.version";
 
-                       static readonly string    version;
-                       static readonly string[]  names;
-                       static readonly int[]     starts;
-                       static readonly int[]     lengths;
-                       static readonly int[]     offsets;
+                       readonly string    zoneRoot;
+                       readonly string    version;
+                       readonly string[]  names;
+                       readonly int[]     starts;
+                       readonly int[]     lengths;
+                       readonly int[]     offsets;
 
-                       static ZoneInfoDB ()
+                       public ZoneInfoDB (string zoneInfoDB = null)
                        {
+                               zoneRoot = zoneInfoDB ?? ZoneDirectoryName;
                                try {
-                                       version = ReadVersion ();
+                                       version = ReadVersion (Path.Combine (zoneRoot, VersionFileName));
                                } catch {
                                        version = DefaultVersion;
                                }
 
                                try {
-                                       ReadDatabase (out names, out starts, out lengths, out offsets);
+                                       ReadDatabase (Path.Combine (zoneRoot, IndexFileName), out names, out starts, out lengths, out offsets);
                                } catch {
                                        names   = new string [0];
                                        starts  = new int [0];
@@ -84,16 +306,16 @@ namespace System {
                                }
                        }
 
-                       static string ReadVersion ()
+                       static string ReadVersion (string path)
                        {
-                               using (var file = new StreamReader (VersionFileName, Encoding.GetEncoding ("iso-8859-1"))) {
+                               using (var file = new StreamReader (path, Encoding.GetEncoding ("iso-8859-1"))) {
                                        return file.ReadToEnd ().Trim ();
                                }
                        }
 
-                       static void ReadDatabase (out string[] names, out int[] starts, out int[] lengths, out int[] offsets)
+                       void ReadDatabase (string path, out string[] names, out int[] starts, out int[] lengths, out int[] offsets)
                        {
-                               using (var file = File.OpenRead (IndexFileName)) {
+                               using (var file = File.OpenRead (path)) {
                                        var nbuf = new byte [TimeZoneNameLength];
 
                                        int numEntries = (int) (file.Length / (TimeZoneNameLength + 3*TimeZoneIntSize));
@@ -140,21 +362,21 @@ namespace System {
                                        ((nbuf [2] & 0xff) << 8) + (nbuf [3] & 0xff);
                        }
 
-                       internal static string Version {
+                       internal string Version {
                                get {return version;}
                        }
 
-                       internal static IEnumerable<string> GetAvailableIds ()
+                       public IEnumerable<string> GetAvailableIds ()
                        {
                                return GetAvailableIds (0, false);
                        }
 
-                       internal static IEnumerable<string> GetAvailableIds (int rawOffset)
+                       IEnumerable<string> GetAvailableIds (int rawOffset)
                        {
                                return GetAvailableIds (rawOffset, true);
                        }
 
-                       static IEnumerable<string> GetAvailableIds (int rawOffset, bool checkOffset)
+                       IEnumerable<string> GetAvailableIds (int rawOffset, bool checkOffset)
                        {
                                for (int i = 0; i < offsets.Length; ++i) {
                                        if (!checkOffset || offsets [i] == rawOffset)
@@ -162,21 +384,21 @@ namespace System {
                                }
                        }
 
-                       static TimeZoneInfo _GetTimeZone (string name)
+                       public byte[] GetTimeZoneData (string id)
                        {
                                int start, length;
-                               using (var stream = GetTimeZoneData (name, out start, out length)) {
+                               using (var stream = GetTimeZoneData (id, out start, out length)) {
                                        if (stream == null)
                                                return null;
                                        byte[] buf = new byte [length];
                                        Fill (stream, buf, buf.Length);
-                                       return TimeZoneInfo.ParseTZBuffer (name, buf, length);
+                                       return buf;
                                }
                        }
 
-                       static FileStream GetTimeZoneData (string name, out int start, out int length)
+                       FileStream GetTimeZoneData (string name, out int start, out int length)
                        {
-                               var f = new FileInfo (Path.Combine (ZoneDirectoryName, name));
+                               var f = new FileInfo (Path.Combine (zoneRoot, name));
                                if (f.Exists) {
                                        start   = 0;
                                        length  = (int) f.Length;
@@ -192,11 +414,48 @@ namespace System {
                                start   = starts [i];
                                length  = lengths [i];
 
-                               var stream = File.OpenRead (ZoneFileName);
+                               var stream = File.OpenRead (Path.Combine (zoneRoot, ZoneFileName));
                                stream.Seek (start, SeekOrigin.Begin);
 
                                return stream;
                        }
+               }
+
+               static class AndroidTimeZones {
+
+                       static IAndroidTimeZoneDB db;
+
+                       static AndroidTimeZones ()
+                       {
+                               db = GetDefaultTimeZoneDB ();
+                       }
+
+                       static IAndroidTimeZoneDB GetDefaultTimeZoneDB ()
+                       {
+                               foreach (var p in AndroidTzData.Paths)
+                                       if (File.Exists (p))
+                                               return new AndroidTzData (AndroidTzData.Paths);
+                               if (Directory.Exists (ZoneInfoDB.ZoneDirectoryName))
+                                       return new ZoneInfoDB ();
+                               return null;
+                       }
+
+                       internal static IEnumerable<string> GetAvailableIds ()
+                       {
+                               return db == null
+                                       ? new string [0]
+                                       : db.GetAvailableIds ();
+                       }
+
+                       static TimeZoneInfo _GetTimeZone (string name)
+                       {
+                               if (db == null)
+                                       return null;
+                               byte[] buffer = db.GetTimeZoneData (name);
+                               if (buffer == null)
+                                       return null;
+                               return TimeZoneInfo.ParseTZBuffer (name, buffer, buffer.Length);
+                       }
 
                        internal static TimeZoneInfo GetTimeZone (string id)
                        {
@@ -211,7 +470,7 @@ namespace System {
 
                                try {
                                        return _GetTimeZone (id);
-                               } catch (Exception e) {
+                               } catch (Exception) {
                                        return null;
                                }
                        }
@@ -265,6 +524,8 @@ namespace System {
                                        return sign * (hour * 60) * 60;
                        }
 
+                       static readonly object _lock = new object ();
+
                        static TimeZoneInfo defaultZone;
                        internal static TimeZoneInfo Default {
                                get {
@@ -295,7 +556,7 @@ namespace System {
 #if SELF_TEST
                        /*
                         * Compile:
-                        *    mcs  /out:tzi.exe "/d:INSIDE_CORLIB;MONODROID;NET_4_0;LIBC;SELF_TEST" System/TimeZone*.cs ../../build/common/Consts.cs
+                        *    mcs  /out:tzi.exe /unsafe "/d:INSIDE_CORLIB;MONODROID;NET_4_0;LIBC;SELF_TEST" System/TimeZone*.cs ../../build/common/Consts.cs ../Mono.Options/Mono.Options/Options.cs
                         * Prep:
                         *    mkdir -p usr/share/zoneinfo
                         *    android_root=`adb shell echo '$ANDROID_ROOT' | tr -d "\r"`
@@ -305,17 +566,31 @@ namespace System {
                         */
                        static void Main (string[] args)
                        {
-                               Console.WriteLine ("Version: {0}", version);
-                               for (int i = 0; i < names.Length; ++i) {
-                                       Console.Write ("{0,3}\tname={1,-40} start={2,-10} length={3,-4} offset=0x{4,8}",
-                                                       i, names [i], starts [i], lengths [i], offsets [i].ToString ("x8"));
+                               Func<IAndroidTimeZoneDB> c = () => GetDefaultTimeZoneDB ();
+                               Mono.Options.OptionSet p = null;
+                               p = new Mono.Options.OptionSet () {
+                                       { "T=", "Create AndroidTzData from {PATH}.", v => {
+                                                       c = () => new AndroidTzData (v);
+                                       } },
+                                       { "Z=", "Create ZoneInfoDB from {DIR}.", v => {
+                                                       c = () => new ZoneInfoDB (v);
+                                       } },
+                                       { "help", "Show this message and exit", v => {
+                                                       p.WriteOptionDescriptions (Console.Out);
+                                                       Environment.Exit (0);
+                                       } },
+                               };
+                               p.Parse (args);
+                               AndroidTimeZones.db = c ();
+                               Console.WriteLine ("DB type: {0}", AndroidTimeZones.db.GetType ().FullName);
+                               foreach (var id in GetAvailableIds ()) {
+                                       Console.Write ("name={0,-40}", id);
                                        try {
-                                               TimeZoneInfo zone = _GetTimeZone (names [i]);
+                                               TimeZoneInfo zone = _GetTimeZone (id);
                                                if (zone != null)
                                                        Console.Write (" {0}", zone);
                                                else {
-                                                       Console.Write (" ERROR:null Index? {0}",
-                                                                       Array.BinarySearch (names, names [i], StringComparer.Ordinal));
+                                                       Console.Write (" ERROR:null");
                                                }
                                        } catch (Exception e) {
                                                Console.WriteLine ();
index a914ed19b3d2649b69b83215207bdf3fc1d842a0..d57df150f0554bb1d318dd787d2b71225cc726f6 100644 (file)
@@ -108,6 +108,26 @@ namespace System
                                return new TransitionTime (timeOfDay, month, week, dayOfWeek);
                        }
 
+                       private TransitionTime (SerializationInfo info, StreamingContext context)
+                       {
+                               if (info == null)
+                                       throw new ArgumentNullException ("info");
+                               timeOfDay = (DateTime) info.GetValue ("TimeOfDay", typeof (DateTime));
+                               month = (byte) info.GetValue ("Month", typeof (byte));
+                               week = (byte) info.GetValue ("Week", typeof (byte));
+                               day = (byte) info.GetValue ("Day", typeof (byte));
+                               dayOfWeek = (DayOfWeek) info.GetValue ("DayOfWeek", typeof (DayOfWeek));
+                               isFixedDateRule = (bool) info.GetValue ("IsFixedDateRule", typeof (bool));
+
+                               if (isFixedDateRule)
+                               {
+                                       week = -1;
+                                       dayOfWeek = (DayOfWeek) (-1);
+                               }
+                               if (!isFixedDateRule)                   
+                                       day = -1;
+                       }
+
                        private TransitionTime (
                                DateTime timeOfDay,
                                int month,
@@ -190,8 +210,24 @@ namespace System
                        public void GetObjectData (SerializationInfo info, StreamingContext context)
 #endif
                        {
-                               throw new NotImplementedException ();
-                       }
+                               if (info == null)
+                                       throw new ArgumentNullException ("info");
+                               info.AddValue ("TimeOfDay", TimeOfDay);
+                               info.AddValue ("Month", System.Convert.ToByte(Month));
+                               if (week > -1)
+                                       info.AddValue ("Week", System.Convert.ToByte(week));
+                               else 
+                                       info.AddValue ("Week", (byte) 1);
+                               if (day > -1)
+                                       info.AddValue ("Day", System.Convert.ToByte(day));
+                               else
+                                       info.AddValue ("Day", (byte) 1);
+                               if (dayOfWeek !=  ((System.DayOfWeek) (-1)))
+                                       info.AddValue ("DayOfWeek", dayOfWeek);
+                               else
+                                       info.AddValue ("DayOfWeek", DayOfWeek.Sunday);
+                               info.AddValue ("IsFixedDateRule", IsFixedDateRule);
+                       }       
        
                        public override bool Equals (object obj)
                        {
@@ -216,7 +252,47 @@ namespace System
                        public void OnDeserialization (object sender)
 #endif
                        {
-                               throw new NotImplementedException ();
+                               try {
+                                       TimeZoneInfo.TransitionTime.Validate (timeOfDay, month, week, day, dayOfWeek, isFixedDateRule);
+                               } catch (ArgumentException ex) {
+                                       throw new SerializationException ("invalid serialization data", ex);
+                               }
+                       }
+
+                       private static void Validate (DateTime timeOfDay, int month,int week, int day, DayOfWeek dayOfWeek, bool isFixedDateRule)
+                       {
+                               if (timeOfDay.Year != 1 || timeOfDay.Month != 1 || timeOfDay.Day != 1)
+                                       throw new ArgumentException ("timeOfDay parameter has a non-default date component");
+
+                               if (timeOfDay.Kind != DateTimeKind.Unspecified)
+                                       throw new ArgumentException ("timeOfDay parameter Kind's property is not DateTimeKind.Unspecified");
+
+                               if (timeOfDay.Ticks % TimeSpan.TicksPerMillisecond != 0)
+                                       throw new ArgumentException ("timeOfDay parameter does not represent a whole number of milliseconds");
+
+                               if (day < 1 || day > 31) {
+                                       if (!(!isFixedDateRule && day == -1))
+                                               throw new ArgumentOutOfRangeException ("day parameter is less than 1 or greater than 31");
+                               }
+
+                               if (week < 1 || week > 5) {
+                                       if (!(isFixedDateRule && week == -1))
+                                               throw new ArgumentOutOfRangeException ("week parameter is less than 1 or greater than 5");
+                               }
+
+                               if (month < 1 || month > 12)
+                                       throw new ArgumentOutOfRangeException ("month parameter is less than 1 or greater than 12");
+
+                               if (dayOfWeek != DayOfWeek.Sunday &&
+                                               dayOfWeek != DayOfWeek.Monday &&
+                                               dayOfWeek != DayOfWeek.Tuesday &&
+                                               dayOfWeek != DayOfWeek.Wednesday &&
+                                               dayOfWeek != DayOfWeek.Thursday &&
+                                               dayOfWeek != DayOfWeek.Friday &&
+                                               dayOfWeek != DayOfWeek.Saturday) {
+                                       if (!(isFixedDateRule && dayOfWeek == (DayOfWeek) (-1)))
+                                               throw new ArgumentOutOfRangeException ("dayOfWeek parameter is not a member od DayOfWeek enumeration");
+                               }
                        }
                }
        }
index ee440a4bd51daa99e02153f2e065e79b31adc04c..1f580d76d8e43def476cb66357d0f66d2566fd92 100644 (file)
@@ -86,7 +86,7 @@ namespace System
                        get { 
                                if (local == null) {
 #if MONODROID
-                                       local = ZoneInfoDB.Default;
+                                       local = AndroidTimeZones.Default;
 #elif MONOTOUCH
                                        using (Stream stream = GetMonoTouchData (null)) {
                                                local = BuildFromStream ("Local", stream);
@@ -394,7 +394,7 @@ namespace System
                        }
 #endif
 #if MONODROID
-                       var timeZoneInfo = ZoneInfoDB.GetTimeZone (id);
+                       var timeZoneInfo = AndroidTimeZones.GetTimeZone (id);
                        if (timeZoneInfo == null)
                                throw new TimeZoneNotFoundException ();
                        return timeZoneInfo;
@@ -598,7 +598,15 @@ namespace System
                public void GetObjectData (SerializationInfo info, StreamingContext context)
 #endif
                {
-                       throw new NotImplementedException ();
+                       if (info == null)
+                               throw new ArgumentNullException ("info");
+                       info.AddValue ("Id", id);
+                       info.AddValue ("DisplayName", displayName);
+                       info.AddValue ("StandardName", standardDisplayName);
+                       info.AddValue ("DaylightName", daylightDisplayName);
+                       info.AddValue ("BaseUtcOffset", baseUtcOffset);
+                       info.AddValue ("AdjustmentRules", adjustmentRules);
+                       info.AddValue ("SupportsDaylightSavingTime", SupportsDaylightSavingTime);
                }
 
                //FIXME: change this to a generic Dictionary and allow caching for FindSystemTimeZoneById
@@ -619,8 +627,8 @@ namespace System
                                }
 #endif
 #if MONODROID
-                       foreach (string id in ZoneInfoDB.GetAvailableIds ()) {
-                               var tz = ZoneInfoDB.GetTimeZone (id);
+                       foreach (string id in AndroidTimeZones.GetAvailableIds ()) {
+                               var tz = AndroidTimeZones.GetTimeZone (id);
                                if (tz != null)
                                        systemTimeZones.Add (tz);
                        }
@@ -786,7 +794,54 @@ namespace System
                public void OnDeserialization (object sender)
 #endif
                {
-                       throw new NotImplementedException ();
+                       try {
+                                       TimeZoneInfo.Validate (id, baseUtcOffset, adjustmentRules);
+                               } catch (ArgumentException ex) {
+                                       throw new SerializationException ("invalid serialization data", ex);
+                               }
+               }
+
+               private static void Validate (string id, TimeSpan baseUtcOffset, AdjustmentRule [] adjustmentRules)
+               {
+                       if (id == null)
+                               throw new ArgumentNullException ("id");
+
+                       if (id == String.Empty)
+                               throw new ArgumentException ("id parameter is an empty string");
+
+                       if (baseUtcOffset.Ticks % TimeSpan.TicksPerMinute != 0)
+                               throw new ArgumentException ("baseUtcOffset parameter does not represent a whole number of minutes");
+
+                       if (baseUtcOffset > new TimeSpan (14, 0, 0) || baseUtcOffset < new TimeSpan (-14, 0, 0))
+                               throw new ArgumentOutOfRangeException ("baseUtcOffset parameter is greater than 14 hours or less than -14 hours");
+
+#if STRICT
+                       if (id.Length > 32)
+                               throw new ArgumentException ("id parameter shouldn't be longer than 32 characters");
+#endif
+
+                       if (adjustmentRules != null && adjustmentRules.Length != 0) {
+                               AdjustmentRule prev = null;
+                               foreach (AdjustmentRule current in adjustmentRules) {
+                                       if (current == null)
+                                               throw new InvalidTimeZoneException ("one or more elements in adjustmentRules are null");
+
+                                       if ((baseUtcOffset + current.DaylightDelta < new TimeSpan (-14, 0, 0)) ||
+                                                       (baseUtcOffset + current.DaylightDelta > new TimeSpan (14, 0, 0)))
+                                               throw new InvalidTimeZoneException ("Sum of baseUtcOffset and DaylightDelta of one or more object in adjustmentRules array is greater than 14 or less than -14 hours;");
+
+                                       if (prev != null && prev.DateStart > current.DateStart)
+                                               throw new InvalidTimeZoneException ("adjustment rules specified in adjustmentRules parameter are not in chronological order");
+                                       
+                                       if (prev != null && prev.DateEnd > current.DateStart)
+                                               throw new InvalidTimeZoneException ("some adjustment rules in the adjustmentRules parameter overlap");
+
+                                       if (prev != null && prev.DateEnd == current.DateStart)
+                                               throw new InvalidTimeZoneException ("a date can have multiple adjustment rules applied to it");
+
+                                       prev = current;
+                               }
+                       }
                }
                
                public string ToSerializedString ()
@@ -799,6 +854,19 @@ namespace System
                        return DisplayName;
                }
 
+               private TimeZoneInfo (SerializationInfo info, StreamingContext context)
+               {
+                       if (info == null)
+                               throw new ArgumentNullException ("info");
+                       id = (string) info.GetValue ("Id", typeof (string));
+                       displayName = (string) info.GetValue ("DisplayName", typeof (string));
+                       standardDisplayName = (string) info.GetValue ("StandardName", typeof (string));
+                       daylightDisplayName = (string) info.GetValue ("DaylightName", typeof (string));
+                       baseUtcOffset = (TimeSpan) info.GetValue ("BaseUtcOffset", typeof (TimeSpan));
+                       adjustmentRules = (TimeZoneInfo.AdjustmentRule []) info.GetValue ("AdjustmentRules", typeof (TimeZoneInfo.AdjustmentRule []));
+                       supportsDaylightSavingTime = (bool) info.GetValue ("SupportsDaylightSavingTime", typeof (bool));
+               }
+
                private TimeZoneInfo (string id, TimeSpan baseUtcOffset, string displayName, string standardDisplayName, string daylightDisplayName, TimeZoneInfo.AdjustmentRule [] adjustmentRules, bool disableDaylightSavingTime)
                {
                        if (id == null)
index 6fd2412f9678039dbe10a9fd17437b2989abae87..e9b0d6f1a8e3e8b503c867112e25aa9f028c1bea 100644 (file)
@@ -1,4 +1,6 @@
 using System;
+using System.IO;
+using System.Runtime.Serialization.Formatters.Binary;
 using NUnit.Framework;
 
 #if NET_2_0
@@ -89,7 +91,28 @@ namespace MonoTests.System
                                TimeZoneInfo.TransitionTime daylightTransitionEnd = TimeZoneInfo.TransitionTime.CreateFixedDateRule (new DateTime (1,1,1,2,0,0), 10, 11);
                                TimeZoneInfo.AdjustmentRule.CreateAdjustmentRule (dateStart, dateEnd, new TimeSpan (55), daylightTransitionStart, daylightTransitionEnd);
                        }
-               }       
+               }
+       
+               [TestFixture]
+               public class NonExceptional
+               {
+                       [Test]
+                       public void Serialization_Deserialization ()
+                       {
+                               TimeZoneInfo.TransitionTime start = TimeZoneInfo.TransitionTime.CreateFloatingDateRule (new DateTime (1,1,1,1,0,0), 3, 5, DayOfWeek.Sunday);
+                               TimeZoneInfo.TransitionTime end = TimeZoneInfo.TransitionTime.CreateFloatingDateRule (new DateTime (1,1,1,2,0,0), 10, 5, DayOfWeek.Sunday);
+                               TimeZoneInfo.AdjustmentRule rule = TimeZoneInfo.AdjustmentRule.CreateAdjustmentRule (DateTime.MinValue.Date, DateTime.MaxValue.Date, new TimeSpan (1,0,0), start, end);
+                               MemoryStream stream = new MemoryStream ();
+                               BinaryFormatter formatter = new BinaryFormatter ();
+                               formatter.Serialize (stream, rule);
+                               stream.Position = 0;
+                               TimeZoneInfo.AdjustmentRule deserialized = (TimeZoneInfo.AdjustmentRule) formatter.Deserialize (stream);
+                               stream.Close ();
+                               stream.Dispose ();
+
+                               Assert.IsTrue (rule.Equals (deserialized));
+                       }
+               }
        }       
 }
 #endif
index 8dd8263fd223fb82fdb01679173c6c948460538e..38fdac701451664a1f9a7aa9408ab7a82c9d8c51 100644 (file)
@@ -1,5 +1,7 @@
 
 using System;
+using System.IO;
+using System.Runtime.Serialization.Formatters.Binary;
 using NUnit.Framework;
 
 #if NET_2_0
@@ -106,6 +108,34 @@ namespace MonoTests.System
                                Assert.IsFalse (tt2.Equals (tt1), "1!=2");
                                Assert.IsFalse (tt1.Equals (tt2), "2!=1");
                        }
+                       
+                       [Test]
+                       public void Serialize_Deserialize_FloatingDateRule ()
+                       {
+                               TimeZoneInfo.TransitionTime floatingDateRule = TimeZoneInfo.TransitionTime.CreateFloatingDateRule(new DateTime(1, 1, 1, 1, 0, 0), 3, 5, DayOfWeek.Sunday);
+                               MemoryStream stream = new MemoryStream ();
+                               BinaryFormatter formatter = new BinaryFormatter ();
+                               formatter.Serialize (stream, floatingDateRule);
+                               stream.Position = 0;
+                               TimeZoneInfo.TransitionTime deserialized = (TimeZoneInfo.TransitionTime) formatter.Deserialize (stream);
+                               stream.Close ();
+                               stream.Dispose ();
+                               Assert.AreEqual (floatingDateRule, deserialized);
+                       }
+
+                       [Test]
+                       public void Serialize_Deserialize_FixedDateRule ()
+                       {
+                               TimeZoneInfo.TransitionTime fixedDateRule = TimeZoneInfo.TransitionTime.CreateFixedDateRule(new DateTime(1, 1, 1, 1, 0, 0), 3, 12);
+                               MemoryStream stream = new MemoryStream ();
+                               BinaryFormatter formatter = new BinaryFormatter ();
+                               formatter.Serialize (stream, fixedDateRule);
+                               stream.Position = 0;
+                               TimeZoneInfo.TransitionTime deserialized = (TimeZoneInfo.TransitionTime) formatter.Deserialize (stream);
+                               stream.Close ();
+                               stream.Dispose ();
+                               Assert.AreEqual (fixedDateRule, deserialized);
+                       }
                }
        }
 }
index 06de33e9ab7262167833ebc8d6cf178b04c4713f..da26842ead4a0ababb1a9f219cad8fc1e52bb928 100644 (file)
@@ -27,6 +27,8 @@
  */
 
 using System;
+using System.IO;
+using System.Runtime.Serialization.Formatters.Binary;
 using System.Collections;
 
 using NUnit.Framework;
@@ -657,6 +659,27 @@ namespace MonoTests.System
                                Assert.IsTrue (utc.HasSameRules (custom));
                        }
                }
+
+               [TestFixture]
+               public class SerializationTests
+               {
+                       [Test]
+                       public void Serialization_Deserialization ()
+                       {
+                               TimeZoneInfo.TransitionTime start = TimeZoneInfo.TransitionTime.CreateFloatingDateRule (new DateTime (1,1,1,1,0,0), 3, 5, DayOfWeek.Sunday);
+                               TimeZoneInfo.TransitionTime end = TimeZoneInfo.TransitionTime.CreateFloatingDateRule (new DateTime (1,1,1,2,0,0), 10, 5, DayOfWeek.Sunday);
+                               TimeZoneInfo.AdjustmentRule rule = TimeZoneInfo.AdjustmentRule.CreateAdjustmentRule (DateTime.MinValue.Date, DateTime.MaxValue.Date, new TimeSpan (1,0,0), start, end);
+                               TimeZoneInfo london = TimeZoneInfo.CreateCustomTimeZone ("Europe/London", new TimeSpan (0), "Europe/London", "British Standard Time", "British Summer Time", new TimeZoneInfo.AdjustmentRule [] {rule});
+                               MemoryStream stream = new MemoryStream ();
+                               BinaryFormatter formatter = new BinaryFormatter ();
+                               formatter.Serialize (stream, london);
+                               stream.Position = 0;
+                               TimeZoneInfo deserialized = (TimeZoneInfo) formatter.Deserialize (stream);
+                               stream.Close ();
+                               stream.Dispose ();
+                               Assert.AreEqual (london, deserialized);
+                       }
+               }
        }
 }
 #endif
diff --git a/mcs/class/System.Core/mobile_static_System.Core.dll.sources b/mcs/class/System.Core/mobile_static_System.Core.dll.sources
new file mode 100644 (file)
index 0000000..55e204a
--- /dev/null
@@ -0,0 +1,7 @@
+#include mobile_System.Core.dll.sources
+#include static_System.Core.dll.sources
+System.Linq.jvm/Conversion.cs
+System.Linq.jvm/ExpressionInterpreter.cs
+System.Linq.jvm/Runner.cs
+System.Linq.jvm/Math.cs
+System/TimeZoneInfo.MonoTouch.cs
diff --git a/mcs/class/System.Data.Services.Client/mobile_static_System.Data.Services.Client.dll.sources b/mcs/class/System.Data.Services.Client/mobile_static_System.Data.Services.Client.dll.sources
new file mode 100644 (file)
index 0000000..37dc299
--- /dev/null
@@ -0,0 +1 @@
+#include net_4_5_System.Data.Services.Client.dll.sources
index b015667e2a174c0be56c1ea56add35aedde74eae..8255e6456d6a582e6f87ddf5142663675f4fa80d 100644 (file)
@@ -31,7 +31,7 @@ LIB_MCS_FLAGS +=      \
        -r:J2SE.Helpers.dll                     \
        $(OTHER_LIB_MCS_FLAGS)
 else 
-MOBILE := $(filter monotouch monodroid mobile, $(PROFILE))
+MOBILE := $(filter monotouch monodroid mobile mobile_static, $(PROFILE))
 ifdef MOBILE
 LIB_MCS_FLAGS += \
        -r:Mono.Data.Tds.dll \
index 29e7b11efc1e3f05e274a1dbc8136a0681672a67..4beb429284e81a5fc21211781e10810a2a121754 100644 (file)
@@ -23,7 +23,9 @@
 using System;
 using System.Collections;
 using System.Reflection;
+#if !FULL_AOT_RUNTIME
 using System.Reflection.Emit;
+#endif
 
 namespace System.Data.Common
 {
index abd8126d092b33d4bda8548c7df89b137dced674..ece2e96518dda786e68703345c8b0c573d1cb355 100644 (file)
@@ -287,7 +287,7 @@ namespace System.Data
                {
                        if (row == null)
                                throw new IndexOutOfRangeException ("The given datarow is not in the current DataRowCollection.");
-                       int index = List.IndexOf (row);
+                       int index = this.IndexOf (row);
                        if (index < 0)
                                throw new IndexOutOfRangeException ("The given datarow is not in the current DataRowCollection.");
                        List.RemoveAt (index);
diff --git a/mcs/class/System.Data/mobile_static_System.Data.dll.sources b/mcs/class/System.Data/mobile_static_System.Data.dll.sources
new file mode 100644 (file)
index 0000000..bbc860b
--- /dev/null
@@ -0,0 +1 @@
+#include mobile_System.Data.dll.sources
index dc61855ee01bc81667d007549871fbcbeb1bd5fe..aba9cdd34a8584977b370791392b3b76e582b09e 100644 (file)
@@ -14,16 +14,6 @@ using System.Security;
 using System.Runtime.CompilerServices;
 using System.Runtime.InteropServices;
 
-// General Information about the System.DirectoryServices.Protocols assembly
-
-using System;
-using System.Reflection;
-using System.Resources;
-using System.Security;
-using System.Diagnostics;
-using System.Runtime.CompilerServices;
-using System.Runtime.InteropServices;
-
 // General Information about the system assembly
 
 [assembly: AssemblyTitle ("System.DirectoryServices.Protocols.dll")]
index 66471e0eb86b9fe101d383f891086fcba83b7c09..f020637d1ce2f5c5c79623159c5b409044311826 100644 (file)
@@ -27,7 +27,6 @@
 //
 
 using System;
-using System.Linq;
 
 namespace System.DirectoryServices.Protocols
 {
@@ -37,8 +36,8 @@ namespace System.DirectoryServices.Protocols
                public SortRequestControl (params SortKey [] sortKeys)
                        : base (null, null, false, false)
                {
-                       throw new NotImplementedException ();
                        SortKeys = sortKeys;
+                       throw new NotImplementedException ();
                }
 
                [MonoTODO]
index dfa5533dffb831c070f9074bb957f81b4db1e9c3..69ac1dab5d07f2a4ff9464d002c1b4a3b8f83df7 100644 (file)
@@ -27,7 +27,6 @@
 //
 
 using System;
-using System.Linq;
 
 namespace System.DirectoryServices.Protocols
 {
@@ -36,12 +35,12 @@ namespace System.DirectoryServices.Protocols
                internal VlvResponseControl (int contentCount, byte [] contextId, ResultCode result, int targetPosition)
                        : base (null, null, false, true)
                {
-                       throw new NotImplementedException ("ctor-chain");
-
                        ContentCount = contentCount;
                        ContextId = contextId;
                        Result = result;
                        TargetPosition = targetPosition;
+
+                       throw new NotImplementedException ("ctor-chain");
                }
 
                [MonoTODO]
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchema.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchema.cs
new file mode 100644 (file)
index 0000000..a2fdc83
--- /dev/null
@@ -0,0 +1,112 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class ActiveDirectorySchema : ActiveDirectoryPartition
+       {
+               public DirectoryServer SchemaRoleOwner {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               protected override void Dispose (bool disposing)
+               {
+
+               }
+
+               public static ActiveDirectorySchema GetSchema (DirectoryContext context)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void RefreshSchema ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ActiveDirectorySchemaClass FindClass (string ldapDisplayName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ActiveDirectorySchemaClass FindDefunctClass (string commonName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReadOnlyActiveDirectorySchemaClassCollection FindAllClasses ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReadOnlyActiveDirectorySchemaClassCollection FindAllClasses (SchemaClassType type)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReadOnlyActiveDirectorySchemaClassCollection FindAllDefunctClasses ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ActiveDirectorySchemaProperty FindProperty (string ldapDisplayName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ActiveDirectorySchemaProperty FindDefunctProperty (string commonName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReadOnlyActiveDirectorySchemaPropertyCollection FindAllProperties ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReadOnlyActiveDirectorySchemaPropertyCollection FindAllProperties (PropertyTypes type)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReadOnlyActiveDirectorySchemaPropertyCollection FindAllDefunctProperties ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override DirectoryEntry GetDirectoryEntry ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public static ActiveDirectorySchema GetCurrentSchema ()
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaClass.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaClass.cs
new file mode 100644 (file)
index 0000000..6af613f
--- /dev/null
@@ -0,0 +1,179 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class ActiveDirectorySchemaClass : IDisposable
+       {
+               public string Name {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string CommonName {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string Oid {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string Description {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool IsDefunct {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySchemaClassCollection PossibleSuperiors {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ReadOnlyActiveDirectorySchemaClassCollection PossibleInferiors {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySchemaPropertyCollection MandatoryProperties {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySchemaPropertyCollection OptionalProperties {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySchemaClassCollection AuxiliaryClasses {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySchemaClass SubClassOf {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public SchemaClassType Type {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public Guid SchemaGuid {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySecurity DefaultObjectSecurityDescriptor {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySchemaClass (DirectoryContext context, string ldapDisplayName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Dispose ()
+               {
+
+               }
+
+               protected virtual void Dispose (bool disposing)
+               {
+
+               }
+
+               public static ActiveDirectorySchemaClass FindByName (DirectoryContext context, string ldapDisplayName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReadOnlyActiveDirectorySchemaPropertyCollection GetAllProperties ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Save ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public override string ToString ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DirectoryEntry GetDirectoryEntry ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaClassCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaClassCollection.cs
new file mode 100644 (file)
index 0000000..fb30942
--- /dev/null
@@ -0,0 +1,108 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ActiveDirectorySchemaClassCollection : CollectionBase
+       {
+               public ActiveDirectorySchemaClass this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int Add (ActiveDirectorySchemaClass schemaClass)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void AddRange (ActiveDirectorySchemaClass[] schemaClasses)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void AddRange (ActiveDirectorySchemaClassCollection schemaClasses)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void AddRange (ReadOnlyActiveDirectorySchemaClassCollection schemaClasses)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Remove (ActiveDirectorySchemaClass schemaClass)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Insert (int index, ActiveDirectorySchemaClass schemaClass)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public bool Contains (ActiveDirectorySchemaClass schemaClass)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ActiveDirectorySchemaClass[] schemaClasses, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ActiveDirectorySchemaClass schemaClass)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnClearComplete ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnInsertComplete (int index, object value)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnRemoveComplete (int index, object value)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnSetComplete (int index, object oldValue, object newValue)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnValidate (object value)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaProperty.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaProperty.cs
new file mode 100644 (file)
index 0000000..8819ec5
--- /dev/null
@@ -0,0 +1,220 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class ActiveDirectorySchemaProperty : IDisposable
+       {
+               public string Name {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string CommonName {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string Oid {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySyntax Syntax {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string Description {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool IsSingleValued {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool IsIndexed {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool IsIndexedOverContainer {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool IsInAnr {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool IsOnTombstonedObject {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool IsTupleIndexed {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool IsInGlobalCatalog {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int RangeLower {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int RangeUpper {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool IsDefunct {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySchemaProperty Link {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int? LinkId {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public Guid SchemaGuid {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySchemaProperty (DirectoryContext context, string ldapDisplayName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Dispose ()
+               {
+               }
+
+               protected virtual void Dispose (bool disposing)
+               {
+
+               }
+
+               public static ActiveDirectorySchemaProperty FindByName (DirectoryContext context, string ldapDisplayName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Save ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public override string ToString ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DirectoryEntry GetDirectoryEntry ()
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaPropertyCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaPropertyCollection.cs
new file mode 100644 (file)
index 0000000..b8721b4
--- /dev/null
@@ -0,0 +1,108 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ActiveDirectorySchemaPropertyCollection : CollectionBase
+       {
+               public ActiveDirectorySchemaProperty this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int Add (ActiveDirectorySchemaProperty schemaProperty)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void AddRange (ActiveDirectorySchemaProperty[] properties)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void AddRange (ActiveDirectorySchemaPropertyCollection properties)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void AddRange (ReadOnlyActiveDirectorySchemaPropertyCollection properties)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Remove (ActiveDirectorySchemaProperty schemaProperty)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Insert (int index, ActiveDirectorySchemaProperty schemaProperty)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public bool Contains (ActiveDirectorySchemaProperty schemaProperty)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ActiveDirectorySchemaProperty[] properties, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ActiveDirectorySchemaProperty schemaProperty)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnClearComplete ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnInsertComplete (int index, object value)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnRemoveComplete (int index, object value)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnSetComplete (int index, object oldValue, object newValue)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnValidate (object value)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySecurity.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySecurity.cs
new file mode 100644 (file)
index 0000000..d921144
--- /dev/null
@@ -0,0 +1,147 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.AccessControl;
+using System.Security.Principal;
+
+namespace System.DirectoryServices
+{
+       public class ActiveDirectorySecurity : DirectoryObjectSecurity
+       {
+               public override Type AccessRightType {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public override Type AccessRuleType {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public override Type AuditRuleType {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySecurity ()
+               {
+               }
+
+               public void AddAccessRule (ActiveDirectoryAccessRule rule)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void SetAccessRule (ActiveDirectoryAccessRule rule)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void ResetAccessRule (ActiveDirectoryAccessRule rule)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void RemoveAccess (IdentityReference identity, AccessControlType type)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public bool RemoveAccessRule (ActiveDirectoryAccessRule rule)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void RemoveAccessRuleSpecific (ActiveDirectoryAccessRule rule)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public override bool ModifyAccessRule (AccessControlModification modification, AccessRule rule, out bool modified)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public override void PurgeAccessRules (IdentityReference identity)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void AddAuditRule (ActiveDirectoryAuditRule rule)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void SetAuditRule (ActiveDirectoryAuditRule rule)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void RemoveAudit (IdentityReference identity)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public bool RemoveAuditRule (ActiveDirectoryAuditRule rule)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void RemoveAuditRuleSpecific (ActiveDirectoryAuditRule rule)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public override bool ModifyAuditRule (AccessControlModification modification, AuditRule rule, out bool modified)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public override void PurgeAuditRules (IdentityReference identity)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public sealed override AccessRule AccessRuleFactory (IdentityReference identityReference, int accessMask, bool isInherited, InheritanceFlags inheritanceFlags, PropagationFlags propagationFlags, AccessControlType type)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public sealed override AccessRule AccessRuleFactory (IdentityReference identityReference, int accessMask, bool isInherited, InheritanceFlags inheritanceFlags, PropagationFlags propagationFlags, AccessControlType type, Guid objectGuid, Guid inheritedObjectGuid)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public sealed override AuditRule AuditRuleFactory (IdentityReference identityReference, int accessMask, bool isInherited, InheritanceFlags inheritanceFlags, PropagationFlags propagationFlags, AuditFlags flags)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public sealed override AuditRule AuditRuleFactory (IdentityReference identityReference, int accessMask, bool isInherited, InheritanceFlags inheritanceFlags, PropagationFlags propagationFlags, AuditFlags flags, Guid objectGuid, Guid inheritedObjectGuid)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectoryServerDownException.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectoryServerDownException.cs
new file mode 100644 (file)
index 0000000..93fc26e
--- /dev/null
@@ -0,0 +1,80 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Serialization;
+using System.Security.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [Serializable]
+       public class ActiveDirectoryServerDownException : Exception, ISerializable
+       {
+               public int ErrorCode {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string Name {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public override string Message {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectoryServerDownException (string message, Exception inner, int errorCode, string name) : base(message, inner)
+               {
+               }
+
+               public ActiveDirectoryServerDownException (string message, int errorCode, string name) : base(message)
+               {
+
+               }
+
+               public ActiveDirectoryServerDownException (string message, Exception inner) : base(message, inner)
+               {
+               }
+
+               public ActiveDirectoryServerDownException (string message) : base(message)
+               {
+               }
+
+               public ActiveDirectoryServerDownException ()
+               {
+               }
+
+               protected ActiveDirectoryServerDownException (SerializationInfo info, StreamingContext context) : base(info, context)
+               {
+               }
+
+               [SecurityPermission(SecurityAction.Demand, SerializationFormatter = true)]
+               public override void GetObjectData (SerializationInfo serializationInfo, StreamingContext streamingContext)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySite.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySite.cs
new file mode 100644 (file)
index 0000000..1c03b05
--- /dev/null
@@ -0,0 +1,166 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Security.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class ActiveDirectorySite : IDisposable
+       {
+               public string Name {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DomainCollection Domains {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySubnetCollection Subnets {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ReadOnlyDirectoryServerCollection Servers {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ReadOnlySiteCollection AdjacentSites {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ReadOnlySiteLinkCollection SiteLinks {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DirectoryServer InterSiteTopologyGenerator {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySiteOptions Options {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string Location {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ReadOnlyDirectoryServerCollection BridgeheadServers {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DirectoryServerCollection PreferredSmtpBridgeheadServers {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DirectoryServerCollection PreferredRpcBridgeheadServers {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySchedule IntraSiteReplicationSchedule {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public static ActiveDirectorySite FindByName (DirectoryContext context, string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ActiveDirectorySite (DirectoryContext context, string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public static ActiveDirectorySite GetComputerSite ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Save ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Delete ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public override string ToString ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DirectoryEntry GetDirectoryEntry ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Dispose ()
+               {
+
+               }
+
+               protected virtual void Dispose (bool disposing)
+               {
+
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteCollection.cs
new file mode 100644 (file)
index 0000000..4df5579
--- /dev/null
@@ -0,0 +1,103 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ActiveDirectorySiteCollection : CollectionBase
+       {
+               public ActiveDirectorySite this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int Add (ActiveDirectorySite site)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void AddRange (ActiveDirectorySite[] sites)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void AddRange (ActiveDirectorySiteCollection sites)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public bool Contains (ActiveDirectorySite site)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ActiveDirectorySite[] array, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ActiveDirectorySite site)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Insert (int index, ActiveDirectorySite site)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Remove (ActiveDirectorySite site)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnClearComplete ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnInsertComplete (int index, object value)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnRemoveComplete (int index, object value)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnSetComplete (int index, object oldValue, object newValue)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnValidate (object value)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteLink.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteLink.cs
new file mode 100644 (file)
index 0000000..0a230d5
--- /dev/null
@@ -0,0 +1,153 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Security.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class ActiveDirectorySiteLink : IDisposable
+       {
+               public string Name {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectoryTransportType TransportType {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySiteCollection Sites {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int Cost {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public TimeSpan ReplicationInterval {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool ReciprocalReplicationEnabled {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool NotificationEnabled {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool DataCompressionEnabled {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySchedule InterSiteReplicationSchedule {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySiteLink (DirectoryContext context, string siteLinkName) : this(context, siteLinkName, ActiveDirectoryTransportType.Rpc, null)
+               {
+               }
+
+               public ActiveDirectorySiteLink (DirectoryContext context, string siteLinkName, ActiveDirectoryTransportType transport) : this(context, siteLinkName, transport, null)
+               {
+               }
+
+               public ActiveDirectorySiteLink (DirectoryContext context, string siteLinkName, ActiveDirectoryTransportType transport, ActiveDirectorySchedule schedule)
+               {
+               }
+
+               public static ActiveDirectorySiteLink FindByName (DirectoryContext context, string siteLinkName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public static ActiveDirectorySiteLink FindByName (DirectoryContext context, string siteLinkName, ActiveDirectoryTransportType transport)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Save ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Delete ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public override string ToString ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DirectoryEntry GetDirectoryEntry ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Dispose ()
+               {
+               }
+
+               protected virtual void Dispose (bool disposing)
+               {
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteLinkBridge.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteLinkBridge.cs
new file mode 100644 (file)
index 0000000..54679eb
--- /dev/null
@@ -0,0 +1,97 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Security.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class ActiveDirectorySiteLinkBridge : IDisposable
+       {
+               public string Name {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySiteLinkCollection SiteLinks {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectoryTransportType TransportType {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySiteLinkBridge (DirectoryContext context, string bridgeName) : this(context, bridgeName, ActiveDirectoryTransportType.Rpc)
+               {
+               }
+
+               public ActiveDirectorySiteLinkBridge (DirectoryContext context, string bridgeName, ActiveDirectoryTransportType transport)
+               {
+
+               }
+
+               public static ActiveDirectorySiteLinkBridge FindByName (DirectoryContext context, string bridgeName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public static ActiveDirectorySiteLinkBridge FindByName (DirectoryContext context, string bridgeName, ActiveDirectoryTransportType transport)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Save ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Delete ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public override string ToString ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DirectoryEntry GetDirectoryEntry ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Dispose ()
+               {
+               }
+
+               protected virtual void Dispose (bool disposing)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteLinkCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteLinkCollection.cs
new file mode 100644 (file)
index 0000000..2079076
--- /dev/null
@@ -0,0 +1,103 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ActiveDirectorySiteLinkCollection : CollectionBase
+       {
+               public ActiveDirectorySiteLink this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int Add (ActiveDirectorySiteLink link)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void AddRange (ActiveDirectorySiteLink[] links)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void AddRange (ActiveDirectorySiteLinkCollection links)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public bool Contains (ActiveDirectorySiteLink link)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ActiveDirectorySiteLink[] array, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ActiveDirectorySiteLink link)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Insert (int index, ActiveDirectorySiteLink link)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Remove (ActiveDirectorySiteLink link)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnClearComplete ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnInsertComplete (int index, object value)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnRemoveComplete (int index, object value)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnSetComplete (int index, object oldValue, object newValue)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnValidate (object value)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySubnet.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySubnet.cs
new file mode 100644 (file)
index 0000000..674aeb5
--- /dev/null
@@ -0,0 +1,98 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class ActiveDirectorySubnet : IDisposable
+       {
+               public string Name {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySite Site {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string Location {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public static ActiveDirectorySubnet FindByName (DirectoryContext context, string subnetName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ActiveDirectorySubnet (DirectoryContext context, string subnetName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ActiveDirectorySubnet (DirectoryContext context, string subnetName, string siteName) : this(context, subnetName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Save ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Delete ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public override string ToString ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DirectoryEntry GetDirectoryEntry ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Dispose ()
+               {
+
+               }
+
+               protected virtual void Dispose (bool disposing)
+               {
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySubnetCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ActiveDirectorySubnetCollection.cs
new file mode 100644 (file)
index 0000000..70ed679
--- /dev/null
@@ -0,0 +1,108 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ActiveDirectorySubnetCollection : CollectionBase
+       {
+               public ActiveDirectorySubnet this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int Add (ActiveDirectorySubnet subnet)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void AddRange (ActiveDirectorySubnet[] subnets)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void AddRange (ActiveDirectorySubnetCollection subnets)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public bool Contains (ActiveDirectorySubnet subnet)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ActiveDirectorySubnet[] array, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ActiveDirectorySubnet subnet)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Insert (int index, ActiveDirectorySubnet subnet)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Remove (ActiveDirectorySubnet subnet)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnClear ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnClearComplete ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnInsertComplete (int index, object value)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnRemoveComplete (int index, object value)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnSetComplete (int index, object oldValue, object newValue)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnValidate (object value)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ApplicationPartition.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ApplicationPartition.cs
new file mode 100644 (file)
index 0000000..c8910b9
--- /dev/null
@@ -0,0 +1,126 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class ApplicationPartition : ActiveDirectoryPartition
+       {
+               public DirectoryServerCollection DirectoryServers {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string SecurityReferenceDomain {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ApplicationPartition (DirectoryContext context, string distinguishedName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ApplicationPartition (DirectoryContext context, string distinguishedName, string objectClass)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void Dispose (bool disposing)
+               {
+
+               }
+
+               public static ApplicationPartition GetApplicationPartition (DirectoryContext context)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public static ApplicationPartition FindByName (DirectoryContext context, string distinguishedName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DirectoryServer FindDirectoryServer ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DirectoryServer FindDirectoryServer (string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DirectoryServer FindDirectoryServer (bool forceRediscovery)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DirectoryServer FindDirectoryServer (string siteName, bool forceRediscovery)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReadOnlyDirectoryServerCollection FindAllDirectoryServers ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReadOnlyDirectoryServerCollection FindAllDirectoryServers (string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReadOnlyDirectoryServerCollection FindAllDiscoverableDirectoryServers ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReadOnlyDirectoryServerCollection FindAllDiscoverableDirectoryServers (string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Delete ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Save ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override DirectoryEntry GetDirectoryEntry ()
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ApplicationPartitionCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ApplicationPartitionCollection.cs
new file mode 100644 (file)
index 0000000..78cae10
--- /dev/null
@@ -0,0 +1,50 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ApplicationPartitionCollection : ReadOnlyCollectionBase
+       {
+               public ApplicationPartition this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (ApplicationPartition applicationPartition)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ApplicationPartition applicationPartition)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ApplicationPartition[] applicationPartitions, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DirectoryContext.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DirectoryContext.cs
new file mode 100644 (file)
index 0000000..b9129c0
--- /dev/null
@@ -0,0 +1,74 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Net;
+using System.Security.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [EnvironmentPermission(SecurityAction.Assert, Unrestricted = true)]
+       public class DirectoryContext
+       {
+               public string Name {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string UserName {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DirectoryContextType ContextType {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               [DirectoryServicesPermission(SecurityAction.Demand, Unrestricted = true)]
+               public DirectoryContext (DirectoryContextType contextType)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.Demand, Unrestricted = true)]
+               public DirectoryContext (DirectoryContextType contextType, string name)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.Demand, Unrestricted = true)]
+               public DirectoryContext (DirectoryContextType contextType, string username, string password)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.Demand, Unrestricted = true)]
+               public DirectoryContext (DirectoryContextType contextType, string name, string username, string password)
+               {
+                       throw new NotImplementedException ();
+               }
+
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DirectoryEntryConfiguration.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DirectoryEntryConfiguration.cs
new file mode 100644 (file)
index 0000000..074e672
--- /dev/null
@@ -0,0 +1,90 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Permissions;
+
+namespace System.DirectoryServices
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class DirectoryEntryConfiguration
+       {
+               public ReferralChasingOption Referral {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public SecurityMasks SecurityMasks {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int PageSize {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int PasswordPort {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public PasswordEncodingMethod PasswordEncoding {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string GetCurrentServerName ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public bool IsMutuallyAuthenticated ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void SetUserNameQueryQuota (string accountName)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DirectoryServer.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DirectoryServer.cs
new file mode 100644 (file)
index 0000000..c32a7cd
--- /dev/null
@@ -0,0 +1,131 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public abstract class DirectoryServer : IDisposable
+       {
+               public string Name {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ReadOnlyStringCollection Partitions {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public abstract string IPAddress {
+                       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+                       get;
+               }
+
+               public abstract string SiteName {
+                       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+                       get;
+               }
+
+               public abstract SyncUpdateCallback SyncFromAllServersCallback {
+                       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+                       get;
+                       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+                       set;
+               }
+
+               public abstract ReplicationConnectionCollection InboundConnections {
+                       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+                       get;
+               }
+
+               public abstract ReplicationConnectionCollection OutboundConnections {
+                       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+                       get;
+               }
+
+               internal DirectoryContext Context {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public void Dispose ()
+               {
+
+               }
+
+               protected virtual void Dispose (bool disposing)
+               {
+
+               }
+
+               public override string ToString ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void MoveToAnotherSite (string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DirectoryEntry GetDirectoryEntry ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public abstract void CheckReplicationConsistency ();
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public abstract ReplicationCursorCollection GetReplicationCursors (string partition);
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public abstract ReplicationOperationInformation GetReplicationOperationInformation ();
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public abstract ReplicationNeighborCollection GetReplicationNeighbors (string partition);
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public abstract ReplicationNeighborCollection GetAllReplicationNeighbors ();
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public abstract ReplicationFailureCollection GetReplicationConnectionFailures ();
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public abstract ActiveDirectoryReplicationMetadata GetReplicationMetadata (string objectPath);
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public abstract void SyncReplicaFromServer (string partition, string sourceServer);
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public abstract void TriggerSyncReplicaFromNeighbors (string partition);
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public abstract void SyncReplicaFromAllServers (string partition, SyncFromAllServersOptions options);
+       }
+
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DirectoryServerCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DirectoryServerCollection.cs
new file mode 100644 (file)
index 0000000..d5b2fa8
--- /dev/null
@@ -0,0 +1,103 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class DirectoryServerCollection : CollectionBase
+       {
+               public DirectoryServer this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int Add (DirectoryServer server)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void AddRange (DirectoryServer[] servers)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public bool Contains (DirectoryServer server)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (DirectoryServer[] array, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (DirectoryServer server)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Insert (int index, DirectoryServer server)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Remove (DirectoryServer server)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnClear ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnClearComplete ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnInsertComplete (int index, object value)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnRemoveComplete (int index, object value)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnSetComplete (int index, object oldValue, object newValue)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected override void OnValidate (object value)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/Domain.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/Domain.cs
new file mode 100644 (file)
index 0000000..c35a8f9
--- /dev/null
@@ -0,0 +1,224 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class Domain : ActiveDirectoryPartition
+       {
+               public Forest Forest {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DomainControllerCollection DomainControllers {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DomainCollection Children {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DomainMode DomainMode {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public Domain Parent {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DomainController PdcRoleOwner {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DomainController RidRoleOwner {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DomainController InfrastructureRoleOwner {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public static Domain GetDomain (DirectoryContext context)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public static Domain GetComputerDomain ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void RaiseDomainFunctionality (DomainMode domainMode)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DomainController FindDomainController ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DomainController FindDomainController (string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DomainController FindDomainController (LocatorOptions flag)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DomainController FindDomainController (string siteName, LocatorOptions flag)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DomainControllerCollection FindAllDomainControllers ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DomainControllerCollection FindAllDomainControllers (string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DomainControllerCollection FindAllDiscoverableDomainControllers ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DomainControllerCollection FindAllDiscoverableDomainControllers (string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override DirectoryEntry GetDirectoryEntry ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public TrustRelationshipInformationCollection GetAllTrustRelationships ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public TrustRelationshipInformation GetTrustRelationship (string targetDomainName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public bool GetSelectiveAuthenticationStatus (string targetDomainName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void SetSelectiveAuthenticationStatus (string targetDomainName, bool enable)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public bool GetSidFilteringStatus (string targetDomainName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void SetSidFilteringStatus (string targetDomainName, bool enable)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void DeleteLocalSideOfTrustRelationship (string targetDomainName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void DeleteTrustRelationship (Domain targetDomain)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void VerifyOutboundTrustRelationship (string targetDomainName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void VerifyTrustRelationship (Domain targetDomain, TrustDirection direction)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CreateLocalSideOfTrustRelationship (string targetDomainName, TrustDirection direction, string trustPassword)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CreateTrustRelationship (Domain targetDomain, TrustDirection direction)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void UpdateLocalSideOfTrustRelationship (string targetDomainName, string newTrustPassword)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void UpdateLocalSideOfTrustRelationship (string targetDomainName, TrustDirection newTrustDirection, string newTrustPassword)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void UpdateTrustRelationship (Domain targetDomain, TrustDirection newTrustDirection)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void RepairTrustRelationship (Domain targetDomain)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public static Domain GetCurrentDomain ()
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DomainCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DomainCollection.cs
new file mode 100644 (file)
index 0000000..d6108c9
--- /dev/null
@@ -0,0 +1,50 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class DomainCollection : ReadOnlyCollectionBase
+       {
+               public Domain this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (Domain domain)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (Domain domain)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (Domain[] domains, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DomainCollisionOptions.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DomainCollisionOptions.cs
new file mode 100644 (file)
index 0000000..ccb4351
--- /dev/null
@@ -0,0 +1,34 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices.ActiveDirectory
+{
+       [Flags]
+       public enum DomainCollisionOptions
+       {
+               None = 0,
+               SidDisabledByAdmin = 1,
+               SidDisabledByConflict = 2,
+               NetBiosNameDisabledByAdmin = 4,
+               NetBiosNameDisabledByConflict = 8
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DomainController.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DomainController.cs
new file mode 100644 (file)
index 0000000..5279b34
--- /dev/null
@@ -0,0 +1,240 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Net;
+using System.Security.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class DomainController : DirectoryServer
+       {
+               public Forest Forest {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DateTime CurrentTime {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public long HighestCommittedUsn {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string OSVersion {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectoryRoleCollection Roles {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public Domain Domain {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public override string IPAddress {
+                       [DnsPermission(SecurityAction.Assert, Unrestricted = true), DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public override string SiteName {
+                       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public override SyncUpdateCallback SyncFromAllServersCallback {
+                       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public override ReplicationConnectionCollection InboundConnections {
+                       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public override ReplicationConnectionCollection OutboundConnections {
+                       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               protected DomainController ()
+               {
+               }
+
+               protected override void Dispose (bool disposing)
+               {
+                       base.Dispose ();
+
+               }
+
+               public static DomainController GetDomainController (DirectoryContext context)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public static DomainController FindOne (DirectoryContext context)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public static DomainController FindOne (DirectoryContext context, string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public static DomainController FindOne (DirectoryContext context, LocatorOptions flag)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public static DomainController FindOne (DirectoryContext context, string siteName, LocatorOptions flag)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public static DomainControllerCollection FindAll (DirectoryContext context)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public static DomainControllerCollection FindAll (DirectoryContext context, string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public virtual GlobalCatalog EnableGlobalCatalog ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public virtual bool IsGlobalCatalog ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void TransferRoleOwnership (ActiveDirectoryRole role)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void SeizeRoleOwnership (ActiveDirectoryRole role)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public virtual DirectorySearcher GetDirectorySearcher ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override void CheckReplicationConsistency ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override ReplicationCursorCollection GetReplicationCursors (string partition)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override ReplicationOperationInformation GetReplicationOperationInformation ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override ReplicationNeighborCollection GetReplicationNeighbors (string partition)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override ReplicationNeighborCollection GetAllReplicationNeighbors ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override ReplicationFailureCollection GetReplicationConnectionFailures ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override ActiveDirectoryReplicationMetadata GetReplicationMetadata (string objectPath)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override void SyncReplicaFromServer (string partition, string sourceServer)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override void TriggerSyncReplicaFromNeighbors (string partition)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override void SyncReplicaFromAllServers (string partition, SyncFromAllServersOptions options)
+               {
+                       throw new NotImplementedException ();
+               }
+
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DomainControllerCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/DomainControllerCollection.cs
new file mode 100644 (file)
index 0000000..309854b
--- /dev/null
@@ -0,0 +1,50 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class DomainControllerCollection : ReadOnlyCollectionBase
+       {
+               public DomainController this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (DomainController domainController)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (DomainController domainController)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (DomainController[] domainControllers, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/Forest.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/Forest.cs
new file mode 100644 (file)
index 0000000..d8ff1f9
--- /dev/null
@@ -0,0 +1,240 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class Forest : IDisposable
+       {
+               public string Name {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ReadOnlySiteCollection Sites {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DomainCollection Domains {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public GlobalCatalogCollection GlobalCatalogs {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ApplicationPartitionCollection ApplicationPartitions {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ForestMode ForestMode {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public Domain RootDomain {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySchema Schema {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DomainController SchemaRoleOwner {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DomainController NamingRoleOwner {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public void Dispose ()
+               {
+                       this.Dispose (true);
+               }
+
+               protected void Dispose (bool disposing)
+               {
+
+               }
+
+               public static Forest GetForest (DirectoryContext context)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void RaiseForestFunctionality (ForestMode forestMode)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public override string ToString ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public GlobalCatalog FindGlobalCatalog ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public GlobalCatalog FindGlobalCatalog (string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public GlobalCatalog FindGlobalCatalog (LocatorOptions flag)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public GlobalCatalog FindGlobalCatalog (string siteName, LocatorOptions flag)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public GlobalCatalogCollection FindAllGlobalCatalogs ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public GlobalCatalogCollection FindAllGlobalCatalogs (string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public GlobalCatalogCollection FindAllDiscoverableGlobalCatalogs ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public GlobalCatalogCollection FindAllDiscoverableGlobalCatalogs (string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public TrustRelationshipInformationCollection GetAllTrustRelationships ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ForestTrustRelationshipInformation GetTrustRelationship (string targetForestName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public bool GetSelectiveAuthenticationStatus (string targetForestName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void SetSelectiveAuthenticationStatus (string targetForestName, bool enable)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public bool GetSidFilteringStatus (string targetForestName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void SetSidFilteringStatus (string targetForestName, bool enable)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void DeleteLocalSideOfTrustRelationship (string targetForestName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void DeleteTrustRelationship (Forest targetForest)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void VerifyOutboundTrustRelationship (string targetForestName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void VerifyTrustRelationship (Forest targetForest, TrustDirection direction)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CreateLocalSideOfTrustRelationship (string targetForestName, TrustDirection direction, string trustPassword)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CreateTrustRelationship (Forest targetForest, TrustDirection direction)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void UpdateLocalSideOfTrustRelationship (string targetForestName, string newTrustPassword)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void UpdateLocalSideOfTrustRelationship (string targetForestName, TrustDirection newTrustDirection, string newTrustPassword)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void UpdateTrustRelationship (Forest targetForest, TrustDirection newTrustDirection)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void RepairTrustRelationship (Forest targetForest)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public static Forest GetCurrentForest ()
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustCollisionException.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustCollisionException.cs
new file mode 100644 (file)
index 0000000..fb07459
--- /dev/null
@@ -0,0 +1,64 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Serialization;
+using System.Security.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [Serializable]
+       public class ForestTrustCollisionException : ActiveDirectoryOperationException, ISerializable
+       {
+               public ForestTrustRelationshipCollisionCollection Collisions {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ForestTrustCollisionException (string message, Exception inner, ForestTrustRelationshipCollisionCollection collisions) : base(message, inner)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ForestTrustCollisionException (string message, Exception inner) : base(message, inner)
+               {
+               }
+
+               public ForestTrustCollisionException (string message) : base(message)
+               {
+               }
+
+               public ForestTrustCollisionException () : base("ForestTrustCollision")
+               {
+               }
+
+               protected ForestTrustCollisionException (SerializationInfo info, StreamingContext context) : base(info, context)
+               {
+               }
+
+               [SecurityPermission(SecurityAction.Demand, SerializationFormatter = true)]
+               public override void GetObjectData (SerializationInfo serializationInfo, StreamingContext streamingContext)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustCollisionType.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustCollisionType.cs
new file mode 100644 (file)
index 0000000..b31f9a0
--- /dev/null
@@ -0,0 +1,31 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices.ActiveDirectory
+{
+       public enum ForestTrustCollisionType
+       {
+               TopLevelName,
+               Domain,
+               Other
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustDomainInfoCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustDomainInfoCollection.cs
new file mode 100644 (file)
index 0000000..2761323
--- /dev/null
@@ -0,0 +1,51 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ForestTrustDomainInfoCollection : ReadOnlyCollectionBase
+       {
+               public ForestTrustDomainInformation this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (ForestTrustDomainInformation information)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ForestTrustDomainInformation information)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ForestTrustDomainInformation[] array, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustDomainInformation.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustDomainInformation.cs
new file mode 100644 (file)
index 0000000..a5cd4b7
--- /dev/null
@@ -0,0 +1,55 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices.ActiveDirectory
+{
+       public class ForestTrustDomainInformation
+       {
+               public string DnsName {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string NetBiosName {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string DomainSid {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ForestTrustDomainStatus Status {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustRelationshipCollision.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustRelationshipCollision.cs
new file mode 100644 (file)
index 0000000..0f81191
--- /dev/null
@@ -0,0 +1,51 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices.ActiveDirectory
+{
+       public class ForestTrustRelationshipCollision
+       {
+               public ForestTrustCollisionType CollisionType {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public TopLevelNameCollisionOptions TopLevelNameCollisionOption {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DomainCollisionOptions DomainCollisionOption {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string CollisionRecord {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustRelationshipCollisionCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustRelationshipCollisionCollection.cs
new file mode 100644 (file)
index 0000000..95279c3
--- /dev/null
@@ -0,0 +1,50 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ForestTrustRelationshipCollisionCollection : ReadOnlyCollectionBase
+       {
+               public ForestTrustRelationshipCollision this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (ForestTrustRelationshipCollision collision)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ForestTrustRelationshipCollision collision)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ForestTrustRelationshipCollision[] array, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustRelationshipInformation.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ForestTrustRelationshipInformation.cs
new file mode 100644 (file)
index 0000000..e6c72b9
--- /dev/null
@@ -0,0 +1,54 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Specialized;
+using System.Security.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class ForestTrustRelationshipInformation : TrustRelationshipInformation
+       {
+               public TopLevelNameCollection TopLevelNames {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public StringCollection ExcludedTopLevelNames {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ForestTrustDomainInfoCollection TrustedDomainInformation {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public void Save ()
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/GlobalCatalog.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/GlobalCatalog.cs
new file mode 100644 (file)
index 0000000..c3d816b
--- /dev/null
@@ -0,0 +1,95 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Security.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class GlobalCatalog : DomainController
+       {
+               public static GlobalCatalog GetGlobalCatalog (DirectoryContext context)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public new static GlobalCatalog FindOne (DirectoryContext context)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public new static GlobalCatalog FindOne (DirectoryContext context, string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public new static GlobalCatalog FindOne (DirectoryContext context, LocatorOptions flag)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public new static GlobalCatalog FindOne (DirectoryContext context, string siteName, LocatorOptions flag)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public new static GlobalCatalogCollection FindAll (DirectoryContext context)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public new static GlobalCatalogCollection FindAll (DirectoryContext context, string siteName)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override GlobalCatalog EnableGlobalCatalog ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DomainController DisableGlobalCatalog ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override bool IsGlobalCatalog ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReadOnlyActiveDirectorySchemaPropertyCollection FindAllProperties ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true), DirectoryServicesPermission(SecurityAction.InheritanceDemand, Unrestricted = true)]
+               public override DirectorySearcher GetDirectorySearcher ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/GlobalCatalogCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/GlobalCatalogCollection.cs
new file mode 100644 (file)
index 0000000..9725e7e
--- /dev/null
@@ -0,0 +1,51 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class GlobalCatalogCollection : ReadOnlyCollectionBase
+       {
+               public GlobalCatalog this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (GlobalCatalog globalCatalog)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (GlobalCatalog globalCatalog)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (GlobalCatalog[] globalCatalogs, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlyActiveDirectorySchemaClassCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlyActiveDirectorySchemaClassCollection.cs
new file mode 100644 (file)
index 0000000..5690994
--- /dev/null
@@ -0,0 +1,50 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ReadOnlyActiveDirectorySchemaClassCollection : ReadOnlyCollectionBase
+       {
+               public ActiveDirectorySchemaClass this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (ActiveDirectorySchemaClass schemaClass)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ActiveDirectorySchemaClass schemaClass)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ActiveDirectorySchemaClass[] classes, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlyActiveDirectorySchemaPropertyCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlyActiveDirectorySchemaPropertyCollection.cs
new file mode 100644 (file)
index 0000000..e7ecf7e
--- /dev/null
@@ -0,0 +1,50 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ReadOnlyActiveDirectorySchemaPropertyCollection : ReadOnlyCollectionBase
+       {
+               public ActiveDirectorySchemaProperty this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (ActiveDirectorySchemaProperty schemaProperty)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ActiveDirectorySchemaProperty schemaProperty)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ActiveDirectorySchemaProperty[] properties, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlyDirectoryServerCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlyDirectoryServerCollection.cs
new file mode 100644 (file)
index 0000000..a30a4a9
--- /dev/null
@@ -0,0 +1,50 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ReadOnlyDirectoryServerCollection : ReadOnlyCollectionBase
+       {
+               public DirectoryServer this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (DirectoryServer directoryServer)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (DirectoryServer directoryServer)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (DirectoryServer[] directoryServers, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlySiteCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlySiteCollection.cs
new file mode 100644 (file)
index 0000000..52e8e9b
--- /dev/null
@@ -0,0 +1,50 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ReadOnlySiteCollection : ReadOnlyCollectionBase
+       {
+               public ActiveDirectorySite this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (ActiveDirectorySite site)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ActiveDirectorySite site)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ActiveDirectorySite[] sites, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlySiteLinkBridgeCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlySiteLinkBridgeCollection.cs
new file mode 100644 (file)
index 0000000..c73f604
--- /dev/null
@@ -0,0 +1,50 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ReadOnlySiteLinkBridgeCollection : ReadOnlyCollectionBase
+       {
+               public ActiveDirectorySiteLinkBridge this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (ActiveDirectorySiteLinkBridge bridge)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ActiveDirectorySiteLinkBridge bridge)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ActiveDirectorySiteLinkBridge[] bridges, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlySiteLinkCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReadOnlySiteLinkCollection.cs
new file mode 100644 (file)
index 0000000..cef4f67
--- /dev/null
@@ -0,0 +1,50 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ReadOnlySiteLinkCollection : ReadOnlyCollectionBase
+       {
+               public ActiveDirectorySiteLink this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (ActiveDirectorySiteLink link)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ActiveDirectorySiteLink link)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ActiveDirectorySiteLink[] links, int index)
+               {
+                       base.InnerList.CopyTo (links, index);
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationConnection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationConnection.cs
new file mode 100644 (file)
index 0000000..1976330
--- /dev/null
@@ -0,0 +1,181 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.ComponentModel;
+using System.Runtime.InteropServices;
+using System.Security.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [DirectoryServicesPermission(SecurityAction.LinkDemand, Unrestricted = true)]
+       public class ReplicationConnection : IDisposable
+       {
+               public string Name {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string SourceServer {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string DestinationServer {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Enabled {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectoryTransportType TransportType {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool GeneratedByKcc {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool ReciprocalReplicationEnabled {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public NotificationStatus ChangeNotificationStatus {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool DataCompressionEnabled {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool ReplicationScheduleOwnedByUser {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ReplicationSpan ReplicationSpan {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySchedule ReplicationSchedule {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public static ReplicationConnection FindByName (DirectoryContext context, string name)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReplicationConnection (DirectoryContext context, string name, DirectoryServer sourceServer) : this(context, name, sourceServer, null, ActiveDirectoryTransportType.Rpc)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReplicationConnection (DirectoryContext context, string name, DirectoryServer sourceServer, ActiveDirectorySchedule schedule) : this(context, name, sourceServer, schedule, ActiveDirectoryTransportType.Rpc)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReplicationConnection (DirectoryContext context, string name, DirectoryServer sourceServer, ActiveDirectoryTransportType transport) : this(context, name, sourceServer, null, transport)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public ReplicationConnection (DirectoryContext context, string name, DirectoryServer sourceServer, ActiveDirectorySchedule schedule, ActiveDirectoryTransportType transport)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Dispose ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected virtual void Dispose (bool disposing)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Delete ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void Save ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public override string ToString ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DirectoryEntry GetDirectoryEntry ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationConnectionCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationConnectionCollection.cs
new file mode 100644 (file)
index 0000000..b46a2b4
--- /dev/null
@@ -0,0 +1,51 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ReplicationConnectionCollection : ReadOnlyCollectionBase
+       {
+               public ReplicationConnection this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (ReplicationConnection connection)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ReplicationConnection connection)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ReplicationConnection[] connections, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationCursor.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationCursor.cs
new file mode 100644 (file)
index 0000000..7a50391
--- /dev/null
@@ -0,0 +1,60 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.DirectoryServices.ActiveDirectory
+{
+       public class ReplicationCursor
+       {
+               public string PartitionName {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public Guid SourceInvocationId {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public long UpToDatenessUsn {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string SourceServer {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DateTime LastSuccessfulSyncTime {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+       }
+}
\ No newline at end of file
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationCursorCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationCursorCollection.cs
new file mode 100644 (file)
index 0000000..d14e35b
--- /dev/null
@@ -0,0 +1,48 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ReplicationCursorCollection : ReadOnlyCollectionBase
+       {
+               public ReplicationCursor this [int index] {
+                       get { throw new NotImplementedException (); }
+               }
+
+               public bool Contains (ReplicationCursor cursor)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ReplicationCursor cursor)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ReplicationCursor[] values, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationFailure.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationFailure.cs
new file mode 100644 (file)
index 0000000..39291b7
--- /dev/null
@@ -0,0 +1,59 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ReplicationFailure
+       {
+               public string SourceServer {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DateTime FirstFailureTime {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int ConsecutiveFailureCount {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int LastErrorCode {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string LastErrorMessage {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationFailureCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationFailureCollection.cs
new file mode 100644 (file)
index 0000000..4b55b86
--- /dev/null
@@ -0,0 +1,53 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ReplicationFailureCollection : ReadOnlyCollectionBase
+       {
+               public ReplicationFailure this[int index]
+               {
+                       get
+                       {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains(ReplicationFailure failure)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf(ReplicationFailure failure)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo(ReplicationFailure[] failures, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationNeighborCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationNeighborCollection.cs
new file mode 100644 (file)
index 0000000..aac4f9a
--- /dev/null
@@ -0,0 +1,50 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ReplicationNeighborCollection : ReadOnlyCollectionBase
+       {
+               public ReplicationNeighbor this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (ReplicationNeighbor neighbor)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ReplicationNeighbor neighbor)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ReplicationNeighbor[] neighbors, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationOperation.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationOperation.cs
new file mode 100644 (file)
index 0000000..b5af673
--- /dev/null
@@ -0,0 +1,65 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ReplicationOperation
+       {
+               public DateTime TimeEnqueued {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int OperationNumber {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int Priority {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ReplicationOperationType OperationType {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string PartitionName {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string SourceServer {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationOperationCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationOperationCollection.cs
new file mode 100644 (file)
index 0000000..a8a1326
--- /dev/null
@@ -0,0 +1,56 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class ReplicationOperationCollection : ReadOnlyCollectionBase
+       {
+               public ReplicationOperation this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (ReplicationOperation operation)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (ReplicationOperation operation)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (ReplicationOperation[] operations, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               private int Add (ReplicationOperation operation)
+               {
+                       throw new NotImplementedException ();
+               }
+
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationOperationInformation.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationOperationInformation.cs
new file mode 100644 (file)
index 0000000..50325a0
--- /dev/null
@@ -0,0 +1,46 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices.ActiveDirectory
+{
+       public class ReplicationOperationInformation
+       {
+               public DateTime OperationStartTime {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ReplicationOperation CurrentOperation {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ReplicationOperationCollection PendingOperations {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationSecurityLevel.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/ReplicationSecurityLevel.cs
new file mode 100644 (file)
index 0000000..17b6a72
--- /dev/null
@@ -0,0 +1,31 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices.ActiveDirectory
+{
+       public enum ReplicationSecurityLevel
+       {
+               MutualAuthentication = 2,
+               Negotiate = 1,
+               NegotiatePassThrough = 0
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/SecurityMasks.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/SecurityMasks.cs
new file mode 100644 (file)
index 0000000..fb66892
--- /dev/null
@@ -0,0 +1,34 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices
+{
+       [Flags]
+       public enum SecurityMasks
+       {
+               None = 0,
+               Owner = 1,
+               Group = 2,
+               Dacl = 4,
+               Sacl = 8
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/SyncFromAllServersErrorInformation.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/SyncFromAllServersErrorInformation.cs
new file mode 100644 (file)
index 0000000..4d97002
--- /dev/null
@@ -0,0 +1,59 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices.ActiveDirectory
+{
+       public class SyncFromAllServersErrorInformation
+       {
+               public SyncFromAllServersErrorCategory ErrorCategory {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public int ErrorCode {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string ErrorMessage {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string TargetServer {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string SourceServer {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/SyncFromAllServersOperationException.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/SyncFromAllServersOperationException.cs
new file mode 100644 (file)
index 0000000..16d2544
--- /dev/null
@@ -0,0 +1,68 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.Serialization;
+using System.Security.Permissions;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       [Serializable]
+       public class SyncFromAllServersOperationException : ActiveDirectoryOperationException, ISerializable
+       {
+               public SyncFromAllServersErrorInformation[] ErrorInformation {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public SyncFromAllServersOperationException (string message, Exception inner, SyncFromAllServersErrorInformation[] errors) : base(message, inner)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public SyncFromAllServersOperationException (string message, Exception inner) : base(message, inner)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public SyncFromAllServersOperationException (string message) : base(message)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public SyncFromAllServersOperationException () : base("DSSyncAllFailure")
+               {
+                       throw new NotImplementedException ();
+               }
+
+               protected SyncFromAllServersOperationException (SerializationInfo info, StreamingContext context) : base(info, context)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [SecurityPermission(SecurityAction.Demand, SerializationFormatter = true)]
+               public override void GetObjectData (SerializationInfo serializationInfo, StreamingContext streamingContext)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/SyncUpdateCallback.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/SyncUpdateCallback.cs
new file mode 100644 (file)
index 0000000..a9546fe
--- /dev/null
@@ -0,0 +1,28 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices.ActiveDirectory
+{
+       public delegate bool SyncUpdateCallback(SyncFromAllServersEvent eventType, string targetServer, string sourceServer, SyncFromAllServersOperationException exception);
+}
\ No newline at end of file
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TopLevelName.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TopLevelName.cs
new file mode 100644 (file)
index 0000000..f3e9663
--- /dev/null
@@ -0,0 +1,43 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices.ActiveDirectory
+{
+       public class TopLevelName
+       {
+               public string Name {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public TopLevelNameStatus Status {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TopLevelNameCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TopLevelNameCollection.cs
new file mode 100644 (file)
index 0000000..709212a
--- /dev/null
@@ -0,0 +1,50 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class TopLevelNameCollection : ReadOnlyCollectionBase
+       {
+               public TopLevelName this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (TopLevelName name)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (TopLevelName name)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (TopLevelName[] names, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TopLevelNameCollisionOptions.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TopLevelNameCollisionOptions.cs
new file mode 100644 (file)
index 0000000..8f74903
--- /dev/null
@@ -0,0 +1,34 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices.ActiveDirectory
+{
+       [Flags]
+       public enum TopLevelNameCollisionOptions
+       {
+               None = 0,
+               NewlyCreated = 1,
+               DisabledByAdmin = 2,
+               DisabledByConflict = 4
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TrustRelationshipInformation.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TrustRelationshipInformation.cs
new file mode 100644 (file)
index 0000000..4dfcbb2
--- /dev/null
@@ -0,0 +1,52 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices.ActiveDirectory
+{
+       public class TrustRelationshipInformation
+       {
+               public string SourceName {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string TargetName {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public TrustType TrustType {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public TrustDirection TrustDirection {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TrustRelationshipInformationCollection.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices.ActiveDirectory/TrustRelationshipInformationCollection.cs
new file mode 100644 (file)
index 0000000..39dfff9
--- /dev/null
@@ -0,0 +1,50 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+
+namespace System.DirectoryServices.ActiveDirectory
+{
+       public class TrustRelationshipInformationCollection : ReadOnlyCollectionBase
+       {
+               public TrustRelationshipInformation this [int index] {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public bool Contains (TrustRelationshipInformation information)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public int IndexOf (TrustRelationshipInformation information)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void CopyTo (TrustRelationshipInformation[] array, int index)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
index 9794c093977e6420e1389bf97bf61d845bc215e2..0c18dadf88dde6d43525590b73ecb4f772a77605 100644 (file)
@@ -1,17 +1,33 @@
 Assembly/AssemblyInfo.cs
 ../../build/common/Consts.cs.in
 ../../build/common/Locale.cs
+System.DirectoryServices/ActiveDirectoryAccessRule.cs
+System.DirectoryServices/ActiveDirectoryAuditRule.cs
+System.DirectoryServices/ActiveDirectoryRights.cs
+System.DirectoryServices/ActiveDirectorySecurityInheritance.cs
 System.DirectoryServices/AuthenticationTypes.cs
 System.DirectoryServices/DirectoryEntries.cs
 System.DirectoryServices/DirectoryEntry.cs
 System.DirectoryServices/DirectorySearcher.cs
+System.DirectoryServices/DirectoryServicesCOMException.cs
 System.DirectoryServices/DirectoryServicesPermission.cs
 System.DirectoryServices/DirectoryServicesPermissionAccess.cs
 System.DirectoryServices/DirectoryServicesPermissionAttribute.cs
 System.DirectoryServices/DirectoryServicesPermissionEntry.cs
 System.DirectoryServices/DirectoryServicesPermissionEntryCollection.cs
+System.DirectoryServices/DirectorySynchronization.cs
+System.DirectoryServices/DirectorySynchronizationOptions.cs
+System.DirectoryServices/DirectoryVirtualListView.cs
+System.DirectoryServices/DirectoryVirtualListViewContext.cs
 System.DirectoryServices/DSDescriptionAttribute.cs
+System.DirectoryServices/ExtendedDN.cs
+System.DirectoryServices/ExtendedRightAccessRule.cs
+System.DirectoryServices/ListChildrenAccessRule.cs
+System.DirectoryServices/PasswordEncodingMethod.cs
+System.DirectoryServices/PropertyAccess.cs
+System.DirectoryServices/PropertyAccessRule.cs
 System.DirectoryServices/PropertyCollection.cs
+System.DirectoryServices/PropertySetAccessRule.cs
 System.DirectoryServices/PropertyValueCollection.cs
 System.DirectoryServices/ReferralChasingOption.cs
 System.DirectoryServices/ResultPropertyCollection.cs
@@ -24,34 +40,95 @@ System.DirectoryServices/SortDirection.cs
 System.DirectoryServices/SortOption.cs
 ../../build/common/MonoTODOAttribute.cs
 System.DirectoryServices.Design/DirectoryEntryConverter.cs
-System.DirectoryServices.ActiveDirectory/ActiveDirectoryRole.cs
 System.DirectoryServices.ActiveDirectory/ActiveDirectoryOperationException.cs
 System.DirectoryServices.ActiveDirectory/ActiveDirectoryPartition.cs
 System.DirectoryServices.ActiveDirectory/ActiveDirectoryReplicationMetadata.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectoryRole.cs
 System.DirectoryServices.ActiveDirectory/ActiveDirectoryRoleCollection.cs
 System.DirectoryServices.ActiveDirectory/ActiveDirectorySchedule.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectorySchema.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaClass.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaClassCollection.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaProperty.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectorySchemaPropertyCollection.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectorySecurity.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectoryServerDownException.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectorySite.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteCollection.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteLink.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteLinkBridge.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteLinkCollection.cs
 System.DirectoryServices.ActiveDirectory/ActiveDirectorySiteOptions.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectorySubnet.cs
+System.DirectoryServices.ActiveDirectory/ActiveDirectorySubnetCollection.cs
 System.DirectoryServices.ActiveDirectory/ActiveDirectorySyntax.cs
 System.DirectoryServices.ActiveDirectory/ActiveDirectoryTransportType.cs
+System.DirectoryServices.ActiveDirectory/ApplicationPartition.cs
+System.DirectoryServices.ActiveDirectory/ApplicationPartitionCollection.cs
 System.DirectoryServices.ActiveDirectory/AttributeMetadata.cs
 System.DirectoryServices.ActiveDirectory/AttributeMetadataCollection.cs
+System.DirectoryServices.ActiveDirectory/DirectoryContext.cs
 System.DirectoryServices.ActiveDirectory/DirectoryContextType.cs
+System.DirectoryServices.ActiveDirectory/DirectoryEntryConfiguration.cs
+System.DirectoryServices.ActiveDirectory/DirectoryServer.cs
+System.DirectoryServices.ActiveDirectory/DirectoryServerCollection.cs
+System.DirectoryServices.ActiveDirectory/Domain.cs
+System.DirectoryServices.ActiveDirectory/DomainCollection.cs
+System.DirectoryServices.ActiveDirectory/DomainController.cs
+System.DirectoryServices.ActiveDirectory/DomainControllerCollection.cs
 System.DirectoryServices.ActiveDirectory/DomainMode.cs
+System.DirectoryServices.ActiveDirectory/DomainCollisionOptions.cs
+System.DirectoryServices.ActiveDirectory/Forest.cs
 System.DirectoryServices.ActiveDirectory/ForestMode.cs
+System.DirectoryServices.ActiveDirectory/ForestTrustCollisionException.cs
+System.DirectoryServices.ActiveDirectory/ForestTrustCollisionType.cs
+System.DirectoryServices.ActiveDirectory/ForestTrustDomainInformation.cs
+System.DirectoryServices.ActiveDirectory/ForestTrustDomainInfoCollection.cs
 System.DirectoryServices.ActiveDirectory/ForestTrustDomainStatus.cs
+System.DirectoryServices.ActiveDirectory/ForestTrustRelationshipCollision.cs
+System.DirectoryServices.ActiveDirectory/ForestTrustRelationshipCollisionCollection.cs
+System.DirectoryServices.ActiveDirectory/ForestTrustRelationshipInformation.cs
+System.DirectoryServices.ActiveDirectory/GlobalCatalog.cs
+System.DirectoryServices.ActiveDirectory/GlobalCatalogCollection.cs
 System.DirectoryServices.ActiveDirectory/HourOfDay.cs
 System.DirectoryServices.ActiveDirectory/LocatorOptions.cs
 System.DirectoryServices.ActiveDirectory/MinuteOfHour.cs
 System.DirectoryServices.ActiveDirectory/NotificationStatus.cs
 System.DirectoryServices.ActiveDirectory/PropertyTypes.cs
+System.DirectoryServices.ActiveDirectory/ReadOnlyActiveDirectorySchemaClassCollection.cs
+System.DirectoryServices.ActiveDirectory/ReadOnlyActiveDirectorySchemaPropertyCollection.cs
+System.DirectoryServices.ActiveDirectory/ReadOnlyDirectoryServerCollection.cs
+System.DirectoryServices.ActiveDirectory/ReadOnlySiteCollection.cs
+System.DirectoryServices.ActiveDirectory/ReadOnlySiteLinkBridgeCollection.cs
+System.DirectoryServices.ActiveDirectory/ReadOnlySiteLinkCollection.cs
 System.DirectoryServices.ActiveDirectory/ReadOnlyStringCollection.cs
+System.DirectoryServices.ActiveDirectory/ReplicationConnection.cs
+System.DirectoryServices.ActiveDirectory/ReplicationConnectionCollection.cs
+System.DirectoryServices.ActiveDirectory/ReplicationCursor.cs
+System.DirectoryServices.ActiveDirectory/ReplicationCursorCollection.cs
+System.DirectoryServices.ActiveDirectory/ReplicationFailure.cs
+System.DirectoryServices.ActiveDirectory/ReplicationFailureCollection.cs
 System.DirectoryServices.ActiveDirectory/ReplicationNeighbor.cs
+System.DirectoryServices.ActiveDirectory/ReplicationNeighborCollection.cs
+System.DirectoryServices.ActiveDirectory/ReplicationOperation.cs
+System.DirectoryServices.ActiveDirectory/ReplicationOperationCollection.cs
+System.DirectoryServices.ActiveDirectory/ReplicationOperationInformation.cs
 System.DirectoryServices.ActiveDirectory/ReplicationOperationType.cs
+System.DirectoryServices.ActiveDirectory/ReplicationSecurityLevel.cs
 System.DirectoryServices.ActiveDirectory/ReplicationSpan.cs
 System.DirectoryServices.ActiveDirectory/SchemaClassType.cs
+System.DirectoryServices.ActiveDirectory/SecurityMasks.cs
 System.DirectoryServices.ActiveDirectory/SyncFromAllServersErrorCategory.cs
+System.DirectoryServices.ActiveDirectory/SyncFromAllServersErrorInformation.cs
 System.DirectoryServices.ActiveDirectory/SyncFromAllServersEvent.cs
+System.DirectoryServices.ActiveDirectory/SyncFromAllServersOperationException.cs
 System.DirectoryServices.ActiveDirectory/SyncFromAllServersOptions.cs
+System.DirectoryServices.ActiveDirectory/SyncUpdateCallback.cs
+System.DirectoryServices.ActiveDirectory/TopLevelNameCollisionOptions.cs
+System.DirectoryServices.ActiveDirectory/TopLevelName.cs
+System.DirectoryServices.ActiveDirectory/TopLevelNameCollection.cs
 System.DirectoryServices.ActiveDirectory/TopLevelNameStatus.cs
 System.DirectoryServices.ActiveDirectory/TrustDirection.cs
+System.DirectoryServices.ActiveDirectory/TrustRelationshipInformation.cs
+System.DirectoryServices.ActiveDirectory/TrustRelationshipInformationCollection.cs
 System.DirectoryServices.ActiveDirectory/TrustType.cs
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/ActiveDirectoryAccessRule.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/ActiveDirectoryAccessRule.cs
new file mode 100644 (file)
index 0000000..9c85473
--- /dev/null
@@ -0,0 +1,75 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.AccessControl;
+using System.Security.Principal;
+
+namespace System.DirectoryServices
+{
+       public class ActiveDirectoryAccessRule : ObjectAccessRule
+       {
+               public ActiveDirectoryRights ActiveDirectoryRights
+               {
+                       get
+                       {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySecurityInheritance InheritanceType
+               {
+                       get
+                       {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectoryAccessRule(IdentityReference identity, ActiveDirectoryRights adRights, AccessControlType type) : this(identity, (int)adRights, type, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public ActiveDirectoryAccessRule(IdentityReference identity, ActiveDirectoryRights adRights, AccessControlType type, Guid objectType) : this(identity, (int)adRights, type, objectType, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public ActiveDirectoryAccessRule(IdentityReference identity, ActiveDirectoryRights adRights, AccessControlType type, ActiveDirectorySecurityInheritance inheritanceType) : this(identity, (int)adRights, type, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public ActiveDirectoryAccessRule(IdentityReference identity, ActiveDirectoryRights adRights, AccessControlType type, Guid objectType, ActiveDirectorySecurityInheritance inheritanceType) : this(identity, (int)adRights, type, objectType, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public ActiveDirectoryAccessRule(IdentityReference identity, ActiveDirectoryRights adRights, AccessControlType type, ActiveDirectorySecurityInheritance inheritanceType, Guid inheritedObjectType) : this(identity, (int)adRights, type, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, inheritedObjectType)
+               {
+               }
+
+               public ActiveDirectoryAccessRule(IdentityReference identity, ActiveDirectoryRights adRights, AccessControlType type, Guid objectType, ActiveDirectorySecurityInheritance inheritanceType, Guid inheritedObjectType) : this(identity, (int)adRights, type, objectType, false, InheritanceFlags.None, PropagationFlags.None, inheritedObjectType)
+               {
+               }
+
+               internal ActiveDirectoryAccessRule(IdentityReference identity, int accessMask, AccessControlType type, Guid objectType, bool isInherited, InheritanceFlags inheritanceFlags, PropagationFlags propagationFlags, Guid inheritedObjectType) : base(identity, accessMask, isInherited, inheritanceFlags, propagationFlags, objectType, inheritedObjectType, type)
+               {
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/ActiveDirectoryAuditRule.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/ActiveDirectoryAuditRule.cs
new file mode 100644 (file)
index 0000000..879ed08
--- /dev/null
@@ -0,0 +1,75 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.AccessControl;
+using System.Security.Principal;
+
+namespace System.DirectoryServices
+{
+       public class ActiveDirectoryAuditRule : ObjectAuditRule
+       {
+               public ActiveDirectoryRights ActiveDirectoryRights
+               {
+                       get
+                       {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectorySecurityInheritance InheritanceType
+               {
+                       get
+                       {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public ActiveDirectoryAuditRule(IdentityReference identity, ActiveDirectoryRights adRights, AuditFlags auditFlags) : this(identity, (int)adRights, auditFlags, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public ActiveDirectoryAuditRule(IdentityReference identity, ActiveDirectoryRights adRights, AuditFlags auditFlags, Guid objectType) : this(identity, (int)adRights, auditFlags, objectType, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public ActiveDirectoryAuditRule(IdentityReference identity, ActiveDirectoryRights adRights, AuditFlags auditFlags, ActiveDirectorySecurityInheritance inheritanceType) : this(identity, (int)adRights, auditFlags, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public ActiveDirectoryAuditRule(IdentityReference identity, ActiveDirectoryRights adRights, AuditFlags auditFlags, Guid objectType, ActiveDirectorySecurityInheritance inheritanceType) : this(identity, (int)adRights, auditFlags, objectType, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public ActiveDirectoryAuditRule(IdentityReference identity, ActiveDirectoryRights adRights, AuditFlags auditFlags, ActiveDirectorySecurityInheritance inheritanceType, Guid inheritedObjectType) : this(identity, (int)adRights, auditFlags, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, inheritedObjectType)
+               {
+               }
+
+               public ActiveDirectoryAuditRule(IdentityReference identity, ActiveDirectoryRights adRights, AuditFlags auditFlags, Guid objectType, ActiveDirectorySecurityInheritance inheritanceType, Guid inheritedObjectType) : this(identity, (int)adRights, auditFlags, objectType, false, InheritanceFlags.None, PropagationFlags.None, inheritedObjectType)
+               {
+               }
+
+               internal ActiveDirectoryAuditRule(IdentityReference identity, int accessMask, AuditFlags auditFlags, Guid objectGuid, bool isInherited, InheritanceFlags inheritanceFlags, PropagationFlags propagationFlags, Guid inheritedObjectType) : base(identity, accessMask, isInherited, inheritanceFlags, propagationFlags, objectGuid, inheritedObjectType, auditFlags)
+               {
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/ActiveDirectoryRights.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/ActiveDirectoryRights.cs
new file mode 100644 (file)
index 0000000..d8c994e
--- /dev/null
@@ -0,0 +1,50 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices
+{
+       [Flags]
+       public enum ActiveDirectoryRights
+       {
+               Delete = 65536,
+               ReadControl = 131072,
+               WriteDacl = 262144,
+               WriteOwner = 524288,
+               Synchronize = 1048576,
+               AccessSystemSecurity = 16777216,
+               GenericRead = 131220,
+               GenericWrite = 131112,
+               GenericExecute = 131076,
+               GenericAll = 983551,
+               CreateChild = 1,
+               DeleteChild = 2,
+               ListChildren = 4,
+               Self = 8,
+               ReadProperty = 16,
+               WriteProperty = 32,
+               DeleteTree = 64,
+               ListObject = 128,
+               ExtendedRight = 256
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/ActiveDirectorySecurityInheritance.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/ActiveDirectorySecurityInheritance.cs
new file mode 100644 (file)
index 0000000..6853871
--- /dev/null
@@ -0,0 +1,35 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices
+{
+       public enum ActiveDirectorySecurityInheritance
+       {
+               None,
+               All,
+               Descendents,
+               SelfAndChildren,
+               Children
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/DirectoryServicesCOMException.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/DirectoryServicesCOMException.cs
new file mode 100644 (file)
index 0000000..c163449
--- /dev/null
@@ -0,0 +1,66 @@
+/******************************************************************************
+* The MIT License
+*
+* 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;
+using System.Runtime.Serialization;
+using System.Security.Permissions;
+
+namespace System.DirectoryServices
+{
+       [Serializable]
+       public class DirectoryServicesCOMException : COMException, ISerializable
+       {
+               public int ExtendedError {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public string ExtendedErrorMessage {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DirectoryServicesCOMException ()
+               {
+               }
+
+               public DirectoryServicesCOMException (string message) : base(message)
+               {
+               }
+
+               public DirectoryServicesCOMException (string message, Exception inner) : base(message, inner)
+               {
+               }
+
+               protected DirectoryServicesCOMException (SerializationInfo info, StreamingContext context) : base(info, context)
+               {
+               }
+
+               [SecurityPermission(SecurityAction.Demand, SerializationFormatter = true)]
+               public override void GetObjectData (SerializationInfo serializationInfo, StreamingContext streamingContext)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/DirectorySynchronization.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/DirectorySynchronization.cs
new file mode 100644 (file)
index 0000000..2602807
--- /dev/null
@@ -0,0 +1,78 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.ComponentModel;
+
+namespace System.DirectoryServices
+{
+       public class DirectorySynchronization
+       {
+               [DefaultValue(DirectorySynchronizationOptions.None), DSDescription("DSDirectorySynchronizationFlag")]
+               public DirectorySynchronizationOptions Option {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DirectorySynchronization ()
+               {
+               }
+
+               public DirectorySynchronization (DirectorySynchronizationOptions option)
+               {
+               }
+
+               public DirectorySynchronization (DirectorySynchronization sync)
+               {
+               }
+
+               public DirectorySynchronization (byte[] cookie)
+               {
+               }
+
+               public DirectorySynchronization (DirectorySynchronizationOptions option, byte[] cookie)
+               {
+               }
+
+               public byte[] GetDirectorySynchronizationCookie ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public void ResetDirectorySynchronizationCookie ()
+               {
+               }
+
+               public void ResetDirectorySynchronizationCookie (byte[] cookie)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public DirectorySynchronization Copy ()
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/DirectorySynchronizationOptions.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/DirectorySynchronizationOptions.cs
new file mode 100644 (file)
index 0000000..a696064
--- /dev/null
@@ -0,0 +1,34 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices
+{
+       [Flags]
+       public enum DirectorySynchronizationOptions : long
+       {
+               None = 0L,
+               ObjectSecurity = 1L,
+               ParentsFirst = 2048L,
+               PublicDataOnly = 8192L,
+               IncrementalValues = 2147483648L
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/DirectoryVirtualListView.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/DirectoryVirtualListView.cs
new file mode 100644 (file)
index 0000000..92aa076
--- /dev/null
@@ -0,0 +1,126 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.ComponentModel;
+
+namespace System.DirectoryServices
+{
+       public class DirectoryVirtualListView
+       {
+               [DefaultValue(0), DSDescription("DSBeforeCount")]
+               public int BeforeCount {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               [DefaultValue(0), DSDescription("DSAfterCount")]
+               public int AfterCount {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               [DefaultValue(0), DSDescription("DSOffset")]
+               public int Offset {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               [DefaultValue(0), DSDescription("DSTargetPercentage")]
+               public int TargetPercentage {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               [DefaultValue("")]
+               [TypeConverter ("System.Diagnostics.Design.StringValueConverter, " + Consts.AssemblySystem_Design)]
+               [DSDescription("DSTarget")]
+               public string Target {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               [DefaultValue(0), DSDescription("DSApproximateTotal")]
+               public int ApproximateTotal {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               [DefaultValue(null), DSDescription("DSDirectoryVirtualListViewContext")]
+               public DirectoryVirtualListViewContext DirectoryVirtualListViewContext {
+                       get {
+                               throw new NotImplementedException ();
+                       }
+                       set {
+                               throw new NotImplementedException ();
+                       }
+               }
+
+               public DirectoryVirtualListView ()
+               {
+               }
+
+               public DirectoryVirtualListView (int afterCount)
+               {
+
+               }
+
+               public DirectoryVirtualListView (int beforeCount, int afterCount, int offset)
+               {
+               }
+
+               public DirectoryVirtualListView (int beforeCount, int afterCount, string target)
+               {
+               }
+
+               public DirectoryVirtualListView (int beforeCount, int afterCount, int offset, DirectoryVirtualListViewContext context)
+               {
+               }
+
+               public DirectoryVirtualListView (int beforeCount, int afterCount, string target, DirectoryVirtualListViewContext context)
+               {
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/DirectoryVirtualListViewContext.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/DirectoryVirtualListViewContext.cs
new file mode 100644 (file)
index 0000000..809fe2f
--- /dev/null
@@ -0,0 +1,36 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices
+{
+       public class DirectoryVirtualListViewContext
+       {
+               public DirectoryVirtualListViewContext ()
+               {
+               }
+
+               public DirectoryVirtualListViewContext Copy ()
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/ExtendedDN.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/ExtendedDN.cs
new file mode 100644 (file)
index 0000000..fb1a93e
--- /dev/null
@@ -0,0 +1,31 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices
+{
+       public enum ExtendedDN
+       {
+               None = -1,
+               HexString,
+               Standard
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/ExtendedRightAccessRule.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/ExtendedRightAccessRule.cs
new file mode 100644 (file)
index 0000000..742d15f
--- /dev/null
@@ -0,0 +1,54 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.AccessControl;
+using System.Security.Principal;
+
+namespace System.DirectoryServices
+{
+       public sealed class ExtendedRightAccessRule : ActiveDirectoryAccessRule
+       {
+               public ExtendedRightAccessRule (IdentityReference identity, AccessControlType type) : base(identity, 256, type, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public ExtendedRightAccessRule (IdentityReference identity, AccessControlType type, Guid extendedRightType) : base(identity, 256, type, extendedRightType, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public ExtendedRightAccessRule (IdentityReference identity, AccessControlType type, ActiveDirectorySecurityInheritance inheritanceType) : base(identity, 256, type, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public ExtendedRightAccessRule (IdentityReference identity, AccessControlType type, Guid extendedRightType, ActiveDirectorySecurityInheritance inheritanceType) : base(identity, 256, type, extendedRightType, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public ExtendedRightAccessRule (IdentityReference identity, AccessControlType type, ActiveDirectorySecurityInheritance inheritanceType, Guid inheritedObjectType) : base(identity, 256, type, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, inheritedObjectType)
+               {
+               }
+
+               public ExtendedRightAccessRule (IdentityReference identity, AccessControlType type, Guid extendedRightType, ActiveDirectorySecurityInheritance inheritanceType, Guid inheritedObjectType) : base(identity, 256, type, extendedRightType, false, InheritanceFlags.None, PropagationFlags.None, inheritedObjectType)
+               {
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/ListChildrenAccessRule.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/ListChildrenAccessRule.cs
new file mode 100644 (file)
index 0000000..03ef876
--- /dev/null
@@ -0,0 +1,42 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.AccessControl;
+using System.Security.Principal;
+
+namespace System.DirectoryServices
+{
+       public sealed class ListChildrenAccessRule : ActiveDirectoryAccessRule
+       {
+               public ListChildrenAccessRule (IdentityReference identity, AccessControlType type) : base(identity, 4, type, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public ListChildrenAccessRule (IdentityReference identity, AccessControlType type, ActiveDirectorySecurityInheritance inheritanceType) : base(identity, 4, type, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public ListChildrenAccessRule (IdentityReference identity, AccessControlType type, ActiveDirectorySecurityInheritance inheritanceType, Guid inheritedObjectType) : base(identity, 4, type, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, inheritedObjectType)
+               {
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/PasswordEncodingMethod.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/PasswordEncodingMethod.cs
new file mode 100644 (file)
index 0000000..4c5224e
--- /dev/null
@@ -0,0 +1,30 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices
+{
+       public enum PasswordEncodingMethod
+       {
+               PasswordEncodingSsl,
+               PasswordEncodingClear
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/PropertyAccess.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/PropertyAccess.cs
new file mode 100644 (file)
index 0000000..54fc88c
--- /dev/null
@@ -0,0 +1,30 @@
+/******************************************************************************
+* The MIT License
+*
+* 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 System.DirectoryServices
+{
+       public enum PropertyAccess
+       {
+               Read,
+               Write
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/PropertyAccessRule.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/PropertyAccessRule.cs
new file mode 100644 (file)
index 0000000..c890cc4
--- /dev/null
@@ -0,0 +1,54 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.AccessControl;
+using System.Security.Principal;
+
+namespace System.DirectoryServices
+{
+       public sealed class PropertyAccessRule : ActiveDirectoryAccessRule
+       {
+               public PropertyAccessRule (IdentityReference identity, AccessControlType type, PropertyAccess access) : base(identity, (int)AccessControlType.Allow, type, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public PropertyAccessRule (IdentityReference identity, AccessControlType type, PropertyAccess access, Guid propertyType) : base(identity, (int)AccessControlType.Allow, type, propertyType, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public PropertyAccessRule (IdentityReference identity, AccessControlType type, PropertyAccess access, ActiveDirectorySecurityInheritance inheritanceType) : base(identity, (int)AccessControlType.Allow, type, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public PropertyAccessRule (IdentityReference identity, AccessControlType type, PropertyAccess access, Guid propertyType, ActiveDirectorySecurityInheritance inheritanceType) : base(identity, (int)AccessControlType.Allow, type, propertyType, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public PropertyAccessRule (IdentityReference identity, AccessControlType type, PropertyAccess access, ActiveDirectorySecurityInheritance inheritanceType, Guid inheritedObjectType) : base(identity, (int)AccessControlType.Allow, type, Guid.Empty, false, InheritanceFlags.None, PropagationFlags.None, inheritedObjectType)
+               {
+               }
+
+               public PropertyAccessRule (IdentityReference identity, AccessControlType type, PropertyAccess access, Guid propertyType, ActiveDirectorySecurityInheritance inheritanceType, Guid inheritedObjectType) : base(identity, (int)AccessControlType.Allow, type, propertyType, false, InheritanceFlags.None, PropagationFlags.None, inheritedObjectType)
+               {
+               }
+       }
+}
diff --git a/mcs/class/System.DirectoryServices/System.DirectoryServices/PropertySetAccessRule.cs b/mcs/class/System.DirectoryServices/System.DirectoryServices/PropertySetAccessRule.cs
new file mode 100644 (file)
index 0000000..ab5455b
--- /dev/null
@@ -0,0 +1,42 @@
+/******************************************************************************
+* The MIT License
+*
+* 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.AccessControl;
+using System.Security.Principal;
+
+namespace System.DirectoryServices
+{
+       public sealed class PropertySetAccessRule : ActiveDirectoryAccessRule
+       {
+               public PropertySetAccessRule (IdentityReference identity, AccessControlType type, PropertyAccess access, Guid propertySetType) : base(identity, (int)AccessControlType.Allow, type, propertySetType, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public PropertySetAccessRule (IdentityReference identity, AccessControlType type, PropertyAccess access, Guid propertySetType, ActiveDirectorySecurityInheritance inheritanceType) : base(identity, (int)AccessControlType.Allow, type, propertySetType, false, InheritanceFlags.None, PropagationFlags.None, Guid.Empty)
+               {
+               }
+
+               public PropertySetAccessRule (IdentityReference identity, AccessControlType type, PropertyAccess access, Guid propertySetType, ActiveDirectorySecurityInheritance inheritanceType, Guid inheritedObjectType) : base(identity, (int)AccessControlType.Allow, type, propertySetType, false, InheritanceFlags.None, PropagationFlags.None, inheritedObjectType)
+               {
+               }
+       }
+}
diff --git a/mcs/class/System.Interactive.Async/Assembly/AssemblyInfo.cs b/mcs/class/System.Interactive.Async/Assembly/AssemblyInfo.cs
new file mode 100644 (file)
index 0000000..9db583d
--- /dev/null
@@ -0,0 +1,2 @@
+[assembly:System.Reflection.AssemblyVersion ("2.1.30214.0")]
+[assembly:System.Reflection.AssemblyFileVersion ("2.1.30214.0")]
diff --git a/mcs/class/System.Interactive.Async/Makefile b/mcs/class/System.Interactive.Async/Makefile
new file mode 100644 (file)
index 0000000..4305b34
--- /dev/null
@@ -0,0 +1,37 @@
+thisdir = class/System.Interactive.Async
+SUBDIRS = 
+include ../../build/rules.make
+
+LIBRARY = System.Interactive.Async.dll
+LIB_MCS_FLAGS = \
+               @more_build_args \
+               -r:System.dll \
+               -r:System.Core.dll
+
+ifeq (2.1, $(FRAMEWORK_VERSION))
+LIB_MCS_FLAGS += -d:NO_TASK_DELAY -d:HAS_AWAIT
+endif
+
+NET_4_5 := $(filter 4.5, $(FRAMEWORK_VERSION))
+ifdef NET_4_5
+LIB_MCS_FLAGS += -d:HAS_EDI -d:PREFERASYNC -d:PREFER_ASYNC -d:HAS_AWAIT
+endif
+
+TEST_MCS_FLAGS = $(LIB_MCS_FLAGS)
+
+EXTRA_DISTFILES = more_build_args
+
+VALID_PROFILE := $(filter monotouch monodroid net_4_0 net_4_5, $(PROFILE))
+ifndef VALID_PROFILE
+LIBRARY_NAME = dummy-System.System.Interactive.Async.dll
+NO_SIGN_ASSEMBLY = yes
+endif
+
+INSTALL_PROFILE := $(filter net_4_5, $(PROFILE))
+ifndef INSTALL_PROFILE
+NO_INSTALL = yes
+endif
+
+NO_TEST = yes
+
+include ../../build/library.make
diff --git a/mcs/class/System.Interactive.Async/System.Interactive.Async.dll.sources b/mcs/class/System.Interactive.Async/System.Interactive.Async.dll.sources
new file mode 100644 (file)
index 0000000..cf0926e
--- /dev/null
@@ -0,0 +1,17 @@
+Assembly/AssemblyInfo.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/AsyncEnumerable.Conversions.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/AsyncEnumerable.Creation.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/AsyncEnumerable.Exceptions.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/AsyncEnumerable.Generated.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/AsyncEnumerable.Single.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/AsyncEnumerable.Multiple.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/AsyncEnumerable.Aggregates.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/AsyncEnumerator.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/Disposables.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/EnumerableGrouping.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/IAsyncEnumerable.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/IAsyncEnumerator.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/IAsyncGrouping.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/IOrderedAsyncEnumerable.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/Properties/AssemblyInfo.cs
+../../../external/rx/Ix/NET/System.Interactive.Async/TaskExt.cs
diff --git a/mcs/class/System.Interactive.Async/more_build_args b/mcs/class/System.Interactive.Async/more_build_args
new file mode 100644 (file)
index 0000000..a53ee7b
--- /dev/null
@@ -0,0 +1,3 @@
+-d:SIGNED
+-delaysign
+-keyfile:../reactive.pub
diff --git a/mcs/class/System.Interactive.Providers/Assembly/AssemblyInfo.cs b/mcs/class/System.Interactive.Providers/Assembly/AssemblyInfo.cs
new file mode 100644 (file)
index 0000000..9db583d
--- /dev/null
@@ -0,0 +1,2 @@
+[assembly:System.Reflection.AssemblyVersion ("2.1.30214.0")]
+[assembly:System.Reflection.AssemblyFileVersion ("2.1.30214.0")]
diff --git a/mcs/class/System.Interactive.Providers/Makefile b/mcs/class/System.Interactive.Providers/Makefile
new file mode 100644 (file)
index 0000000..6829108
--- /dev/null
@@ -0,0 +1,38 @@
+thisdir = class/System.Interactive.Providers
+SUBDIRS = 
+include ../../build/rules.make
+
+LIBRARY = System.Interactive.Providers.dll
+LIB_MCS_FLAGS = \
+               @more_build_args \
+               -r:System.dll \
+               -r:System.Core.dll \
+               -r:System.Interactive.dll
+
+ifeq (2.1, $(FRAMEWORK_VERSION))
+LIB_MCS_FLAGS += -d:NO_TASK_DELAY -d:HAS_AWAIT
+endif
+
+NET_4_5 := $(filter 4.5, $(FRAMEWORK_VERSION))
+ifdef NET_4_5
+LIB_MCS_FLAGS += -d:HAS_EDI -d:PREFERASYNC -d:PREFER_ASYNC -d:HAS_AWAIT
+endif
+
+TEST_MCS_FLAGS = $(LIB_MCS_FLAGS)
+
+EXTRA_DISTFILES = more_build_args
+
+VALID_PROFILE := $(filter monotouch monodroid net_4_0 net_4_5, $(PROFILE))
+ifndef VALID_PROFILE
+LIBRARY_NAME = dummy-System.System.Interactive.Providers.dll
+NO_SIGN_ASSEMBLY = yes
+endif
+
+INSTALL_PROFILE := $(filter net_4_5, $(PROFILE))
+ifndef INSTALL_PROFILE
+NO_INSTALL = yes
+endif
+
+NO_TEST = yes
+
+include ../../build/library.make
diff --git a/mcs/class/System.Interactive.Providers/System.Interactive.Providers.dll.sources b/mcs/class/System.Interactive.Providers/System.Interactive.Providers.dll.sources
new file mode 100644 (file)
index 0000000..7052a97
--- /dev/null
@@ -0,0 +1,3 @@
+Assembly/AssemblyInfo.cs
+../../../external/rx/Ix/NET/System.Interactive.Providers/Properties/AssemblyInfo.cs
+../../../external/rx/Ix/NET/System.Interactive.Providers/QueryableEx.cs
diff --git a/mcs/class/System.Interactive.Providers/more_build_args b/mcs/class/System.Interactive.Providers/more_build_args
new file mode 100644 (file)
index 0000000..a53ee7b
--- /dev/null
@@ -0,0 +1,3 @@
+-d:SIGNED
+-delaysign
+-keyfile:../reactive.pub
diff --git a/mcs/class/System.Interactive/Assembly/AssemblyInfo.cs b/mcs/class/System.Interactive/Assembly/AssemblyInfo.cs
new file mode 100644 (file)
index 0000000..9db583d
--- /dev/null
@@ -0,0 +1,2 @@
+[assembly:System.Reflection.AssemblyVersion ("2.1.30214.0")]
+[assembly:System.Reflection.AssemblyFileVersion ("2.1.30214.0")]
diff --git a/mcs/class/System.Interactive/Makefile b/mcs/class/System.Interactive/Makefile
new file mode 100644 (file)
index 0000000..2d6248e
--- /dev/null
@@ -0,0 +1,37 @@
+thisdir = class/System.Interactive
+SUBDIRS = 
+include ../../build/rules.make
+
+LIBRARY = System.Interactive.dll
+LIB_MCS_FLAGS = \
+               @more_build_args \
+               -r:System.dll \
+               -r:System.Core.dll
+
+ifeq (2.1, $(FRAMEWORK_VERSION))
+LIB_MCS_FLAGS += -d:NO_TASK_DELAY -d:HAS_AWAIT
+endif
+
+NET_4_5 := $(filter 4.5, $(FRAMEWORK_VERSION))
+ifdef NET_4_5
+LIB_MCS_FLAGS += -d:HAS_EDI -d:PREFERASYNC -d:PREFER_ASYNC -d:HAS_AWAIT
+endif
+
+TEST_MCS_FLAGS = $(LIB_MCS_FLAGS)
+
+EXTRA_DISTFILES = more_build_args
+
+VALID_PROFILE := $(filter monotouch monodroid net_4_0 net_4_5, $(PROFILE))
+ifndef VALID_PROFILE
+LIBRARY_NAME = dummy-System.System.Interactive.dll
+NO_SIGN_ASSEMBLY = yes
+endif
+
+INSTALL_PROFILE := $(filter net_4_5, $(PROFILE))
+ifndef INSTALL_PROFILE
+NO_INSTALL = yes
+endif
+
+NO_TEST = yes
+
+include ../../build/library.make
diff --git a/mcs/class/System.Interactive/System.Interactive.dll.sources b/mcs/class/System.Interactive/System.Interactive.dll.sources
new file mode 100644 (file)
index 0000000..6500671
--- /dev/null
@@ -0,0 +1,9 @@
+Assembly/AssemblyInfo.cs
+../../../external/rx/Ix/NET/System.Interactive/EnumerableEx.Imperative.cs
+../../../external/rx/Ix/NET/System.Interactive/EnumerableEx.Multiple.cs
+../../../external/rx/Ix/NET/System.Interactive/EnumerableEx.Single.cs
+../../../external/rx/Ix/NET/System.Interactive/EnumerableEx.Exceptions.cs
+../../../external/rx/Ix/NET/System.Interactive/EnumerableEx.Creation.cs
+../../../external/rx/Ix/NET/System.Interactive/EnumerableEx.Buffering.cs
+../../../external/rx/Ix/NET/System.Interactive/EnumerableEx.Aggregates.cs
+../../../external/rx/Ix/NET/System.Interactive/Properties/AssemblyInfo.cs
diff --git a/mcs/class/System.Interactive/more_build_args b/mcs/class/System.Interactive/more_build_args
new file mode 100644 (file)
index 0000000..a53ee7b
--- /dev/null
@@ -0,0 +1,3 @@
+-d:SIGNED
+-delaysign
+-keyfile:../reactive.pub
index 2511171a23a93392781c2bdb4ffbfda39961545a..6dd6ee510dd7b8531f0511785aca1cd9a32dc990 100644 (file)
@@ -24,6 +24,8 @@
 // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 // THE SOFTWARE.
 
+#if NET_4_0
+
 [assembly: System.Runtime.CompilerServices.TypeForwardedToAttribute(typeof(System.Net.Cookie))]
 [assembly: System.Runtime.CompilerServices.TypeForwardedToAttribute(typeof(System.Net.CookieCollection))]
 [assembly: System.Runtime.CompilerServices.TypeForwardedToAttribute(typeof(System.Net.CookieContainer))]
@@ -45,3 +47,4 @@
 [assembly: System.Runtime.CompilerServices.TypeForwardedToAttribute(typeof(System.Net.NetworkInformation.NetworkChange))]
 [assembly: System.Runtime.CompilerServices.TypeForwardedToAttribute(typeof(System.Net.NetworkInformation.NetworkInterface))]
 
+#endif
\ No newline at end of file
index b04f9ff96640d02e4b1af3ca70733e43d223e352..dea18bab3b1e479006a36dc2f5399739a4a4ea34 100644 (file)
@@ -2,5 +2,4 @@ Assembly/AssemblyInfo.cs
 Assembly/TypeForwarders.cs
 ../../build/common/Consts.cs
 ../../build/common/MonoTODOAttribute.cs
-System.Net/DnsPermission.cs
 System.Net/IPEndPointCollection.cs
diff --git a/mcs/class/System.Net/System.Net/DnsPermission.cs b/mcs/class/System.Net/System.Net/DnsPermission.cs
deleted file mode 100644 (file)
index 16a2006..0000000
+++ /dev/null
@@ -1,72 +0,0 @@
-/******************************************************************************
-* The MIT License
-*
-* 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;
-using System.Security;
-using System.Security.Permissions;
-
-namespace System.Net
-{
-       [Serializable]
-       public sealed class DnsPermission : CodeAccessPermission, IUnrestrictedPermission
-       {
-               public DnsPermission (PermissionState state)
-               {
-
-               }
-
-               public bool IsUnrestricted ()
-               {
-                       throw new NotImplementedException ();
-               }
-
-               public override IPermission Copy ()
-               {
-                       throw new NotImplementedException ();
-               }
-
-               public override IPermission Union (IPermission target)
-               {
-                       throw new NotImplementedException ();
-               }
-
-               public override IPermission Intersect (IPermission target)
-               {
-                       throw new NotImplementedException ();
-               }
-
-               public override bool IsSubsetOf (IPermission target)
-               {
-                       throw new NotImplementedException ();
-               }
-
-               public override void FromXml (SecurityElement securityElement)
-               {
-                       throw new NotImplementedException ();
-               }
-
-               public override SecurityElement ToXml ()
-               {
-                       throw new NotImplementedException ();
-               }
-       }
-}
diff --git a/mcs/class/System.Runtime.Serialization/mobile_static_System.Runtime.Serialization.dll.sources b/mcs/class/System.Runtime.Serialization/mobile_static_System.Runtime.Serialization.dll.sources
new file mode 100644 (file)
index 0000000..6caafd4
--- /dev/null
@@ -0,0 +1 @@
+#include mobile_System.Runtime.Serialization.dll.sources
index 67aaf7db84e340a787fe08dac6fcd88c6dc0e0bb..09886796b7f73a99168a98fae347e8a1875b2c91 100644 (file)
@@ -81,10 +81,9 @@ namespace System.Runtime.Serialization.Json
                static TypeMap CreateDefaultTypeMap (Type type)
                {
                        var l = new List<TypeMapMember> ();
-                       foreach (var fi in type.GetFields ())
-                               if (!fi.IsStatic)
-                                       l.Add (new TypeMapField (fi, null));
-                       foreach (var pi in type.GetProperties ())
+                       foreach (var fi in type.GetFields (binding_flags))
+                               l.Add (new TypeMapField (fi, null));
+                       foreach (var pi in type.GetProperties (binding_flags))
                                if (pi.CanRead && pi.CanWrite && !pi.GetGetMethod ().IsStatic && pi.GetIndexParameters ().Length == 0)
                                        l.Add (new TypeMapProperty (pi, null));
                        l.Sort ((x, y) => x.Order != y.Order ? x.Order - y.Order : String.Compare (x.Name, y.Name, StringComparison.Ordinal));
@@ -116,7 +115,7 @@ namespace System.Runtime.Serialization.Json
 
                        List<TypeMapMember> members = new List<TypeMapMember> ();
 
-                       foreach (FieldInfo fi in type.GetFields (BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Instance)) {
+                       foreach (FieldInfo fi in type.GetFields (binding_flags)) {
                                if (dca != null) {
                                        object [] atts = fi.GetCustomAttributes (typeof (DataMemberAttribute), true);
                                        if (atts.Length == 0)
@@ -131,7 +130,7 @@ namespace System.Runtime.Serialization.Json
                        }
 
                        if (dca != null) {
-                               foreach (PropertyInfo pi in type.GetProperties (BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Instance)) {
+                               foreach (PropertyInfo pi in type.GetProperties (binding_flags)) {
                                        object [] atts = pi.GetCustomAttributes (typeof (DataMemberAttribute), true);
                                        if (atts.Length == 0)
                                                continue;
index 7a37a5b4e7090baae46aa81d967aebd5672f9a28..cba0fb87bc68f9089872dacf89349470fbca17f9 100644 (file)
@@ -1452,6 +1452,21 @@ namespace MonoTests.System.Runtime.Serialization.Json
                        Assert.AreEqual (1, dict.Count, "#2");
                        Assert.AreEqual ("value", dict ["key"], "#3");
                }
+               
+               [Test]
+               public void Bug13485 ()
+               {
+                       const string json = "{ \"Name\" : \"Test\", \"Value\" : \"ValueA\" }";
+
+                       string result = string.Empty;
+                       var serializer = new DataContractJsonSerializer (typeof (Bug13485Type));
+                       Bug13485Type entity;
+                       using (var stream = new MemoryStream (Encoding.UTF8.GetBytes (json)))
+                               entity = (Bug13485Type) serializer.ReadObject (stream);
+
+                       result = entity.GetValue;
+                       Assert.AreEqual ("ValueA", result, "#1");
+               }
        }
        
        public class CharTest
@@ -1762,3 +1777,16 @@ public class MyDictionary<K, V> : System.Collections.Generic.IDictionary<K, V>
        }
 }
 
+[DataContract]
+public class Bug13485Type
+{
+       [DataMember]
+       public string Name { get; set; }
+
+       [DataMember (Name = "Value")]
+       private string Value { get; set; }
+
+       public string GetValue { get { return this.Value; } }
+}
+
+
diff --git a/mcs/class/System.ServiceModel.Web/mobile_static_System.ServiceModel.Web.dll.sources b/mcs/class/System.ServiceModel.Web/mobile_static_System.ServiceModel.Web.dll.sources
new file mode 100644 (file)
index 0000000..cbea0fa
--- /dev/null
@@ -0,0 +1 @@
+#include mobile_System.ServiceModel.Web.dll.sources
index 128c5b9712c03058ed57dbb798915160e384a299..283389d59b1e1b2384ef8e9754f6f1460c82dcb1 100644 (file)
@@ -22,7 +22,7 @@
 //
 
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index c06d2478b6ee1f2703c416e576e876a2576f930e..e2eea5cfa38c289ee7a61fafd2d4824f8533449e 100644 (file)
@@ -1,6 +1,6 @@
 // created on 28/08/2004 at 17:07
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index d25686496588d416adb9a377a7ddfbb313e1092a..4bfcdec9d91efb470ed9b75d340bf818eecd9dec 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 92ddb5e954e19350cd489f2813e833f239d63b43..dac3d4efcb5e951f6525f69ad290a51966e1660c 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index b521345a869f08720fcf5f435917fc5f116fbe51..7ef31fb03e1c85a7202668031dc94ffdfadee503 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 489004e3c01318ab5fe6ec27a3835d866541a67d..2b3fdd7c2c5f59577ebd2960ce9b07ed2e265519 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 49dcb1173245b883ebad5f3f96b7791bd11f4635..be22efc420f802c281e126f69bf17cf762ae07ed 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index c60f58afe179bd4287ea451d18a126b6eb854ecd..60ad69d629837061939ffce7a9231b3d0594aae1 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index dc6d5ef364e149e7754f603024436c6216d29ef8..3cd60037c82670dda741e6142910bc94aa8a0b35 100644 (file)
@@ -1,6 +1,6 @@
 // created on 28/08/2004 at 17:30
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 4dfa1d0e4cae438879b9ad34003169dcfe954d7b..47f0dd18445393d77a9393ad04e17218d892f7ca 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Collections;
 using System.Reflection;
index 58de364d19fc25ce3ee377783538e8f86e0eaab6..7c4456c6d6bbbdb008a06c28a09c7eaa1fb5f51e 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.IO;
 using System.Collections;
index 4610f4b008f85f8045c72e1d956be84708ee3073..7370b3b033e168a2e6bb9679dceab43edac26007 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 1327d5c2c7e39e517bddfb13be0dec632687ec2c..e34884a9b5608bcff6c8f0b964db56e850244480 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.IO;
 using System.Collections;
index b2c0519f4ad20f03014369c81792ba22b07d3397..f75bc8be193a3a5542cd0633e8385b6064263109 100644 (file)
@@ -18,7 +18,7 @@
 // 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 !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.IO;
 using System.Collections;
index d7f488b91044a7907614e535981a4830b308e44a..eddce1600b912efc54347ea1559013ed40028db1 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index b9ea6dd694545b2005a9664659c33b26cbbb8869..41410e83717ca083f50ca0795732a809f0ad08f0 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 066b27930d43de95f0e9adb89a95e0b4995632d6..b090c4f1f5823c542f8261ea398ab9a72b192700 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 7beeffe455da32436543578790ef175aa29cb194..84f01b87cbba98a51b2ce47f186dcd391dc97a6b 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 123e556db631286f3511d32064f0e866d63714c1..c871b5bb518ea5eb9a04a0ee2534de9e6a317d0d 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 8f7f6bfdef6da8391170eae5a7be775cb63449ad..5d7baa343c1d45315fa9a130882056ee2a2c5cdc 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Collections;
 using System.Reflection;
index d0defd95dc8848195262e6fbae20bc31ebe7a99b..d753a6666882df96b2ec10d898b09b6b8daf36c1 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Collections;
 using System.Reflection.Emit;
index e860fd8620dcd4ebb307af2a2bc56764ce1d4de6..7355c5a94f629d7addfe0ef08fbe99fa6182369a 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 5967954dca511a28f73ce69b27f6797b5b65f72c..e2863463e53a647ff541472c388e5166fe1ca79b 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index c8f682b4e6db63e4f21dd12d5c7e91478c88f28e..356b35ba45971e94be38ca5d95d1a0245fbd7631 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 6e2586cc2ff727e11ac673edf3577a51f4406b89..f6808840d95beefc3714fbe26c0a2720fb09cdaf 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 152d7f8b9f64b1719495d87bef9416ec2099a887..90c46fe6de72316152faf2c3b024329c5f82aa19 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Globalization;
 using System.Reflection;
index 2bde317409836a89ec7d5d67af69de2d4ce52a0f..68f477ff01bb318abd44128f202b776b1d080647 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Collections;
 using System.IO;
index fc882c4c1552facbd9510d378ef2f4ee00d25daa..aa378d766d5254fa8510894f036bab7dce600cc3 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index bf9b4bd3b60c169561186fae444ac612ca862760..ff8251f18158475d04de5c4707eb0a6fa5a389de 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.IO;
 using System.Collections;
index 2e97c843f663a54f3bf0084731034ed007e7d51b..8c5a860586e09c24ac18cfe0aeacd03443ac3634 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index a7dd963c8da6e597723ce6cde0560c40f39cc225..618d0ffcc2c3e42a05537db1993e61c2ad3b5df9 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index dcf9b3d03060650ff653af9470e341725bfae669..16dc05e3f870353a68a48f15686a98d7cff35095 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 32b0ce2fb498a146ddbfe34389ab0a45090f2654..bdce56d6e9ec252911d452d259cc82551671cf4d 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 0e79378a5ce84eb72415a0c9c4716d2f64370aaa..338e37038d5823290b8f54027c7500036b294c0f 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Collections;
 using System.IO;
index b268e835c492dfa979fa342433540162ee944521..b496749e3f38be75052d5eebf5cdc6d8cff34953 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index ca9ecb3f4cf5f441470bdcb54fc8f675ed34fa9c..c2c5e8480fc19bfdb839ae0a594924e1f261e894 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index ea83af5d6f9c75bef802f33caa53a42f5e36e017..dfb268174b4d6b10c78676320272784e6f02be13 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Collections;
 using System.Reflection;
index 90dd7010d8b058cbc90934acdd22bffa1a2d59ae..082fbabfbb168575fbed464a54c99919a48cfe2f 100644 (file)
@@ -1,6 +1,6 @@
 // created on 28/08/2004 at 17:30
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index b917e14fde5f080ad2c68eae14b30d97ea8ca78a..c2330c4249941307760a1d44894775e680b3d5f9 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) 2009 Novell, Inc
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Collections;
 #if NET_2_0
index b66493a558941235c7f4003e97f988bbf936eeb2..413131b2f6fc00318dae2419f4588a1512de2266 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 52dd50b496e1798096e9ca0fd2a33dcdd32b2e43..6cb27ea36d35072dac00f04def3b24153c446eab 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 93f8394b1a95f16b5089f29d580898ee47ad4cb0..fb270b24ad773d557f38f770f1ab39c1cefdd401 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index af682fb2b92144dc592daaf28ec14eefb57cf48c..5fb248e4630f63c0c88ba6921614d14e757af91f 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 41fa2b1fe5f737d7337984209bc0468c97f4b31e..3ae85a3be360dc003e1a53b72219e618e1fac2a6 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index d691cfef73903f84b46d3b24f319aeadf724efaf..ffd90b45d3bbf258e21f8145a96b7babbdadf6ab 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index ee9ff61616a4564e9f11c1ba997b18a2e6b35517..b34341d90488450dae181d9b263f1ad1ff1b735a 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.IO;
 
index e67107ad89490f8ab2197106d3148f11f84411ff..a01f4f21a1f3e8255e0cbe8f71e1b5953ee4dbb6 100644 (file)
@@ -21,7 +21,7 @@
 // Copyright (C) Lluis Sanchez Gual, 2004
 //
 
-#if !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Reflection;
 using System.Reflection.Emit;
index 7e4823f1819676a446ac81f466e4b8a5b9c81fc2..929a450d22be5df1083bdfb0cc77f5210478985f 100644 (file)
@@ -263,7 +263,7 @@ namespace System.ServiceModel.Description
                {
                        var l = new List<MethodInfo> ();
                        foreach (var t in GetAllInterfaceTypes (type)) {
-#if MONOTOUCH
+#if FULL_AOT_RUNTIME
                                // The MethodBase[] from t.GetMethods () is cast to a IEnumerable <MethodInfo>
                                // when passed to List<MethodInfo>.AddRange, which in turn casts it to 
                                // ICollection <MethodInfo>.  The full-aot compiler has no idea of this, so
index 81529cb5fd255a2bdb640364d98afd290547a304..1af7625027ecea7470b966e0a0c214edbdb31571 100644 (file)
@@ -137,7 +137,7 @@ namespace System.ServiceModel
 
                public virtual TChannel CreateChannel (EndpointAddress address, Uri via)
                {
-#if MONOTOUCH
+#if FULL_AOT_RUNTIME
                        throw new InvalidOperationException ("MonoTouch does not support dynamic proxy code generation. Override this method or its caller to return specific client proxy instance");
 #else
                        var existing = Endpoint.Address;
index 576e4a8a877abd40447f2d771897e2b30eae9ce6..a7b5587abf84f9809a24c4dae57b31ee730ae139 100644 (file)
@@ -26,7 +26,7 @@
 // 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 !MONOTOUCH
+#if !FULL_AOT_RUNTIME
 using System;
 using System.Collections.Generic;
 using System.Reflection;
index 7c647a77dc8c860a0dc2e76e9682754f1df2757e..b656c1d1d2ef2209906f827f56bc75c5d8c4ea0b 100644 (file)
@@ -37,7 +37,7 @@ namespace System.ServiceModel
        {
                TDetail detail;
 
-#if MONOTOUCH
+#if FULL_AOT_RUNTIME
                // WCF creates FaultExceptions using reflection, so unless we reference
                // the corresponding ctor, it will not be possible to use FaultExceptions
                // in MonoTouch. This ctor reference will work as long as TDetail
diff --git a/mcs/class/System.ServiceModel/mobile_static_System.ServiceModel.dll.sources b/mcs/class/System.ServiceModel/mobile_static_System.ServiceModel.dll.sources
new file mode 100644 (file)
index 0000000..22ece5c
--- /dev/null
@@ -0,0 +1 @@
+#include mobile_System.ServiceModel.dll.sources
index e65451c85ed94ea59f8008399abcc88c26a9e127..a89f1d4c83fda4af45556e48f0ba1f1b86412a45 100644 (file)
@@ -2,7 +2,7 @@ thisdir = class/System.Transactions
 SUBDIRS = 
 include ../../build/rules.make
 
-MOBILE_PROFILE := $(filter monotouch monodroid mobile, $(PROFILE))
+MOBILE_PROFILE := $(filter monotouch monodroid mobile mobile_static, $(PROFILE))
 
 LIBRARY = System.Transactions.dll
 ifdef MOBILE_PROFILE
index 5a13d8ec0214e6d50ecf03b2ca9d6455e0a08bb6..9a4d1cfed1fb46646aabccb6626032881d8d53f6 100644 (file)
@@ -3,7 +3,7 @@ SUBDIRS =
 include ../../build/rules.make
 
 LIBRARY = System.Web.Services.dll
-MOBILE := $(filter monotouch monodroid mobile, $(PROFILE))
+MOBILE := $(filter monotouch monodroid mobile mobile_static, $(PROFILE))
 ifdef MOBILE
 LIB_MCS_FLAGS = \
        -nowarn:649 -nowarn:169                 \
diff --git a/mcs/class/System.Web.Services/mobile_static_System.Web.Services.dll.sources b/mcs/class/System.Web.Services/mobile_static_System.Web.Services.dll.sources
new file mode 100644 (file)
index 0000000..9e39dcc
--- /dev/null
@@ -0,0 +1 @@
+#include mobile_System.Web.Services.dll.sources
index 7f19ce58d3d06ab83ab969b2642b2647bfb3f6f6..f6b56c6b3c6e6d7ed71f16884b69f40bc912ff21 100644 (file)
@@ -473,7 +473,7 @@ namespace Mono.Xml.Schema
 
                private void ValidateEndElementParticle ()
                {
-                       if (Context.State != null) {
+                       if (xsiNilDepth < 0 && Context.State != null) {
                                if (!Context.EvaluateEndElement ()) {
                                        HandleError ("Invalid end element: " + reader.Name);
                                }
index 31a488b7b81a9d9a8568af36db7f1bd74113302a..4950c30aadd246e18f5bf0d70e334e4283c2dc32 100644 (file)
@@ -376,6 +376,8 @@ namespace Mono.Xml.Xsl {
                                return; // Already done.
 
                        c.PushInputDocument (included);
+                       included.MoveToRoot ();
+                       included.MoveToFirstChild ();
 
                        while (c.Input.NodeType != XPathNodeType.Element)
                                if (!c.Input.MoveToNext ())
@@ -387,6 +389,7 @@ namespace Mono.Xml.Xsl {
                                templates.Add (new XslTemplate (c));
                        }
                        else {
+                               c.Input.MoveToFirstChild ();
                                do {
                                        if (c.Input.NodeType != XPathNodeType.Element)
                                                continue;
index b082221ed071ed83feefff2c671aef974ac85790..72d8cf3e4eaf9a5c2723fdf11ea8ce8f54f398b1 100644 (file)
@@ -2263,7 +2263,8 @@ namespace Mono.Xml.Schema
 
                internal override ValueType ParseValueType (string s, XmlNameTable nameTable, NSResolver nsmgr) 
                {
-                       return DateTime.ParseExact (Normalize(s), "--MM--", null);
+                       DateTime ret;
+                       return DateTime.TryParseExact (Normalize(s), "--MM", null, DateTimeStyles.RoundtripKind, out ret) ? ret : DateTime.ParseExact (Normalize(s), "--MM--", null);
                }
                
                internal override XsdOrdering Compare(object x, object y) {
index 87f576c00110ccc7d4f422165847ce72cb3fd744..ccb62f048e589cdc77d52a8883d579eea5179f1e 100644 (file)
@@ -45,8 +45,10 @@ namespace System.Xml.Schema
                double doubleValue;
                int intValue;
                long longValue;
+               ulong ulongValue;
                object objectValue;
                float floatValue;
+               byte [] bytesValue;
                string stringValue;
                XmlSchemaType schemaType;
                XmlTypeCode xmlTypeCode;
@@ -68,6 +70,20 @@ namespace System.Xml.Schema
                        schemaType = xmlType;
                }
 
+               internal XmlAtomicValue (byte [] value, XmlSchemaType xmlType)
+               {
+                       Init (value, xmlType);
+               }
+               
+               private void Init (byte [] value, XmlSchemaType xmlType)
+               {
+                       if (xmlType == null)
+                               throw new ArgumentNullException ("xmlType");
+                       xmlTypeCode = XmlTypeCode.Base64Binary;
+                       this.bytesValue = value;
+                       schemaType = xmlType;
+               }
+
                internal XmlAtomicValue (DateTime value, XmlSchemaType xmlType)
                {
                        Init (value, xmlType);
@@ -138,6 +154,20 @@ namespace System.Xml.Schema
                        schemaType = xmlType;
                }
 
+               internal XmlAtomicValue (ulong value, XmlSchemaType xmlType)
+               {
+                       Init (value, xmlType);
+               }
+               
+               private void Init (ulong value, XmlSchemaType xmlType)
+               {
+                       if (xmlType == null)
+                               throw new ArgumentNullException ("xmlType");
+                       xmlTypeCode = XmlTypeCode.UnsignedLong;
+                       this.ulongValue = value;
+                       schemaType = xmlType;
+               }
+
                internal XmlAtomicValue (float value, XmlSchemaType xmlType)
                {
                        Init (value, xmlType);
@@ -182,6 +212,12 @@ namespace System.Xml.Schema
                                throw new ArgumentNullException ("xmlType");
 
                        switch (Type.GetTypeCode (value.GetType ())) {
+                       case TypeCode.Byte:
+                               Init ((byte) value, xmlType);
+                               return;
+                       case TypeCode.SByte:
+                               Init ((sbyte) value, xmlType);
+                               return;
                        case TypeCode.Int16:
                                Init ((short) value, xmlType);
                                return;
@@ -206,6 +242,9 @@ namespace System.Xml.Schema
                        case TypeCode.UInt32:
                                Init ((uint) value, xmlType);
                                return;
+                       case TypeCode.UInt64:
+                               Init ((ulong) value, xmlType);
+                               return;
                        case TypeCode.String:
                                Init ((string) value, xmlType);
                                return;
@@ -216,6 +255,10 @@ namespace System.Xml.Schema
                                Init ((bool) value, xmlType);
                                return;
                        }
+                       if (value is byte []) {
+                               Init ((byte []) value, xmlType);
+                               return;
+                       }
 
                        ICollection col = value as ICollection;
                        if (col != null && col.Count == 1) {
@@ -254,6 +297,9 @@ namespace System.Xml.Schema
                                case XmlTypeCode.Long:
                                        Init (another.longValue, xmlType);
                                        return;
+                               case XmlTypeCode.UnsignedLong:
+                                       Init (another.ulongValue, xmlType);
+                                       return;
                                case XmlTypeCode.Float:
                                        Init (another.floatValue, xmlType);
                                        return;
@@ -309,6 +355,11 @@ namespace System.Xml.Schema
                                return TypedValue;
                        case XmlTypeCode.QName:
                                return XmlQualifiedName.Parse (Value, nsResolver, true);
+                       case XmlTypeCode.Base64Binary:
+                       case XmlTypeCode.HexBinary:
+                               if (bytesValue != null)
+                                       return bytesValue;
+                               break;
                        }
                        throw new NotImplementedException ();
                }
@@ -376,11 +427,31 @@ namespace System.Xml.Schema
                                case XmlTypeCode.DateTime:
                                        stringValue = XQueryConvert.DateTimeToString (ValueAsDateTime);
                                        break;
+                               case XmlTypeCode.Duration:
+                                       stringValue = XQueryConvert.DayTimeDurationToString (TimeSpan.FromMilliseconds (doubleValue));
+                                       break;
+                               case XmlTypeCode.GYear:
+                                       stringValue = XQueryConvert.GYearToString (ValueAsDateTime);
+                                       break;
+                               case XmlTypeCode.GYearMonth:
+                                       stringValue = XQueryConvert.GYearMonthToString (ValueAsDateTime);
+                                       break;
+                               case XmlTypeCode.GMonth:
+                                       stringValue = XQueryConvert.GMonthToString (ValueAsDateTime);
+                                       break;
+                               case XmlTypeCode.GMonthDay:
+                                       stringValue = XQueryConvert.GMonthDayToString (ValueAsDateTime);
+                                       break;
+                               case XmlTypeCode.GDay:
+                                       stringValue = XQueryConvert.GDayToString (ValueAsDateTime);
+                                       break;
                                case XmlTypeCode.Float:
                                case XmlTypeCode.Double:
                                        stringValue = XQueryConvert.DoubleToString (ValueAsDouble);
                                        break;
                                case XmlTypeCode.Integer:
+                               case XmlTypeCode.UnsignedInt:
+                               case XmlTypeCode.UnsignedLong:
                                case XmlTypeCode.Decimal:
                                        stringValue = XQueryConvert.DecimalToString (ValueAsDecimal);
                                        break;
@@ -388,18 +459,24 @@ namespace System.Xml.Schema
                                case XmlTypeCode.NonNegativeInteger:
                                case XmlTypeCode.NegativeInteger:
                                case XmlTypeCode.Long:
-                               case XmlTypeCode.UnsignedLong:
                                case XmlTypeCode.PositiveInteger:
                                        stringValue = XQueryConvert.IntegerToString (ValueAsLong);
                                        break;
                                case XmlTypeCode.Int:
                                case XmlTypeCode.Short:
                                case XmlTypeCode.Byte:
-                               case XmlTypeCode.UnsignedInt:
                                case XmlTypeCode.UnsignedShort:
                                case XmlTypeCode.UnsignedByte:
                                        stringValue = XQueryConvert.IntToString (ValueAsInt);
                                        break;
+                               case XmlTypeCode.Base64Binary:
+                                       stringValue = XQueryConvert.Base64BinaryToString (bytesValue);
+                                       break;
+                               case XmlTypeCode.HexBinary:
+                                       stringValue = XQueryConvert.HexBinaryToString (bytesValue);
+                                       break;
+                               case XmlTypeCode.QName:
+                               case XmlTypeCode.AnyUri:
                                case XmlTypeCode.String:
                                        return stringValue;
 
@@ -419,6 +496,9 @@ namespace System.Xml.Schema
                                        case XmlTypeCode.DateTime:
                                                stringValue = XQueryConvert.DateTimeToString ((DateTime) objectValue);
                                                break;
+                                       case XmlTypeCode.Duration:
+                                               stringValue = XQueryConvert.DayTimeDurationToString (TimeSpan.FromMilliseconds ((double) objectValue));
+                                               break;
                                        case XmlTypeCode.Boolean:
                                                stringValue = XQueryConvert.BooleanToString ((bool) objectValue);
                                                break;
@@ -438,6 +518,12 @@ namespace System.Xml.Schema
                                        case XmlTypeCode.Int:
                                                stringValue = XQueryConvert.IntToString ((int) objectValue);
                                                break;
+                                       case XmlTypeCode.Base64Binary:
+                                               stringValue = XQueryConvert.Base64BinaryToString ((byte []) objectValue);
+                                               break;
+                                       case XmlTypeCode.HexBinary:
+                                               stringValue = XQueryConvert.HexBinaryToString ((byte []) objectValue);
+                                               break;
                                        }
                                        break;
                                }
@@ -445,7 +531,7 @@ namespace System.Xml.Schema
                                        return stringValue;
 
                                if (objectValue != null)
-                                       throw new InvalidCastException (String.Format ("Conversion from runtime type {0} to {1} is not supported", objectValue.GetType (), XmlTypeCode.String));
+                                       throw new InvalidCastException (String.Format ("Conversion from runtime type {0}, resolved as type code {1}, to {2} is not supported", objectValue.GetType (), ResolvedTypeCode, XmlTypeCode.String));
                                else
                                        throw new InvalidCastException (String.Format ("Conversion from schema type {0} (type code {1}, resolved type code {2}) to {3} is not supported.", schemaType.QualifiedName, xmlTypeCode, ResolvedTypeCode, XmlTypeCode.String));
                        }
@@ -489,6 +575,16 @@ namespace System.Xml.Schema
                                        return dateTimeValue;
                                case XmlTypeCode.String:
                                        return XQueryConvert.StringToDateTime (stringValue);
+                               case XmlTypeCode.GYear:
+                                       return XQueryConvert.StringToGYear (stringValue);
+                               case XmlTypeCode.GYearMonth:
+                                       return XQueryConvert.StringToGYearMonth (stringValue);
+                               case XmlTypeCode.GMonth:
+                                       return XQueryConvert.StringToGMonth (stringValue);
+                               case XmlTypeCode.GMonthDay:
+                                       return XQueryConvert.StringToGMonthDay (stringValue);
+                               case XmlTypeCode.GDay:
+                                       return XQueryConvert.StringToGDay (stringValue);
                                case XmlTypeCode.None:
                                case XmlTypeCode.Item:
                                case XmlTypeCode.AnyAtomicType:
@@ -515,6 +611,8 @@ namespace System.Xml.Schema
                                        return XQueryConvert.DoubleToDecimal (doubleValue);
                                case XmlTypeCode.Long:
                                        return XQueryConvert.IntegerToDecimal (longValue);
+                               case XmlTypeCode.UnsignedLong:
+                                       return XQueryConvert.IntegerToDecimal (ulongValue);
                                case XmlTypeCode.Int:
                                        return XQueryConvert.IntToDecimal (intValue);
                                case XmlTypeCode.Float:
@@ -660,6 +758,9 @@ namespace System.Xml.Schema
                                return typeof (DateTime);
                        case XmlTypeCode.Boolean:
                                return typeof (bool);
+                       case XmlTypeCode.Base64Binary:
+                       case XmlTypeCode.HexBinary:
+                               return typeof (byte []);
                        case XmlTypeCode.Item:
                                return typeof (object);
                        }
@@ -692,7 +793,10 @@ namespace System.Xml.Schema
                        case TypeCode.Boolean:
                                return XmlTypeCode.Boolean;
                        case TypeCode.Object:
-                               return XmlTypeCode.Item;
+                               if (cliType == typeof (byte []))
+                                       return XmlTypeCode.Base64Binary;
+                               else
+                                       return XmlTypeCode.Item;
                        }
                        if (raiseError)
                                throw new NotSupportedException (String.Format ("XQuery internal error: Cannot infer XmlTypeCode from Runtime Type {0}", cliType));
index 11ad6b3a4a21834566a5dd414240210688a61394..bad7071427b43af07c86377c3d9ca6d9cb30e076 100644 (file)
@@ -130,14 +130,10 @@ namespace System.Xml.Schema
 
                public XmlSchema Add (string targetNamespace, string schemaUri)
                {
-                       XmlTextReader r = null;
-                       try {
-                               r = new XmlTextReader (schemaUri, nameTable);
-                               return Add (targetNamespace, r);
-                       } finally {
-                               if (r != null)
-                                       r.Close ();
-                       }
+                       var uri = xmlResolver.ResolveUri (null, schemaUri);
+                       using (var stream = (Stream) xmlResolver.GetEntity (uri, null, typeof (Stream)))
+                               using (var r = XmlReader.Create (stream, new XmlReaderSettings () { XmlResolver = xmlResolver, NameTable = nameTable}))
+                                       return Add (targetNamespace, r);
                }
 
                public XmlSchema Add (string targetNamespace, XmlReader schemaDocument)
index 92274b2e15758ccd09a72d3b692b9aebfa4da923..286963d3056ebe5029a59002baa6fa75cccd6852 100644 (file)
@@ -539,10 +539,10 @@ namespace System.Xml.Schema
 
                                if (skipValidationDepth < 0 || depth <= skipValidationDepth)
                                        AssessCloseStartElementSchemaValidity (schemaInfo);
-                               depth++;
                        } finally {
                                current_info = null;
                                occuredAtts.Clear ();
+                               depth++;
                        }
                }
 
@@ -976,7 +976,7 @@ namespace System.Xml.Schema
 
                private void ValidateEndElementParticle ()
                {
-                       if (Context.State != null) {
+                       if (xsiNilDepth < 0 && Context.State != null) {
                                if (!Context.EvaluateEndElement ()) {
                                        HandleError ("Invalid end element. There are still required content items.");
                                }
@@ -1588,7 +1588,8 @@ namespace System.Xml.Schema
                        if (value == "true") {
                                if (element.ValidatedFixedValue != null)
                                        HandleError ("Schema instance nil was specified, where the element declaration for " + element.QualifiedName + "has fixed value constraints.");
-                               xsiNilDepth = depth;
+                               if (xsiNilDepth < 0)
+                                       xsiNilDepth = depth;
                                if (info != null)
                                        info.IsNil = true;
                        }
index ed06d61a688c2b69519d4711906a76231e6a0ace..9f754c727b7fe4f7a8d924c563def3982b95d861 100644 (file)
@@ -691,6 +691,7 @@ namespace System.Xml.Serialization {
                        }
                        else
                        {
+                               defaultValue = defaultValue is decimal ? (object) ('"' + ((decimal) defaultValue).ToString (CultureInfo.InvariantCulture) + '"') : defaultValue;
                                AddCustomAttribute (externalField, "System.ComponentModel.DefaultValue", GetArg (defaultValue));
                                //internalField.InitExpression = new CodePrimitiveExpression (defaultValue);
                        }
index fdcbc0e186f44a95ca625a146b6ae0603a5c01e3..0ea81302af1d48dce0db137b2d0eedd89862ad58 100644 (file)
@@ -35,6 +35,7 @@ using System.CodeDom.Compiler;
 #endif
 using System.Xml.Schema;
 using System.Collections;
+using System.Collections.Generic;
 #if NET_2_0 && CONFIGURATION_DEP
 using System.Configuration;
 using System.Xml.Serialization.Configuration;
@@ -744,6 +745,25 @@ namespace System.Xml.Serialization
                                }
                        }
                }
+               
+               IEnumerable<XmlSchemaAttribute> EnumerateAttributes (XmlSchemaObjectCollection col, List<XmlSchemaAttributeGroup> recurse)
+               {
+                       foreach (var o in col) {
+                               if (o is XmlSchemaAttributeGroupRef) {
+                                       var gr = (XmlSchemaAttributeGroupRef) o;
+                                       var g = FindRefAttributeGroup (gr.RefName);
+                                       if (recurse.Contains (g))
+                                               continue;
+                                       recurse.Add (g);
+                                       if (g == null)
+                                               throw new InvalidOperationException (string.Format ("Referenced AttributeGroup '{0}' was not found.", gr.RefName));
+                                       foreach (var a in EnumerateAttributes (g.Attributes, recurse))
+                                               yield return a;
+                               }
+                               else
+                                       yield return (XmlSchemaAttribute) o;
+                       }
+               }
 
                // Attributes might be redefined, so there is an existing attribute for the same name, skip it.
                // FIXME: this is nothing more than just a hack.
@@ -753,7 +773,7 @@ namespace System.Xml.Serialization
                        XmlSchemaObjectCollection src, ClassMap map)
                {
                        XmlSchemaObjectCollection atts = new XmlSchemaObjectCollection ();
-                       foreach (XmlSchemaAttribute a in src)
+                       foreach (var a in EnumerateAttributes (src, new List<XmlSchemaAttributeGroup> ()))
                                if (map.GetAttribute (a.QualifiedName.Name, a.QualifiedName.Namespace) == null)
                                        atts.Add (a);
                        return atts;
index 178cb53dbcb22ee397b9923d34ab3d9c82c96187..941b9e9103691c4e682811a80e8213e0c1ed9f3f 100644 (file)
@@ -342,17 +342,17 @@ namespace System.Xml
 
                public static string GMonthToString (DateTime value)
                {
-                       return XmlConvert.ToString (new TimeSpan (0, value.Month, 0));
+                       return XmlConvert.ToString (new TimeSpan (0, value.Month, 1));
                }
 
                public static string GYearMonthToString (DateTime value)
                {
-                       return XmlConvert.ToString (new TimeSpan (value.Year, value.Month, 0));
+                       return XmlConvert.ToString (new TimeSpan (value.Year, value.Month, 1));
                }
 
                public static string GYearToString (DateTime value)
                {
-                       return XmlConvert.ToString (new TimeSpan (new DateTime (value.Year, 0, 0).Ticks));
+                       return XmlConvert.ToString (new TimeSpan (new DateTime (value.Year, 1, 1).Ticks));
                }
 
                public static string HexBinaryToString (byte [] data)
@@ -376,6 +376,11 @@ namespace System.Xml
                        return (decimal) value;
                }
 
+               public static decimal IntegerToDecimal (ulong value)
+               {
+                       return (decimal) value;
+               }
+
                public static double IntegerToDouble (long value)
                {
                        return Convert.ToDouble (value);
index c00965d425ae1db99c4af7fd156802037035d0a2..8497c85eee976921b10874da195e7708956aa4d6 100644 (file)
@@ -928,47 +928,60 @@ namespace System.Xml {
 #if NET_4_0
                public static bool IsNCNameChar (char ch)
                {
-                       throw new NotImplementedException ();
+                       return XmlChar.IsNCNameChar (ch);
                }
 
                public static bool IsPublicIdChar (char ch)
                {
-                       throw new NotImplementedException ();
+                       return XmlChar.IsPubidChar (ch);
                }
 
                public static bool IsStartNCNameChar (char ch)
                {
-                       throw new NotImplementedException ();
+                       return XmlChar.IsFirstNameChar (ch);
                }
 
                public static bool IsWhitespaceChar (char ch)
                {
-                       throw new NotImplementedException ();
+                       return XmlChar.IsWhitespace (ch);
                }
 
                public static bool IsXmlChar (char ch)
                {
-                       throw new NotImplementedException ();
+                       return XmlChar.IsValid (ch);
                }
 
                public static bool IsXmlSurrogatePair (char lowChar, char highChar)
                {
-                       throw new NotImplementedException ();
+                       return 0xD800 <= lowChar && lowChar <= 0xDBFF && 0xDC00 <= highChar && highChar <= 0xDFFF;
                }
                
                public static string VerifyPublicId (string publicId)
                {
-                       throw new NotImplementedException ();
+                       if (publicId == null)
+                               throw new ArgumentNullException ("publicId");
+                       if (XmlChar.IsPubid (publicId))
+                               return publicId;
+                       throw new XmlException (string.Format ("'{0}' is not a valid PUBLIC ID", publicId));
                }
 
                public static string VerifyWhitespace (string content)
                {
-                       throw new NotImplementedException ();
+                       if (content == null)
+                               throw new ArgumentNullException ("content");
+                       if (XmlChar.IsWhitespace (content))
+                               return content;
+                       throw new XmlException (string.Format ("'{0}' is not whitespace", content));
                }
 
                public static string VerifyXmlChars (string content)
                {
-                       throw new NotImplementedException ();
+                       if (content == null)
+                               throw new ArgumentNullException ("content");
+                       var idx = XmlChar.IndexOfInvalid (content, true);
+                       if (idx < 0)
+                               return content;
+                       throw new XmlException (string.Format ("Invalid XML character was found in the content, at index {0}.", idx));
                }
 #endif
        }
index bfbd80e9a0d847b1736b1ba7d1c19eab4737fb2c..0d417787a492b61624e062aaf3077fdcc9f56b7d 100644 (file)
@@ -321,5 +321,144 @@ namespace MonoTests.System.Xml
 
                        datatype.ChangeType(300, typeof (int));
                }
+               
+               [Test]
+               public void Bug12469 ()
+               {
+                       Dictionary<string, string> validValues = new Dictionary<string, string> {
+                               {"string", "abc"},
+
+                               {"normalizedString", "abc"},
+                               {"token", "abc"},
+                               {"language", "en"},
+                               {"Name", "abc"},
+                               {"NCName", "abc"},
+                               {"ID", "abc"},
+                               {"ENTITY", "abc"},
+                               {"NMTOKEN", "abc"},
+
+                               {"boolean", "true"},
+                               {"decimal", "1"},
+                               {"integer", "1"},
+                               {"nonPositiveInteger", "0"},
+                               {"negativeInteger", "-1"},
+                               {"long", "9223372036854775807"},
+                               {"int", "2147483647"},
+                               {"short", "32767"},
+                               {"byte", "127"},
+                               {"nonNegativeInteger", "0"},
+                               {"unsignedLong", "18446744073709551615"},
+                               {"unsignedInt", "4294967295"},
+                               {"unsignedShort", "65535"},
+                               {"unsignedByte", "255"},
+                               {"positiveInteger", "1"},
+                               {"float", "1.1"},
+                               {"double", "1.1"},
+                               {"time", "00:00:00"},
+                               {"date", "1999-12-31"},
+                               {"dateTime", "1999-12-31T00:00:00.000"},
+                               {"duration", "P1Y2M3DT10H30M"},
+                               {"gYearMonth", "1999-01"},
+                               {"gYear", "1999"},
+                               {"gMonthDay", "--12-31"},
+                               {"gMonth", "--12"},
+                               {"gDay", "---31"},
+
+                               {"base64Binary", "AbCd eFgH IjKl 019+"},
+                               {"hexBinary", "0123456789ABCDEF"},
+
+                               {"anyURI", "https://www.server.com"},
+                               {"QName", "xml:abc"},
+                               };
+
+                       // FIXME: implement validation
+                       Dictionary<string, string> invalidValues = new Dictionary<string, string> {
+                               {"Name", "***"},
+                               {"NCName", "a::"},
+                               {"ID", "123"},
+                               {"ENTITY", "***"},
+                               {"NMTOKEN", "***"},
+
+                               {"boolean", "ABC"},
+                               {"decimal", "1A"},
+                               {"integer", "1.5"},
+                               {"nonPositiveInteger", "5"},
+                               {"negativeInteger", "10"},
+                               {"long", "999999999999999999999999999999999999999"},
+                               {"int", "999999999999999999999999999999999999999"},
+                               {"short", "32768"},
+                               {"byte", "128"},
+                               {"nonNegativeInteger", "-1"},
+                               {"unsignedLong", "-1"},
+                               {"unsignedInt", "-1"},
+                               {"unsignedShort", "-1"},
+                               {"unsignedByte", "-1"},
+                               {"positiveInteger", "0"},
+                               {"float", "1.1x"},
+                               {"double", "1.1x"},
+                               {"time", "0"},
+                               {"date", "1"},
+                               {"dateTime", "2"},
+                               {"duration", "P1"},
+                               {"gYearMonth", "1999"},
+                               {"gYear", "-1"},
+                               {"gMonthDay", "-12-31"},
+                               {"gMonth", "-12"},
+                               {"gDay", "--31"},
+
+                               {"base64Binary", "####"},
+                               {"hexBinary", "G"},
+
+                               // anyURI passes everything (as long as I observed)
+                               {"QName", "::"},
+                               };
+
+                       const string schemaTemplate = @"
+                               <xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' elementFormDefault='qualified'> 
+                                       <xs:element name='EL'>
+                                               <xs:complexType>
+                                                       <xs:attribute name='attr' type='xs:{0}' use='required' />
+                                               </xs:complexType>
+                                       </xs:element>
+                               </xs:schema>";
+
+                       const string documentTemplate = @"<EL attr='{0}' />";
+
+                       foreach (var type in validValues.Keys) {
+                               try {
+                                       var schema = string.Format (schemaTemplate, type);
+                                       var document = string.Format (documentTemplate, validValues[type]);
+
+                                       var schemaSet = new XmlSchemaSet ();
+                                       using (var reader = new StringReader (schema))
+                                               schemaSet.Add (XmlSchema.Read (reader, null));
+                                       schemaSet.Compile ();
+                                       var doc = new XmlDocument ();
+                                       using (var reader = new StringReader (document))
+                                               doc.Load (reader);
+                                       doc.Schemas = schemaSet;
+                                       doc.Validate (null);
+
+                                       // FIXME: implement validation
+                                       /*
+                                       if (!invalidValues.ContainsKey (type))
+                                               continue;
+                                       try {
+                                               doc = new XmlDocument ();
+                                               document = string.Format (documentTemplate, invalidValues [type]);
+                                               using (var reader = new StringReader (document))
+                                                       doc.Load (reader);
+                                               doc.Schemas = schemaSet;
+                                               doc.Validate (null);
+                                               Assert.Fail (string.Format ("Failed to invalidate {0} for {1}", document, type));
+                                       } catch (XmlSchemaException) {
+                                       }
+                                       */
+                               } catch (Exception) {
+                                       Console.Error.WriteLine (type);
+                                       throw;
+                               }
+                       }
+               }
        }
 }
index 6a8a7a49d8accf2b444cc3efc26ae861e332e194..127a21aea4eb04c899518fb5958e4c1df2825b25 100644 (file)
@@ -11,6 +11,7 @@
 using System;
 using System.Collections;
 using System.IO;
+using System.Text;
 using System.Xml;
 using System.Xml.Schema;
 using NUnit.Framework;
@@ -279,6 +280,40 @@ type=""xsd:string"" use=""required""/>
                        xss.Compile ();
                        Assert.IsNotNull (xss.GlobalElements [new XmlQualifiedName ("GetSystemDateAndTimeResponse", "http://www.onvif.org/ver10/device/wsdl")], "#1");
                }
+               
+               [Test] // bug #13716
+               public void ResolveSchemaUriUsingXmlResolver ()
+               {
+                       var resolver = new Bug13716XmlResolver ();
+                       string xml = "<people xmlns='testschema'><person name='Ian'><books><book>Clean Code</book></books></person></people>";
+                       string ns = "testschema";
+                       string xsdPath = "my.xsd";
+
+                       var readerSettings = new XmlReaderSettings ();
+
+                       //readerSettings.XmlResolver = resolver;
+                       readerSettings.Schemas.XmlResolver = resolver;
+                       readerSettings.Schemas.Add (ns, xsdPath);
+                       readerSettings.ValidationType = ValidationType.Schema;
+
+                       using (var xr = XmlReader.Create (new StringReader (xml), readerSettings))
+                       {
+                               while (!xr.EOF)
+                                       xr.Read ();
+                       }
+               }
+               
+               public class Bug13716XmlResolver : XmlUrlResolver
+               {
+                       public override object GetEntity(Uri absoluteUri, string role, Type typeOfObjectToReturn)
+                       {
+                               string xsd = @"
+               <xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' targetNamespace='testschema'>
+                 <xs:element name='people' />
+               </xs:schema>";
+                               return new MemoryStream (Encoding.UTF8.GetBytes (xsd));
+                       }
+               }
        }
 }
 #endif
index bf258f6cc17b453e60aaafdb474fb2a07ef26fe6..6f7ec34a5dd6e730d5bfbc8983980bfc853781c3 100644 (file)
@@ -397,6 +397,50 @@ namespace MonoTests.System.Xml
                                i++;
                        Assert.AreEqual (2, i, "#2");
                }
+               
+               [Test]
+               public void Bug12035 ()
+               {
+                       string xml = @"<UserSettings
+  xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'
+  xmlns:xsd='http://www.w3.org/2001/XMLSchema'
+  xmlns='http://schema/test'><Enabled>false</Enabled><Time xsi:nil='true' /></UserSettings>";
+                       string xsd = @"<?xml version='1.0' encoding='utf-8'?>
+<xs:schema
+  targetNamespace='http://schema/test'
+  xmlns='http://schema/test'
+  xmlns:xs='http://www.w3.org/2001/XMLSchema'
+  elementFormDefault='qualified'>
+  <xs:element name='UserSettings'>
+    <xs:complexType>
+      <xs:sequence>
+        <xs:element name='Enabled' type='xs:boolean' />
+        <xs:element name='Time' type='CoarseTime' nillable='true' />
+      </xs:sequence>
+    </xs:complexType>
+  </xs:element>
+
+  <xs:complexType name='CoarseTime'>
+    <xs:sequence>
+      <xs:element name='Hours' type='xs:int' />
+    </xs:sequence>
+  </xs:complexType>
+</xs:schema>";
+                       var schema = XmlSchema.Read (new StringReader (xsd), null);
+                       var schemaSet = new XmlSchemaSet ();
+                       schemaSet.Add (schema);
+                       var xmlReaderSettings = new XmlReaderSettings { ValidationType = ValidationType.Schema };
+                       xmlReaderSettings.ValidationFlags |= XmlSchemaValidationFlags.ReportValidationWarnings;
+                       xmlReaderSettings.Schemas.Add (schemaSet);
+                       
+                       using (var configStream = new StringReader (xml)) {
+                               using (var validatingReader = XmlReader.Create (configStream, xmlReaderSettings)) {
+                                       // Read the XML, throwing an exception if a validation error occurs
+                                       while (validatingReader.Read()) {
+                                       }
+                               }
+                       }
+               }
        }
 }
 
index b276342806c1743a75280bfd13d3a79a0eedb38a..16573e3beee8c0eef042a0c89a13c94390c3c577 100644 (file)
@@ -2226,7 +2226,6 @@ NO
                        Assert.IsTrue (sw.ToString ().IndexOf ("NO") > 0);
                }
 
-#if NET_2_0
                [Test] // bug #349375
                public void PreserveWhitespace ()
                {
@@ -2416,6 +2415,36 @@ NO
                }
 
                private bool valueHasBeenSet;
-#endif
+               
+               [Test] // bug #4434
+               public void IncludeProcessStylesheet ()
+               {
+                       string includedXsl = @"<?xml version='1.0' ?>
+<xsl:stylesheet xmlns:xsl='http://www.w3.org/1999/XSL/Transform' xmlns:doc='http://nwalsh.com/xsl/documentation/1.0' exclude-result-prefixes='doc' version='1.0'>
+       <doc:template name='foo' />
+       <xsl:template name='foo'>
+               <foo />
+       </xsl:template>
+</xsl:stylesheet>";
+                       StreamWriter includedWriter = new StreamWriter ("include.xsl");
+                       includedWriter.WriteLine (includedXsl);
+                       includedWriter.Close ();
+                       XslCompiledTransform transform = new XslCompiledTransform ();
+                       string xsl = @"<?xml version='1.0' ?>
+<xsl:stylesheet xmlns:xsl='http://www.w3.org/1999/XSL/Transform' version='1.0'>
+       <xsl:include href='include.xsl' />
+       <xsl:template match='/'>
+               <xsl:call-template name='foo' />
+       </xsl:template>
+</xsl:stylesheet>";
+                       XmlReader xslReader = XmlReader.Create (new StringReader (xsl));
+                       transform.Load (xslReader);
+                       XmlReader inputReader = XmlReader.Create (new StringReader ("<bar />"));
+                       var sw = new StringWriter ();
+                       XmlWriter outputWriter = XmlWriter.Create (sw);
+                       transform.Transform (inputReader, outputWriter);
+                       outputWriter.Close ();
+                       Assert.AreEqual ("<?xml version=\"1.0\" encoding=\"utf-16\"?><foo />", sw.ToString (), "#1");
+               }
        }
 }
diff --git a/mcs/class/System.XML/mobile_static_System.Xml.dll.sources b/mcs/class/System.XML/mobile_static_System.Xml.dll.sources
new file mode 100644 (file)
index 0000000..b663093
--- /dev/null
@@ -0,0 +1 @@
+#include mobile_System.Xml.dll.sources
index 80ba33b662332394e89f44393fbe7ea925b47263..70b6430929a98ab53cd5b4a7f8b7a80854de58d7 100644 (file)
@@ -760,8 +760,9 @@ namespace System.Xml.Linq
 
                public void ReplaceAll (object content)
                {
-                       RemoveNodes ();
-                       Add (content);
+                       // it's waste of resource, but from bug #11298 it must save content
+                       // snapshot first and then remove existing attributes.
+                       ReplaceAll (XUtil.ExpandArray (content).ToArray ());
                }
 
                public void ReplaceAll (params object [] content)
@@ -772,8 +773,9 @@ namespace System.Xml.Linq
 
                public void ReplaceAttributes (object content)
                {
-                       RemoveAttributes ();
-                       Add (content);
+                       // it's waste of resource, but from bug #11298 it must save content
+                       // snapshot first and then remove existing attributes.
+                       ReplaceAttributes (XUtil.ExpandArray (content).ToArray ());
                }
 
                public void ReplaceAttributes (params object [] content)
@@ -785,8 +787,9 @@ namespace System.Xml.Linq
                public void SetElementValue (XName name, object value)
                {
                        var element = Element (name);
-                       if (element == null && value != null) {
-                               Add (new XElement (name, value));
+                       if (element == null) {
+                               if (value != null)
+                                       Add (new XElement (name, value));
                        } else if (element != null && value == null) {
                                element.Remove ();
                        } else
index c6bb881eac2134caefc6c756fc8a01f953eba3f5..e98811ed434c181db2c9f1ed853a605115e85bc9 100644 (file)
@@ -80,9 +80,10 @@ namespace System.Xml.Linq
                public string ToString (SaveOptions options)
                {
                        StringWriter sw = new StringWriter ();
-                       XmlWriterSettings s = new XmlWriterSettings ();
-                       s.ConformanceLevel = ConformanceLevel.Auto;
-                       s.Indent = options != SaveOptions.DisableFormatting;
+                       XmlWriterSettings s = new XmlWriterSettings () {
+                               ConformanceLevel = ConformanceLevel.Auto,
+                               Indent = options != SaveOptions.DisableFormatting,
+                               OmitXmlDeclaration = true };
                        XmlWriter xw = XmlWriter.Create (sw, s);
                        WriteTo (xw);
                        xw.Close ();
index 69cb484b23ed49c47b3e3b6a1895c2fec40dcb51..debe2696823078f1d1e9ac4688dc54a7fa632a28 100644 (file)
@@ -93,7 +93,7 @@ namespace System.Xml.Linq
                        throw new NotImplementedException ();
                }
 
-               public static IEnumerable ExpandArray (object o)
+               public static IEnumerable<object> ExpandArray (object o)
                {
                        XNode n = o as XNode;
                        if (n != null)
index 5a5f255094c74c579df300882bd87538267d25e7..dd0b6a6783572b57f642ce0ab0e0981ea6be8a11 100644 (file)
@@ -2050,5 +2050,27 @@ namespace MonoTests.System.Xml.Linq
                        XElement newElement = new XElement(ns + "geoloc");
                        Assert.AreEqual ("<geoloc xmlns=\"http://jabber.org/protocol/geoloc\" />", newElement.ToString (), "#1");
                }
+               
+               [Test] // bug #10194
+               public void SetElementValueNullOnNonExistingElement ()
+               {
+                       var xd = XDocument.Parse ("<foo />");
+                       xd.Root.SetElementValue (XName.Get ("bar"), null);
+               }
+               
+               [Test] // bug #11298
+               public void ReplaceAttributesIteratesContentsFirstThenRemove ()
+               {
+                       var xmlString = "<Class Id='1' Name='' Cluster='' xmlns='urn:x' />";
+                       var e = XDocument.Parse (xmlString).Root;
+                       var attrs = e.Attributes ()
+                               .Where (a => !a.IsNamespaceDeclaration)
+                               .Select (a => a.Name.Namespace != XNamespace.None ?
+                                                new XAttribute (XName.Get(a.Name.LocalName), a.Value) : a);
+                       e.ReplaceAttributes (attrs);
+                       Assert.IsNotNull (e.Attribute ("Id"), "#1");
+                       Assert.IsNotNull (e.Attribute ("Name"), "#2");
+                       Assert.IsNotNull (e.Attribute ("Cluster"), "#3");
+               }
        }
 }
index 4a3bd989644fe5b88607775eebbb594d21ba00b6..3b25daa8977eecc2a4328aae9fd5dff0971002d1 100644 (file)
@@ -36,7 +36,7 @@ LIB_MCS_FLAGS += -d:SECURITY_DEP
 endif
 endif
 ifeq (monotouch, $(PROFILE))
-LIB_MCS_FLAGS += -d:FULL_AOT_RUNTIME -d:SECURITY_DEP
+LIB_MCS_FLAGS += -d:SECURITY_DEP
 endif
 
 EXTRA_DISTFILES = \
index 0f8322efc76c4d28f3d0d3573a5448059b630a1e..de0f569d5c5d57a002c307b612d0f9e9f10d64b3 100644 (file)
@@ -172,7 +172,28 @@ namespace Mono.CSharp
                {
                        GenerateCompileUnitStart (compileUnit);
 
-                       GenerateGlobalNamespace (compileUnit);
+                       List<CodeNamespaceImport> imports = null;
+                       foreach (CodeNamespace codeNamespace in compileUnit.Namespaces) {
+                               if (!string.IsNullOrEmpty (codeNamespace.Name))
+                                       continue;
+
+                               if (codeNamespace.Imports.Count == 0)
+                                       continue;
+
+                               if (imports == null)
+                                       imports = new List<CodeNamespaceImport> ();
+
+                               foreach (CodeNamespaceImport i in codeNamespace.Imports)
+                                       imports.Add (i);
+                       }
+
+                       if (imports != null) {
+                               imports.Sort ((a, b) => a.Namespace.CompareTo (b.Namespace));
+                               foreach (var import in imports)
+                                       GenerateNamespaceImport (import);
+
+                               Output.WriteLine ();
+                       }
 
                        if (compileUnit.AssemblyCustomAttributes.Count > 0) {
                                OutputAttributes (compileUnit.AssemblyCustomAttributes, 
@@ -180,26 +201,22 @@ namespace Mono.CSharp
                                Output.WriteLine ("");
                        }
 
-                       GenerateLocalNamespaces (compileUnit);
-
-                       GenerateCompileUnitEnd (compileUnit);
-               }
+                       CodeNamespaceImportCollection global_imports = null;
+                       foreach (CodeNamespace codeNamespace in compileUnit.Namespaces) {
+                               if (string.IsNullOrEmpty (codeNamespace.Name)) {
+                                       global_imports = codeNamespace.Imports;
+                                       codeNamespace.Imports = new CodeNamespaceImportCollection ();
+                               }
 
-               private void GenerateGlobalNamespace (CodeCompileUnit compileUnit) {
-                       CodeNamespace globalNamespace = null;
+                               GenerateNamespace (codeNamespace);
 
-                       foreach (CodeNamespace codeNamespace in compileUnit.Namespaces)
-                               if (string.IsNullOrEmpty (codeNamespace.Name)) 
-                                       globalNamespace = codeNamespace;
-  
-                       if (globalNamespace != null)
-                               GenerateNamespace (globalNamespace);
-               }
+                               if (global_imports != null) {
+                                       codeNamespace.Imports = global_imports;
+                                       global_imports = null;
+                               }
+                       }
 
-               private void GenerateLocalNamespaces (CodeCompileUnit compileUnit) {
-                       foreach (CodeNamespace codeNamespace in compileUnit.Namespaces)
-                               if (!string.IsNullOrEmpty (codeNamespace.Name))
-                                       GenerateNamespace (codeNamespace);
+                       GenerateCompileUnitEnd (compileUnit);
                }
 
                protected override void GenerateDefaultValueExpression (CodeDefaultValueExpression e)
index 8a709865b4149519aa388fe7ba56963d8346188e..7940975eb21a6c7ce09b6f8f7728a31a106d0c05 100644 (file)
@@ -80,6 +80,9 @@ namespace System.CodeDom
                                }
                                return imports;
                        }
+                       internal set {
+                               imports = value;
+                       }
                }
 
                public string Name {
index 6c26e8795f62cf037c1eddafeec9a8dd8ce73aa3..339e63c9aa2079d44290b9a939defd982c23c329 100644 (file)
@@ -40,30 +40,33 @@ namespace System.Collections.ObjectModel
 #endif
        public class ObservableCollection<T> : Collection<T>, INotifyCollectionChanged, INotifyPropertyChanged {
                [Serializable]
-               sealed class Reentrant : IDisposable {
-                       private int count = 0;
+#if !MOBILE
+               [TypeForwardedFrom (Consts.WindowsBase_3_0)]
+#endif
+               sealed class SimpleMonitor : IDisposable {
+                       private int _busyCount;
 
-                       public Reentrant()
+                       public SimpleMonitor()
                        {
                        }
 
                        public void Enter()
                        {
-                               count++;
+                               _busyCount++;
                        }
 
                        public void Dispose()
                        {
-                               count--;
+                               _busyCount--;
                        }
 
                        public bool Busy
                        {
-                               get { return count > 0; }
+                               get { return _busyCount > 0; }
                        }
                }
 
-               private Reentrant reentrant = new Reentrant ();
+               private SimpleMonitor _monitor = new SimpleMonitor ();
 
                public ObservableCollection ()
                {
@@ -83,7 +86,9 @@ namespace System.Collections.ObjectModel
                {
                }
 
+               [field:NonSerialized]
                public virtual event NotifyCollectionChangedEventHandler CollectionChanged;
+               [field:NonSerialized]
                protected virtual event PropertyChangedEventHandler PropertyChanged;
 
                event PropertyChangedEventHandler INotifyPropertyChanged.PropertyChanged {
@@ -93,8 +98,8 @@ namespace System.Collections.ObjectModel
 
                protected IDisposable BlockReentrancy ()
                {
-                       reentrant.Enter ();
-                       return reentrant;
+                       _monitor.Enter ();
+                       return _monitor;
                }
 
                protected void CheckReentrancy ()
@@ -102,7 +107,7 @@ namespace System.Collections.ObjectModel
                        NotifyCollectionChangedEventHandler eh = CollectionChanged;
 
                        // Only have a problem if we have more than one event listener.
-                       if (reentrant.Busy && eh != null && eh.GetInvocationList ().Length > 1)
+                       if (_monitor.Busy && eh != null && eh.GetInvocationList ().Length > 1)
                                throw new InvalidOperationException ("Cannot modify the collection while reentrancy is blocked.");
                }
 
index 00c92ef503cc6ba03fa8c8cac22bb304f2e5acb4..3f307b018ce3115f637f793083618bbde129046f 100644 (file)
@@ -5,8 +5,10 @@
 // Authors:
 //     Christopher James Lahey <clahey@ximian.com>
 //     Gonzalo Paniagua Javier (gonzalo@novell.com)
+//  Marek Safar (marek.safar@gmail.com)
 //
 // (c) Copyright 2004,2009 Novell, Inc. <http://www.novell.com>
+// Copyright (C) 2013 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
@@ -37,12 +39,10 @@ using System.Runtime.Remoting.Messaging;
 using MonoTouch;
 #endif
 
-namespace System.IO.Compression {
+namespace System.IO.Compression
+{
        public class DeflateStream : Stream
        {
-               const int BufferSize = 4096;
-               [UnmanagedFunctionPointer (CallingConvention.Cdecl)]
-               delegate int UnmanagedReadOrWrite (IntPtr buffer, int length, IntPtr data);
                delegate int ReadMethod (byte[] array, int offset, int count);
                delegate void WriteMethod (byte[] array, int offset, int count);
 
@@ -50,11 +50,7 @@ namespace System.IO.Compression {
                CompressionMode mode;
                bool leaveOpen;
                bool disposed;
-               UnmanagedReadOrWrite feeder; // This will be passed to unmanaged code and used there
-               IntPtr z_stream;
-               byte [] io_buffer;
-
-               GCHandle data;
+               DeflateStreamNative native;
 
                public DeflateStream (Stream compressedStream, CompressionMode mode) :
                        this (compressedStream, mode, false, false)
@@ -74,14 +70,10 @@ namespace System.IO.Compression {
                        if (mode != CompressionMode.Compress && mode != CompressionMode.Decompress)
                                throw new ArgumentException ("mode");
 
-                       this.data = GCHandle.Alloc (this);
                        this.base_stream = compressedStream;
-                       this.feeder = (mode == CompressionMode.Compress) ? new UnmanagedReadOrWrite (UnmanagedWrite) :
-                                                                          new UnmanagedReadOrWrite (UnmanagedRead);
-                       this.z_stream = CreateZStream (mode, gzip, feeder, GCHandle.ToIntPtr (data));
-                       if (z_stream == IntPtr.Zero) {
-                               this.base_stream = null;
-                               this.feeder = null;
+
+                       this.native = DeflateStreamNative.Create (compressedStream, mode, gzip);
+                       if (this.native == null) {
                                throw new NotImplementedException ("Failed to initialize zlib. You probably have an old zlib installed. Version 1.2.0.4 or later is required.");
                        }
                        this.mode = mode;
@@ -108,107 +100,29 @@ namespace System.IO.Compression {
                {
                        if (disposing && !disposed) {
                                disposed = true;
-                               IntPtr zz = z_stream;
-                               z_stream = IntPtr.Zero;
-                               int res = 0;
-                               if (zz != IntPtr.Zero)
-                                       res = CloseZStream (zz); // This will Flush() the remaining output if any
 
-                               io_buffer = null;
                                if (!leaveOpen) {
                                        Stream st = base_stream;
                                        if (st != null)
                                                st.Close ();
                                        base_stream = null;
                                }
-                               CheckResult (res, "Dispose");
                        }
 
-                       if (data.IsAllocated) {
-                               data.Free ();
-                               data = new GCHandle ();
-                       }
+                       native.Dispose (disposing);
 
                        base.Dispose (disposing);
                }
 
-#if MONOTOUCH
-               [MonoPInvokeCallback (typeof (UnmanagedReadOrWrite))]
-#endif
-               static int UnmanagedRead (IntPtr buffer, int length, IntPtr data)
-               {
-                       GCHandle s = GCHandle.FromIntPtr (data);
-                       var self = s.Target as DeflateStream;
-                       if (self == null)
-                               return -1;
-                       return self.UnmanagedRead (buffer, length);
-               }
-
-               int UnmanagedRead (IntPtr buffer, int length)
-               {
-                       int total = 0;
-                       int n = 1;
-                       while (length > 0 && n > 0) {
-                               if (io_buffer == null)
-                                       io_buffer = new byte [BufferSize];
-
-                               int count = Math.Min (length, io_buffer.Length);
-                               n = base_stream.Read (io_buffer, 0, count);
-                               if (n > 0) {
-                                       Marshal.Copy (io_buffer, 0, buffer, n);
-                                       unsafe {
-                                               buffer = new IntPtr ((byte *) buffer.ToPointer () + n);
-                                       }
-                                       length -= n;
-                                       total += n;
-                               }
-                       }
-                       return total;
-               }
-
-#if MONOTOUCH
-               [MonoPInvokeCallback (typeof (UnmanagedReadOrWrite))]
-#endif
-               static int UnmanagedWrite (IntPtr buffer, int length, IntPtr data)
-               {
-                       GCHandle s = GCHandle.FromIntPtr (data);
-                       var self = s.Target as DeflateStream;
-                       if (self == null)
-                               return -1;
-                       return self.UnmanagedWrite (buffer, length);
-               }
-
-               int UnmanagedWrite (IntPtr buffer, int length)
-               {
-                       int total = 0;
-                       while (length > 0) {
-                               if (io_buffer == null)
-                                       io_buffer = new byte [BufferSize];
-
-                               int count = Math.Min (length, io_buffer.Length);
-                               Marshal.Copy (buffer, io_buffer, 0, count);
-                               base_stream.Write (io_buffer, 0, count);
-                               unsafe {
-                                       buffer = new IntPtr ((byte *) buffer.ToPointer () + count);
-                               }
-                               length -= count;
-                               total += count;
-                       }
-                       return total;
-               }
-
                unsafe int ReadInternal (byte[] array, int offset, int count)
                {
                        if (count == 0)
                                return 0;
 
-                       int result = 0;
                        fixed (byte *b = array) {
                                IntPtr ptr = new IntPtr (b + offset);
-                               result = ReadZStream (z_stream, ptr, count);
+                               return native.ReadZStream (ptr, count);
                        }
-                       CheckResult (result, "ReadInternal");
-                       return result;
                }
 
                public override int Read (byte[] dest, int dest_offset, int count)
@@ -235,12 +149,10 @@ namespace System.IO.Compression {
                        if (count == 0)
                                return;
 
-                       int result = 0;
                        fixed (byte *b = array) {
                                IntPtr ptr = new IntPtr (b + offset);
-                               result = WriteZStream (z_stream, ptr, count);
+                               native.WriteZStream (ptr, count);
                        }
-                       CheckResult (result, "WriteInternal");
                }
 
                public override void Write (byte[] src, int src_offset, int count)
@@ -263,53 +175,13 @@ namespace System.IO.Compression {
                        WriteInternal (src, src_offset, count);
                }
 
-               static void CheckResult (int result, string where)
-               {
-                       if (result >= 0)
-                               return;
-
-                       string error;
-                       switch (result) {
-                       case -1: // Z_ERRNO
-                               error = "Unknown error"; // Marshal.GetLastWin32() ?
-                               break;
-                       case -2: // Z_STREAM_ERROR
-                               error = "Internal error";
-                               break;
-                       case -3: // Z_DATA_ERROR
-                               error = "Corrupted data";
-                               break;
-                       case -4: // Z_MEM_ERROR
-                               error = "Not enough memory";
-                               break;
-                       case -5: // Z_BUF_ERROR
-                               error = "Internal error (no progress possible)";
-                               break;
-                       case -6: // Z_VERSION_ERROR
-                               error = "Invalid version";
-                               break;
-                       case -10:
-                               error = "Invalid argument(s)";
-                               break;
-                       case -11:
-                               error = "IO error";
-                               break;
-                       default:
-                               error = "Unknown error";
-                               break;
-                       }
-
-                       throw new IOException (error + " " + where);
-               }
-
                public override void Flush ()
                {
                        if (disposed)
                                throw new ObjectDisposedException (GetType ().FullName);
 
                        if (CanWrite) {
-                               int result = Flush (z_stream);
-                               CheckResult (result, "Flush");
+                               native.Flush ();
                        }
                }
 
@@ -430,6 +302,188 @@ namespace System.IO.Compression {
                        get { throw new NotSupportedException(); }
                        set { throw new NotSupportedException(); }
                }
+       }
+
+       class DeflateStreamNative
+       {
+               const int BufferSize = 4096;
+
+               [UnmanagedFunctionPointer (CallingConvention.Cdecl)]
+               delegate int UnmanagedReadOrWrite (IntPtr buffer, int length, IntPtr data);
+
+               UnmanagedReadOrWrite feeder; // This will be passed to unmanaged code and used there
+
+               Stream base_stream;
+               IntPtr z_stream;
+               GCHandle data;
+               bool disposed;
+               byte [] io_buffer;
+
+               private DeflateStreamNative ()
+               {
+               }
+
+               public static DeflateStreamNative Create (Stream compressedStream, CompressionMode mode, bool gzip)
+               {
+                       var dsn = new DeflateStreamNative ();
+                       dsn.data = GCHandle.Alloc (dsn);
+                       dsn.feeder = mode == CompressionMode.Compress ? new UnmanagedReadOrWrite (UnmanagedWrite) : new UnmanagedReadOrWrite (UnmanagedRead);
+                       dsn.z_stream = CreateZStream (mode, gzip, dsn.feeder, GCHandle.ToIntPtr (dsn.data));
+                       if (dsn.z_stream == IntPtr.Zero) {
+                               dsn.Dispose (true);
+                               return null;
+                       }
+
+                       dsn.base_stream = compressedStream;
+                       return dsn;
+               }
+
+               ~DeflateStreamNative ()
+               {
+                       Dispose (false);
+               }
+
+               public void Dispose (bool disposing)
+               {
+                       if (disposing && !disposed) {
+                               disposed = true;
+                               GC.SuppressFinalize (this);
+                       
+                               io_buffer = null;
+                       
+                               IntPtr zz = z_stream;
+                               z_stream = IntPtr.Zero;
+                               if (zz != IntPtr.Zero)
+                                       CloseZStream (zz); // This will Flush() the remaining output if any
+                       }
+
+                       if (data.IsAllocated) {
+                               data.Free ();
+                       }
+               }
+
+               public void Flush ()
+               {
+                       var res = Flush (z_stream);
+                       CheckResult (res, "Flush");
+               }
+
+               public int ReadZStream (IntPtr buffer, int length)
+               {
+                       var res = ReadZStream (z_stream, buffer, length);
+                       CheckResult (res, "ReadInternal");
+                       return res;
+               }
+
+               public void WriteZStream (IntPtr buffer, int length)
+               {
+                       var res = WriteZStream (z_stream, buffer, length);
+                       CheckResult (res, "WriteInternal");
+               }
+
+#if MONOTOUCH
+               [MonoPInvokeCallback (typeof (UnmanagedReadOrWrite))]
+#endif
+               static int UnmanagedRead (IntPtr buffer, int length, IntPtr data)
+               {
+                       GCHandle s = GCHandle.FromIntPtr (data);
+                       var self = s.Target as DeflateStreamNative;
+                       if (self == null)
+                               return -1;
+                       return self.UnmanagedRead (buffer, length);
+               }
+
+               int UnmanagedRead (IntPtr buffer, int length)
+               {
+                       int total = 0;
+                       int n = 1;
+                       while (length > 0 && n > 0) {
+                               if (io_buffer == null)
+                                       io_buffer = new byte [BufferSize];
+
+                               int count = Math.Min (length, io_buffer.Length);
+                               n = base_stream.Read (io_buffer, 0, count);
+                               if (n > 0) {
+                                       Marshal.Copy (io_buffer, 0, buffer, n);
+                                       unsafe {
+                                               buffer = new IntPtr ((byte *) buffer.ToPointer () + n);
+                                       }
+                                       length -= n;
+                                       total += n;
+                               }
+                       }
+                       return total;
+               }
+
+#if MONOTOUCH
+               [MonoPInvokeCallback (typeof (UnmanagedReadOrWrite))]
+#endif
+               static int UnmanagedWrite (IntPtr buffer, int length, IntPtr data)
+               {
+                       GCHandle s = GCHandle.FromIntPtr (data);
+                       var self = s.Target as DeflateStreamNative;
+                       if (self == null)
+                               return -1;
+                       return self.UnmanagedWrite (buffer, length);
+               }
+
+               int UnmanagedWrite (IntPtr buffer, int length)
+               {
+                       int total = 0;
+                       while (length > 0) {
+                               if (io_buffer == null)
+                                       io_buffer = new byte [BufferSize];
+
+                               int count = Math.Min (length, io_buffer.Length);
+                               Marshal.Copy (buffer, io_buffer, 0, count);
+                               base_stream.Write (io_buffer, 0, count);
+                               unsafe {
+                                       buffer = new IntPtr ((byte *) buffer.ToPointer () + count);
+                               }
+                               length -= count;
+                               total += count;
+                       }
+                       return total;
+               }
+
+               static void CheckResult (int result, string where)
+               {
+                       if (result >= 0)
+                               return;
+
+                       string error;
+                       switch (result) {
+                       case -1: // Z_ERRNO
+                               error = "Unknown error"; // Marshal.GetLastWin32() ?
+                               break;
+                       case -2: // Z_STREAM_ERROR
+                               error = "Internal error";
+                               break;
+                       case -3: // Z_DATA_ERROR
+                               error = "Corrupted data";
+                               break;
+                       case -4: // Z_MEM_ERROR
+                               error = "Not enough memory";
+                               break;
+                       case -5: // Z_BUF_ERROR
+                               error = "Internal error (no progress possible)";
+                               break;
+                       case -6: // Z_VERSION_ERROR
+                               error = "Invalid version";
+                               break;
+                       case -10:
+                               error = "Invalid argument(s)";
+                               break;
+                       case -11:
+                               error = "IO error";
+                               break;
+                       default:
+                               error = "Unknown error";
+                               break;
+                       }
+
+                       throw new IOException (error + " " + where);
+               }
 
 #if MONOTOUCH || MONODROID
                const string LIBNAME = "__Internal";
index c9eea9c165b380e9e9477f48729589ac7a55ca6f..02e3dc71c0e1764351ba339c28a7fa9bc3250cc7 100644 (file)
@@ -181,24 +181,45 @@ namespace MonoTests.Microsoft.CSharp
                [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);
+                       ns.Imports.Add (new CodeNamespaceImport ("Z"));
+                       ns.Imports.Add (new CodeNamespaceImport ("A"));
                        codeUnit.Namespaces.Add (ns);
-               }
 
-               private static void AddAssemblyAttribute (CodeCompileUnit codeUnit, string attributeName) {
                        CodeAttributeDeclaration attrDec = new CodeAttributeDeclaration ();
-                       attrDec.Name = attributeName;
+                       attrDec.Name = "A";
                        codeUnit.AssemblyCustomAttributes.Add (attrDec);
+
+                       Assert.AreEqual (string.Format (CultureInfo.InvariantCulture,
+                               "using A;{0}using Z;{0}{0}[assembly: A()]{0}{0}{0}", NewLine), Generate ());
+               }
+
+               [Test]
+               public void GlobalAttributeBeforeType ()
+               {
+                       StringWriter writer = new StringWriter ();
+                       writer.NewLine = NewLine;
+
+                       codeUnit = new CodeCompileUnit () {
+                               AssemblyCustomAttributes = {
+                                       new CodeAttributeDeclaration (
+                                               new CodeTypeReference (typeof (CLSCompliantAttribute)),
+                                               new CodeAttributeArgument (new CodePrimitiveExpression (false))),
+                               },
+                               Namespaces = {
+                                       new CodeNamespace () {
+                                               Types = {
+                                                       new CodeTypeDeclaration ("Resources"),
+                                               },
+                                       }
+                               },
+                       };
+
+                       generator.GenerateCodeFromCompileUnit (codeUnit, writer, options);
+                       writer.Close ();
+
+                       Assert.AreEqual (string.Format (CultureInfo.InvariantCulture,
+                               "[assembly: System.CLSCompliantAttribute(false)]{0}{0}{0}{0}public class Resources {{{0}}}{0}", NewLine), Generate ());
                }
        }
 }
diff --git a/mcs/class/System/mobile_static_System.dll.sources b/mcs/class/System/mobile_static_System.dll.sources
new file mode 100644 (file)
index 0000000..7bb9316
--- /dev/null
@@ -0,0 +1,76 @@
+#include mobile_System.dll.sources
+MonoTouch/MonoPInvokeCallbackAttribute.cs
+../Mono.Security/Mono.Security.Authenticode/PrivateKey.cs
+../Mono.Security/Mono.Security.Cryptography/MD5SHA1.cs
+../Mono.Security/Mono.Security.Cryptography/TlsHMAC.cs
+../Mono.Security/Mono.Security.Protocol.Ntlm/ChallengeResponse.cs
+../Mono.Security/Mono.Security.Protocol.Ntlm/ChallengeResponse2.cs
+../Mono.Security/Mono.Security.Protocol.Ntlm/MessageBase.cs
+../Mono.Security/Mono.Security.Protocol.Ntlm/NtlmAuthLevel.cs
+../Mono.Security/Mono.Security.Protocol.Ntlm/NtlmFlags.cs
+../Mono.Security/Mono.Security.Protocol.Ntlm/Type1Message.cs
+../Mono.Security/Mono.Security.Protocol.Ntlm/Type2Message.cs
+../Mono.Security/Mono.Security.Protocol.Ntlm/Type3Message.cs
+../Mono.Security/Mono.Security.Protocol.Tls/Alert.cs
+../Mono.Security/Mono.Security.Protocol.Tls/CipherAlgorithmType.cs
+../Mono.Security/Mono.Security.Protocol.Tls/CipherSuite.cs
+../Mono.Security/Mono.Security.Protocol.Tls/CipherSuiteCollection.cs
+../Mono.Security/Mono.Security.Protocol.Tls/CipherSuiteFactory.cs
+../Mono.Security/Mono.Security.Protocol.Tls/ClientContext.cs
+../Mono.Security/Mono.Security.Protocol.Tls/ClientRecordProtocol.cs
+../Mono.Security/Mono.Security.Protocol.Tls/ClientSessionCache.cs
+../Mono.Security/Mono.Security.Protocol.Tls/ContentType.cs
+../Mono.Security/Mono.Security.Protocol.Tls/Context.cs
+../Mono.Security/Mono.Security.Protocol.Tls/DebugHelper.cs
+../Mono.Security/Mono.Security.Protocol.Tls/ExchangeAlgorithmType.cs
+../Mono.Security/Mono.Security.Protocol.Tls/HandshakeState.cs
+../Mono.Security/Mono.Security.Protocol.Tls/HashAlgorithmType.cs
+../Mono.Security/Mono.Security.Protocol.Tls/HttpsClientStream.cs
+../Mono.Security/Mono.Security.Protocol.Tls/RecordProtocol.cs
+../Mono.Security/Mono.Security.Protocol.Tls/RSASslSignatureDeformatter.cs
+../Mono.Security/Mono.Security.Protocol.Tls/RSASslSignatureFormatter.cs
+../Mono.Security/Mono.Security.Protocol.Tls/SecurityCompressionType.cs
+../Mono.Security/Mono.Security.Protocol.Tls/SecurityParameters.cs
+../Mono.Security/Mono.Security.Protocol.Tls/SecurityProtocolType.cs
+../Mono.Security/Mono.Security.Protocol.Tls/ServerContext.cs
+../Mono.Security/Mono.Security.Protocol.Tls/ServerRecordProtocol.cs
+../Mono.Security/Mono.Security.Protocol.Tls/SslClientStream.cs
+../Mono.Security/Mono.Security.Protocol.Tls/SslCipherSuite.cs
+../Mono.Security/Mono.Security.Protocol.Tls/SslHandshakeHash.cs
+../Mono.Security/Mono.Security.Protocol.Tls/SslServerStream.cs
+../Mono.Security/Mono.Security.Protocol.Tls/SslStreamBase.cs
+../Mono.Security/Mono.Security.Protocol.Tls/TlsCipherSuite.cs
+../Mono.Security/Mono.Security.Protocol.Tls/TlsClientSettings.cs
+../Mono.Security/Mono.Security.Protocol.Tls/TlsException.cs
+../Mono.Security/Mono.Security.Protocol.Tls/TlsServerSettings.cs
+../Mono.Security/Mono.Security.Protocol.Tls/TlsStream.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake/ClientCertificateType.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake/HandshakeMessage.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake/HandshakeType.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Client/TlsClientCertificate.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Client/TlsClientCertificateVerify.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Client/TlsClientFinished.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Client/TlsClientHello.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Client/TlsClientKeyExchange.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Client/TlsServerCertificate.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Client/TlsServerCertificateRequest.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Client/TlsServerFinished.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Client/TlsServerHello.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Client/TlsServerHelloDone.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Client/TlsServerKeyExchange.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Server/TlsClientCertificate.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Server/TlsClientCertificateVerify.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Server/TlsClientFinished.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Server/TlsClientHello.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Server/TlsClientKeyExchange.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Server/TlsServerCertificate.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Server/TlsServerCertificateRequest.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Server/TlsServerFinished.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Server/TlsServerHello.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Server/TlsServerHelloDone.cs
+../Mono.Security/Mono.Security.Protocol.Tls.Handshake.Server/TlsServerKeyExchange.cs
+../Mono.Security/Mono.Security.X509.Extensions/AuthorityKeyIdentifierExtension.cs
+../Mono.Security/Mono.Security.X509.Extensions/ExtendedKeyUsageExtension.cs
+../Mono.Security/Mono.Security.X509.Extensions/GeneralNames.cs
+../Mono.Security/Mono.Security.X509.Extensions/NetscapeCertTypeExtension.cs
+../Mono.Security/Mono.Security.X509.Extensions/SubjectAltNameExtension.cs
index 1ea166cd9ac3134a1165f5513852e53a8112fb9d..2ec5f3be0b489652f82eb7d21ab39be1c4241b0c 100644 (file)
@@ -42,31 +42,31 @@ namespace System.Collections.ObjectModel
 {
        [Serializable]
        public class ObservableCollection<T> : Collection<T>, INotifyCollectionChanged, INotifyPropertyChanged {
-               
-               private class Reentrant : IDisposable {
-                       private int count = 0;
+               [Serializable]
+               sealed class SimpleMonitor : IDisposable {
+                       private int _busyCount;
 
-                       public Reentrant()
+                       public SimpleMonitor()
                        {
                        }
 
                        public void Enter()
                        {
-                               count++;
+                               _busyCount++;
                        }
 
                        public void Dispose()
                        {
-                               count--;
+                               _busyCount--;
                        }
 
                        public bool Busy
                        {
-                               get { return count > 0; }
+                               get { return _busyCount > 0; }
                        }
                }
 
-               private Reentrant reentrant = new Reentrant ();
+               private SimpleMonitor _monitor = new SimpleMonitor ();
 
                public ObservableCollection()
                {
@@ -86,7 +86,9 @@ namespace System.Collections.ObjectModel
                {
                }
 
+               [field:NonSerialized]
                public virtual event NotifyCollectionChangedEventHandler CollectionChanged;
+               [field:NonSerialized]
                protected virtual event PropertyChangedEventHandler PropertyChanged;
 
                event PropertyChangedEventHandler INotifyPropertyChanged.PropertyChanged {
@@ -96,8 +98,8 @@ namespace System.Collections.ObjectModel
 
                protected IDisposable BlockReentrancy ()
                {
-                       reentrant.Enter ();
-                       return reentrant;
+                       _monitor.Enter ();
+                       return _monitor;
                }
 
                protected void CheckReentrancy ()
@@ -105,7 +107,7 @@ namespace System.Collections.ObjectModel
                        NotifyCollectionChangedEventHandler eh = CollectionChanged;
 
                        // Only have a problem if we have more than one event listener.
-                       if (reentrant.Busy && eh != null && eh.GetInvocationList ().Length > 1)
+                       if (_monitor.Busy && eh != null && eh.GetInvocationList ().Length > 1)
                                throw new InvalidOperationException ("Cannot modify the collection while reentrancy is blocked.");
                }
 
index 6c68aa2025a917401a1ff658c554838f6ad49155..2b3026c2ce71135c53e5c9d6fbf8f705198af625 100644 (file)
@@ -10,10 +10,23 @@ using System.Xml.XPath;
 var template_android = File.ReadAllText ("project_template_android.txt");
 var template_ios = File.ReadAllText ("project_template_ios.txt");
 
-var guids_android = new string [] { "4fa878dc-6e88-43c4-b37b-8c1151cec56f", "fef62c23-10cd-4def-a5ae-54a8b309e970", "d263c126-9d3c-4299-a0c1-f25c703d07c9", "ec704077-ea31-4852-ad24-6732244174c0", "9360e845-d79d-4288-9100-63a80fad2bf0", "00dc3654-e373-4e3f-80fe-109f795adf1f", "e662282b-4341-4f86-aaaa-a942335b47fb", "a153a379-670c-42c2-9018-fc0d933a4f7f", "b29d45a6-0b8c-49c5-82a2-457e4d3cbc33", "3a3b5e76-029f-46b0-9ccf-fefe06eb61e7", "cb2ab716-bfcb-43bc-a03b-a3bda427746c", "73c5260f-8972-4e7c-822b-1a3a0358fa0b" };
-var guids_ios = new string [] { "6f2675f5-fcc7-4a28-9dc3-657b4613dcc5", "a67f34b5-75c1-4319-a93e-93df87e728a4", "79a43ceb-1a18-49ea-aac4-b72b9c90bf5a", "0a977063-0796-4cd4-84b8-aedb2d648b26", "b41cb61a-dca0-4539-8f99-7b3499e18e6d", "24f995bd-7075-489c-b7a5-7fde08c304b6", "894021ec-14fb-430a-8572-bea9569ae435", "92857c8e-0e83-4d02-a831-8af3fed43336", "912e14a2-7bdf-4600-8d55-e8c4f33a2063", "0f6c2933-8d0c-41e6-9f77-e8714ab8c4ab", "47d85a91-e8e2-4088-bf5a-68a161754d48", "45377009-1425-47fc-985e-05f98022f9e3" };
+var guids_android = new string [] { 
+// Ix
+"5F7F40B6-19D3-48C7-8E15-AE1F976F60E1", "065F2411-7610-4AD6-9513-A1EFFCE576C0",
+"C4037060-1692-4423-B29E-76F3A74A72A5",
+// Rx
+"4fa878dc-6e88-43c4-b37b-8c1151cec56f", "fef62c23-10cd-4def-a5ae-54a8b309e970", "d263c126-9d3c-4299-a0c1-f25c703d07c9", "ec704077-ea31-4852-ad24-6732244174c0", "9360e845-d79d-4288-9100-63a80fad2bf0", "00dc3654-e373-4e3f-80fe-109f795adf1f", "e662282b-4341-4f86-aaaa-a942335b47fb", "a153a379-670c-42c2-9018-fc0d933a4f7f", "b29d45a6-0b8c-49c5-82a2-457e4d3cbc33", "3a3b5e76-029f-46b0-9ccf-fefe06eb61e7", "cb2ab716-bfcb-43bc-a03b-a3bda427746c", "73c5260f-8972-4e7c-822b-1a3a0358fa0b" };
+var guids_ios = new string [] {
+// Ix
+"AD6FCBE9-0F6A-4F27-8147-17AB1C8799A2", "220AD2F1-FEE9-4514-8F36-6BE37F0AAD7F",
+"4779C7FF-6969-4715-9389-DF6C43655D6F",
+// Rx
+"6f2675f5-fcc7-4a28-9dc3-657b4613dcc5", "a67f34b5-75c1-4319-a93e-93df87e728a4", "79a43ceb-1a18-49ea-aac4-b72b9c90bf5a", "0a977063-0796-4cd4-84b8-aedb2d648b26", "b41cb61a-dca0-4539-8f99-7b3499e18e6d", "24f995bd-7075-489c-b7a5-7fde08c304b6", "894021ec-14fb-430a-8572-bea9569ae435", "92857c8e-0e83-4d02-a831-8af3fed43336", "912e14a2-7bdf-4600-8d55-e8c4f33a2063", "0f6c2933-8d0c-41e6-9f77-e8714ab8c4ab", "47d85a91-e8e2-4088-bf5a-68a161754d48", "45377009-1425-47fc-985e-05f98022f9e3" };
 
 var asses = new string [] {
+       "System.Interactive",
+       "System.Interactive.Async",
+       "System.Interactive.Providers",
        "System.Reactive.Interfaces",
        "System.Reactive.Core",
        "System.Reactive.PlatformServices",
@@ -45,20 +58,28 @@ var blacklist = new string [] {
        "ObservableConcurrencyTest.cs",
        };
 
-var dstAndroid = "../../external/rx/Rx/NET/Source/Rx_Xamarin/android";
-var dstIOS = "../../external/rx/Rx/NET/Source/Rx_Xamarin/iOS";
-
 int guid_idx = 0;
 foreach (var ass in asses) {
 
+       var ix = ass.Contains ("Interactive");
+
+       var dstAndroid = ix ? "../../external/rx/Ix/NET/Ix_Xamarin/android" :
+               "../../external/rx/Rx/NET/Source/Rx_Xamarin/android";
+       var dstIOS = ix ? "../../external/rx/Ix/NET/Ix_Xamarin/iOS" :
+               "../../external/rx/Rx/NET/Source/Rx_Xamarin/iOS";
+
+
        var monoass = ass == "Microsoft.Reactive.Testing" ?
                "Mono.Reactive.Testing" : ass;
-       var basePath = "../../external/rx/Rx/NET/Source";
+       var basePath = ix ? "../../external/rx/Ix/NET" :
+               "../../external/rx/Rx/NET/Source";
        var csproj = Path.Combine (basePath, ass, ass + ".csproj");
        var pathPrefix = ass == "Tests.System.Reactive" ? "../" : "";
 
-       var android_dir = Path.GetFullPath (Path.Combine (csproj, "..", "..", "Rx_Xamarin", "android", "rx", monoass));
-       var ios_dir = Path.GetFullPath (Path.Combine (csproj, "..", "..", "Rx_Xamarin", "iOS", "rx", monoass));
+       var category = ix ? "Ix_Xamarin" : "Rx_Xamarin";
+       var category2 = ix ? "ix" : "rx";
+       var android_dir = Path.GetFullPath (Path.Combine (csproj, "..", "..", category, "android", category2, monoass));
+       var ios_dir = Path.GetFullPath (Path.Combine (csproj, "..", "..", category, "iOS", category2, monoass));
        var android_proj = Path.Combine (android_dir, "android_" + monoass + ".csproj");
        var ios_proj = Path.Combine (ios_dir, "ios_" + monoass + ".csproj");
        if (!Directory.Exists (android_dir))
index 5bdc14633c0cd1faeec5afc7dfa089ac1f66885f..7c0f829a38009aeef38578e6b3fda3755c6f2bf0 100644 (file)
@@ -32,6 +32,7 @@
 
 using System.Globalization;
 using System.Runtime.InteropServices;
+using System.Collections.Generic;
 
 namespace System.Reflection
 {
@@ -400,12 +401,12 @@ namespace System.Reflection
                                                if (i < names.Length)
                                                        continue;
 
-                                               selected = SelectMethod (bindingAttr, new MethodBase [] { m }, newTypes, newModifiers, true, args);
+                                               selected = SelectMethod (bindingAttr, new MethodBase [] { m }, newTypes, newModifiers, true, ref args);
                                                if (selected != null)
                                                        break;
                                        }
                                } else {
-                                       selected = SelectMethod (bindingAttr, match, types, modifiers, true, args);
+                                       selected = SelectMethod (bindingAttr, match, types, modifiers, true, ref args);
                                }
 
                                state = null;
@@ -618,11 +619,11 @@ namespace System.Reflection
 
                        public override MethodBase SelectMethod (BindingFlags bindingAttr, MethodBase [] match, Type [] types, ParameterModifier [] modifiers)
                        {
-                               return SelectMethod (bindingAttr, match, types, modifiers,
-                                       false, null);
+                               object[] args = null;
+                               return SelectMethod (bindingAttr, match, types, modifiers, false, ref args);
                        }
 
-                       MethodBase SelectMethod (BindingFlags bindingAttr, MethodBase[] match, Type[] types, ParameterModifier[] modifiers, bool allowByRefMatch, object[] arguments)
+                       MethodBase SelectMethod (BindingFlags bindingAttr, MethodBase[] match, Type[] types, ParameterModifier[] modifiers, bool allowByRefMatch, ref object[] arguments)
                        {
                                MethodBase m;
                                int i, j;
@@ -685,22 +686,57 @@ namespace System.Reflection
                                        return null;
 
                                MethodBase result = null;
+                               ParameterInfo[] result_pi = null;
                                for (i = 0; i < match.Length; ++i) {
                                        m = match [i];
-                                       ParameterInfo[] args = m.GetParametersInternal ();
-                                       if (args.Length != types.Length)
-                                               continue;
-                                       if (!check_arguments (types, args, allowByRefMatch))
+                                       var pi = m.GetParametersInternal ();
+                                       var full_pi = pi;
+                                       if (pi.Length != types.Length) {
+                                               if ((bindingAttr & BindingFlags.OptionalParamBinding) == 0)
+                                                       continue;
+
+                                               List<ParameterInfo> pi_reduced = null;
+                                               for (var ii = pi.Length - 1; ii >= 0; --ii) {
+                                                       if ((pi [ii].Attributes & ParameterAttributes.HasDefault) == 0)
+                                                               break;
+
+                                                       if (pi_reduced == null) {
+                                                               pi_reduced = new List<ParameterInfo> (pi);
+                                                       }
+
+                                                       pi_reduced.RemoveAt (ii);
+                                               }
+
+                                               if (pi_reduced == null || pi_reduced.Count != types.Length)
+                                                       continue;
+
+                                               pi = pi_reduced.ToArray ();
+                                       }
+
+                                       if (!check_arguments (types, pi, allowByRefMatch))
                                                continue;
 
-                                       if (result != null)
+                                       if (result != null) {
                                                result = GetBetterMethod (result, m, types);
-                                       else
-                                               result = m;
+                                               if (result != m)
+                                                       continue;
+                                       }
+
+                                       result = m;
+                                       result_pi = full_pi;
                                }
 
-                               if (result != null || arguments == null || types.Length != arguments.Length)
+                               if (result != null) {
+                                       i = arguments == null ? 0 : arguments.Length;
+                                       Array.Resize (ref arguments, result_pi.Length);
+                                       for (; i < arguments.Length; ++i)
+                                               arguments [i] = result_pi [i].DefaultValue;
+
                                        return result;
+                               }
+
+                               if (arguments == null || types.Length != arguments.Length)
+                                       return null;
 
                                // Xamarin-5278: try with parameters that are COM objects
                                // REVIEW: do we also need to implement best method match?
index 03cbfe1a8fb0ae6b1377cb755d925db8f9705028..4cd3779172c0cecba59890f2de6cb83dbb5b89ee 100644 (file)
@@ -235,7 +235,7 @@ namespace System.Security.Cryptography {
 
                        HashAlgorithm hash = null;
                        if (halg is String)
-                               hash = HashAlgorithm.Create ((String)halg);
+                               hash = GetHashFromString ((string) halg);
                        else if (halg is HashAlgorithm)
                                hash = (HashAlgorithm) halg;
                        else if (halg is Type)
@@ -243,8 +243,25 @@ namespace System.Security.Cryptography {
                        else
                                throw new ArgumentException ("halg");
 
+                       if (hash == null)
+                               throw new ArgumentException (
+                                               "Could not find provider for halg='" + halg + "'.",
+                                               "halg");
+
                        return hash;
                }
+
+               private HashAlgorithm GetHashFromString (string name)
+               {
+                       HashAlgorithm hash = HashAlgorithm.Create (name);
+                       if (hash != null)
+                               return hash;
+                       try {
+                               return HashAlgorithm.Create (GetHashNameFromOID (name));
+                       } catch (CryptographicException e) {
+                               throw new ArgumentException (e.Message, "halg", e);
+                       }
+               }
        
                // NOTE: this method can work with ANY configured (OID in machine.config) 
                // HashAlgorithm descendant
index cf2e6f23efcfd5758a60892787b165434656fbbc..c44176989c8acdac1df35754ad32cffbc069bf14 100644 (file)
@@ -108,10 +108,11 @@ public abstract class Decoder
                CheckArguments (chars, charCount, bytes, byteCount);
 
                char [] carr = new char [charCount];
-               Marshal.Copy ((IntPtr) chars, carr, 0, charCount);
                byte [] barr = new byte [byteCount];
                Marshal.Copy ((IntPtr) bytes, barr, 0, byteCount);
-               return GetChars (barr, 0, byteCount, carr, 0, flush);
+               int charsUsed = GetChars (barr, 0, byteCount, carr, 0, flush);
+               Marshal.Copy (carr, 0, (IntPtr) chars, charsUsed);
+               return charsUsed;
        }
 
        [ComVisible (false)]
index 5c4cedf15b02994fd6c90bac1d7c03be391fd599..719f43020e08092ce05d16e1ced024308e4f6230 100644 (file)
@@ -98,11 +98,9 @@ namespace System.Threading
                }
 #endif
 
-               [MonoTODO]
                protected void SetWaitNotificationRequired ()
                {
                        notification_required = true;
-                       throw new NotImplementedException ();
                }
 
                [CLSCompliant (false)]
index 696df9abdd581cd45240712b22e61ef741e8fdbc..08f8a4c1da1bfe92ecd879883d42b60b86374e1e 100644 (file)
@@ -155,7 +155,7 @@ namespace System
 // FULL_AOT_RUNTIME is used (instead of MONOTOUCH) since we only want this code when running on 
 // iOS (simulator or devices) and *not* when running tools (e.g. btouch #12179) that needs to use 
 // the mscorlib.dll shipped with Xamarin.iOS
-#if FULL_AOT_RUNTIME
+#if MONOTOUCH && FULL_AOT_RUNTIME
                                stdout = new NSLogWriter ();
 #else
                                stdout = new UnexceptionalStreamWriter (OpenStandardOutput (0), outputEncoding);
@@ -163,7 +163,7 @@ namespace System
 #endif
                                stdout = TextWriter.Synchronized (stdout, true);
 
-#if FULL_AOT_RUNTIME
+#if MONOTOUCH && FULL_AOT_RUNTIME
                                stderr = new NSLogWriter ();
 #else
                                stderr = new UnexceptionalStreamWriter (OpenStandardError (0), outputEncoding); 
index 42ff390b6d74f46bcc977c0a2acffeef1a74b9ed..ad6329ec8e7349551a2b70443fae0375f332c41b 100644 (file)
@@ -38,7 +38,7 @@
 using System.Runtime.InteropServices;
 using System.Security.Cryptography;
 using System.Text;
-#if FULL_AOT_RUNTIME
+#if MONOTOUCH && FULL_AOT_RUNTIME
 using Crimson.CommonCrypto;
 #endif
 
@@ -48,7 +48,7 @@ namespace System {
        [StructLayout (LayoutKind.Sequential)]
        [ComVisible (true)]
        public struct Guid : IFormattable, IComparable, IComparable<Guid>, IEquatable<Guid> {
-#if FULL_AOT_RUNTIME
+#if MONOTOUCH
                static Guid () {
                        if (MonoTouchAOTHelper.FalseFlag) {
                                var comparer = new System.Collections.Generic.GenericComparer <Guid> ();
@@ -472,6 +472,15 @@ namespace System {
                private static RandomNumberGenerator _fastRng;
 #endif
 
+#if FULL_AOT_RUNTIME && !MONOTOUCH
+               // NSA approved random generator.
+               static void LameRandom (byte [] b)
+               {
+                       var r = new Random ();
+                       r.NextBytes (b);
+               }
+#endif
+               
                // generated as per section 3.4 of the specification
                public static Guid NewGuid ()
                {
@@ -483,8 +492,10 @@ namespace System {
                                        _rng = RandomNumberGenerator.Create ();
                                _rng.GetBytes (b);
                        }
-#else
+#elif MONOTOUCH
                        Cryptor.GetRandom (b);
+#else
+                       LameRandom (b);
 #endif
 
                        Guid res = new Guid (b);
index 3cc7b18dfb8c1bbc02016ba4254fb2e24759db9c..8ac242b346e64ac4cfc6b37d96b88765f6c9470a 100644 (file)
@@ -247,7 +247,7 @@ namespace System
                                obj = Marshal.PtrToStringBSTR(Marshal.ReadIntPtr(addr));
                                break;
 // GetObjectForIUnknown is excluded from Marshal using FULL_AOT_RUNTIME
-#if !MONOTOUCH
+#if !DISABLE_COM
                        case VarEnum.VT_UNKNOWN:
                        case VarEnum.VT_DISPATCH:
                        {
index 4a6ac7db8a086cc2b23c5206f3044aabf1d2d212..7714f53ab3251892b0f2e34cb38ca2f20cbcacb3 100644 (file)
@@ -571,6 +571,14 @@ namespace MonoTests.System.Globalization
                        Assert.AreEqual (31748, new CultureInfo ("zh-CHT").LCID);
                        Assert.AreEqual (31748, new CultureInfo ("zh-CHT").Parent.LCID);
                }
+
+               [Test]
+               [SetCulture ("zh-TW")]
+               public void ParentOfZh ()
+               {
+                       Assert.AreEqual (31748, CultureInfo.CurrentCulture.Parent.LCID);
+                       Assert.AreEqual (31748, CultureInfo.CurrentCulture.Parent.Parent.LCID);
+               }
                
                [Test]
                public void CurrentCulture ()
index 08235e8cec6c5f52e4df234210a334767fdb61f3..ab0c5356aff0c33c7b5731492387a3a638c2d4ae 100644 (file)
@@ -174,6 +174,14 @@ namespace MonoTests.System.Reflection
                }
        }
 
+       class DefaultValues
+       {
+               public int Value;
+               public DefaultValues (int i = 5)
+               {
+                       Value = i;
+               }
+       }
 
        [TestFixture]
        public class BinderTest
@@ -187,6 +195,16 @@ namespace MonoTests.System.Reflection
                        var o = Activator.CreateInstance (typeof (ParamsArrayTest), new object[] { test_args });
                        Assert.IsNotNull (o, "#A1");
                }
+
+               [Test]
+               public void DefaultParameter ()
+               {
+                       var o = Activator.CreateInstance (typeof (DefaultValues),
+                               BindingFlags.CreateInstance | BindingFlags.Public | BindingFlags.Instance | BindingFlags.OptionalParamBinding,
+                               null, null, null);
+                       var a = o as DefaultValues;
+                       Assert.AreEqual (5, a.Value);
+               }
                
                [Test]
                [ExpectedException (typeof (ArgumentException))]
index 91b39eb832c5434a5a551018b4016e29bcd2afdd..01a3f9987f326267418e82808d60475c42c94c2b 100644 (file)
@@ -262,6 +262,26 @@ public class RSACryptoServiceProviderTest {
                rsa.SignData (data, MD5.Create ());
        }
 
+       [Test]
+       [ExpectedException (typeof (ArgumentException))]
+       public void SignDataWithInvalidOid ()
+       {
+               byte[] data = new byte [5];
+               rsa = new RSACryptoServiceProvider (minKeySize);
+
+               rsa.SignData (data, "1.2.3");
+       }
+
+       [Test]
+       public void SignDataWithOid ()
+       {
+               string oid  = CryptoConfig.MapNameToOID ("SHA256");
+               byte[] data = new byte [5];
+               rsa = new RSACryptoServiceProvider (minKeySize);
+
+               rsa.SignData (data, oid);
+       }
+
        [Test]
        [ExpectedException (typeof (ArgumentNullException))]
        public void SignHashNullValue () 
diff --git a/mcs/class/corlib/mobile_static_corlib.dll.sources b/mcs/class/corlib/mobile_static_corlib.dll.sources
new file mode 100644 (file)
index 0000000..da77893
--- /dev/null
@@ -0,0 +1 @@
+#include corlib.dll.sources
diff --git a/mcs/errors/cs0177-13.cs b/mcs/errors/cs0177-13.cs
new file mode 100644 (file)
index 0000000..b655a65
--- /dev/null
@@ -0,0 +1,14 @@
+// CS0177: The out parameter `baz' must be assigned to before control leaves the current method
+// Line: 6
+
+static class A
+{
+       public static void Foo (int i, out object baz)
+       {
+               switch (i) {
+               case 0:
+                       baz = 1;
+                       return;
+               }
+       }
+}
\ No newline at end of file
diff --git a/mcs/errors/cs0452-11.cs b/mcs/errors/cs0452-11.cs
new file mode 100644 (file)
index 0000000..f0681aa
--- /dev/null
@@ -0,0 +1,10 @@
+// CS0452: The type `int' must be a reference type in order to use it as type parameter `T' in the generic type or method `Program.M<T>(T, T)'
+// Line: 8
+
+class Program
+{
+       public static void M<T> (T item1, T item2 = null) where T : class
+       {
+               M (1);
+       }
+}
\ No newline at end of file
diff --git a/mcs/errors/cs1750-4.cs b/mcs/errors/cs1750-4.cs
new file mode 100644 (file)
index 0000000..4499780
--- /dev/null
@@ -0,0 +1,23 @@
+// CS1750: Optional parameter expression of type `null' cannot be converted to parameter type `A'
+// Line: 8
+
+using System;
+
+class GenericClass<T>
+{
+       public GenericClass (GenericClass<T> g = null, A a = null)
+       {
+       }
+}
+
+class DerivedClass<T> : GenericClass<T>
+{
+       public DerivedClass (GenericClass<T> g) : base(g)
+       {
+       }
+}
+
+public struct A
+{
+       public int Field;
+}
index cd9d1099f65ef1f58ba620a50bccf8fdfe931915..03ee9cc3b072236eefc71749d4696bb6a5c73690 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>MultiByte</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>MultiByte</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index 26a77a41a05755a1319ffe31e7579251bb23da9b..64d1c52e0633be55fe2a28201b3347513d0d592c 100644 (file)
@@ -956,6 +956,12 @@ namespace Mono.CSharp {
                        }
                }
 
+               public override bool IsSideEffectFree {
+                       get {
+                               return true;
+                       }
+               }
+
                public ParametersCompiled Parameters {
                        get {
                                return Block.Parameters;
index 09a22ef66dff9fd6867ed0ef2d9640ab691383ad..3f4d9f406631ad5dcfb8312e0e3136056838a45e 100644 (file)
@@ -187,6 +187,8 @@ namespace Mono.CSharp
 
                        next_part.PartialContainer = existing;
 
+                       existing.AddPartialPart (next_part);
+
                        AddTypeContainerMember (next_part);
                }
 
@@ -514,6 +516,9 @@ namespace Mono.CSharp
 
                protected List<FullNamedExpression> type_bases;
 
+               // Partial parts for classes only
+               List<TypeDefinition> class_partial_parts;
+
                TypeDefinition InTransit;
 
                public TypeBuilder TypeBuilder;
@@ -859,6 +864,17 @@ namespace Mono.CSharp
                        AddMember (op);
                }
 
+               public void AddPartialPart (TypeDefinition part)
+               {
+                       if (Kind != MemberKind.Class)
+                               return;
+
+                       if (class_partial_parts == null)
+                               class_partial_parts = new List<TypeDefinition> ();
+
+                       class_partial_parts.Add (part);
+               }
+
                public override void ApplyAttributeBuilder (Attribute a, MethodSpec ctor, byte[] cdata, PredefinedAttributes pa)
                {
                        if (has_normal_indexers && a.Type == pa.DefaultMember) {
@@ -1426,6 +1442,14 @@ namespace Mono.CSharp
                }
 
                protected bool DefineBaseTypes ()
+               {
+                       if (IsPartialPart && Kind == MemberKind.Class)
+                               return true;
+
+                       return DoDefineBaseType ();
+               }
+
+               bool DoDefineBaseType ()
                {
                        iface_exprs = ResolveBaseTypes (out base_type_expr);
                        bool set_base_type;
@@ -1518,6 +1542,18 @@ namespace Mono.CSharp
                                SetBaseType ();
                        }
 
+                       //
+                       // Base type of partial container has to be resolved before we
+                       // resolve any nested types of the container. We need to know
+                       // partial parts because the base type can be specified in file
+                       // defined after current container
+                       //
+                       if (class_partial_parts != null) {
+                               foreach (var pp in class_partial_parts)
+                                       pp.DoDefineBaseType ();
+
+                       }
+
                        return true;
                }
 
index f190cc941cd1d64ad42cc2b9875e0d86108e379c..a4f7df436ca42d42cfd5a482a2cc36e796a9bd3d 100644 (file)
@@ -299,6 +299,16 @@ namespace Mono.CSharp
 #endif
                }
 
+               public void BeginCompilerScope ()
+               {
+                       if ((flags & Options.OmitDebugInfo) != 0)
+                               return;
+
+#if NET_4_0
+                       methodSymbols.StartBlock (CodeBlockEntry.Type.CompilerGenerated, ig.ILOffset);
+#endif
+               }
+
                public void EndExceptionBlock ()
                {
                        ig.EndExceptionBlock ();
index 1a70f55d8f83fdfece957397b44f6b02edefb7fb..f51bfab660900ca6aa8dab4783b4e446778341dc 100644 (file)
@@ -162,6 +162,88 @@ namespace Mono.CSharp {
 #endif
                }
 
+               //
+               // Returns a constant instance based on value and type. This is probing version of
+               // CreateConstantFromValue
+               //
+               public static Constant ExtractConstantFromValue (TypeSpec t, object v, Location loc)
+               {
+                       switch (t.BuiltinType) {
+                       case BuiltinTypeSpec.Type.Int:
+                               if (v is int)
+                                       return new IntConstant (t, (int) v, loc);
+                               break;
+                       case BuiltinTypeSpec.Type.String:
+                               if (v is string)
+                                       return new StringConstant (t, (string) v, loc);
+                               break;
+                       case BuiltinTypeSpec.Type.UInt:
+                               if (v is uint)
+                                       return new UIntConstant (t, (uint) v, loc);
+                               break;
+                       case BuiltinTypeSpec.Type.Long:
+                               if (v is long)
+                                       return new LongConstant (t, (long) v, loc);
+                               break;
+                       case BuiltinTypeSpec.Type.ULong:
+                               if (v is ulong)
+                                       return new ULongConstant (t, (ulong) v, loc);
+                               break;
+                       case BuiltinTypeSpec.Type.Float:
+                               if (v is float)
+                                       return new FloatConstant (t, (float) v, loc);
+                               break;
+                       case BuiltinTypeSpec.Type.Double:
+                               if (v is double)
+                                       return new DoubleConstant (t, (double) v, loc);
+                               break;
+                       case BuiltinTypeSpec.Type.Short:
+                               if (v is short)
+                                       return new ShortConstant (t, (short) v, loc);
+                               break;
+                       case BuiltinTypeSpec.Type.UShort:
+                               if (v is ushort)
+                                       return new UShortConstant (t, (ushort) v, loc);
+                               break;
+                       case BuiltinTypeSpec.Type.SByte:
+                               if (v is sbyte)
+                                       return new SByteConstant (t, (sbyte) v, loc);
+                               break;
+                       case BuiltinTypeSpec.Type.Byte:
+                               if (v is byte)
+                                       return new ByteConstant (t, (byte) v, loc);
+                               break;
+                       case BuiltinTypeSpec.Type.Char:
+                               if (v is char)
+                                       return new CharConstant (t, (char) v, loc);
+                               break;
+                       case BuiltinTypeSpec.Type.Bool:
+                               if (v is bool)
+                                       return new BoolConstant (t, (bool) v, loc);
+                               break;
+                       case BuiltinTypeSpec.Type.Decimal:
+                               if (v is decimal)
+                                       return new DecimalConstant (t, (decimal) v, loc);
+                               break;
+                       }
+
+                       if (t.IsEnum) {
+                               var real_type = EnumSpec.GetUnderlyingType (t);
+                               return new EnumConstant (CreateConstantFromValue (real_type, v, loc), t);
+                       }
+
+                       if (v == null) {
+                               if (t.IsNullableType)
+                                       return Nullable.LiftedNull.Create (t, loc);
+
+                               if (TypeSpec.IsReferenceType (t))
+                                       return new NullConstant (t, loc);
+                       }
+
+                       return null;
+               }
+
+
                public override Expression CreateExpressionTree (ResolveContext ec)
                {
                        Arguments args = new Arguments (2);
index bfbfe0374955c5e6fc33957e3ecd2527d8594a99..63e87ebc32ca55bc6be69c82f0702eb73c25135e 100644 (file)
@@ -34,7 +34,7 @@ namespace Mono.CSharp {
                //
                static bool ArrayToIList (ArrayContainer array, TypeSpec list, bool isExplicit)
                {
-                       if (array.Rank != 1 || !list.IsGenericIterateInterface)
+                       if (array.Rank != 1 || !list.IsArrayGenericInterface)
                                return false;
 
                        var arg_type = list.TypeArguments[0];
@@ -55,7 +55,7 @@ namespace Mono.CSharp {
                
                static bool IList_To_Array(TypeSpec list, ArrayContainer array)
                {
-                       if (array.Rank != 1 || !list.IsGenericIterateInterface)
+                       if (array.Rank != 1 || !list.IsArrayGenericInterface)
                                return false;
 
                        var arg_type = list.TypeArguments[0];
index 099d2e94771f38f0888680022d8c5459a86315f7..54f5c6dff804a3eb5875428a129209742a6578f7 100644 (file)
@@ -3521,6 +3521,13 @@ namespace Mono.CSharp {
                        }
                }
 
+               public override bool IsSideEffectFree {
+                       get {
+                               return InstanceExpression != null ?
+                                       InstanceExpression.IsSideEffectFree : true;
+                       }
+               }
+
                public override bool IsStatic {
                        get {
                                if (best_candidate != null)
@@ -5365,6 +5372,7 @@ namespace Mono.CSharp {
                                        params_initializers.Add (a.Expr);
                                        args.RemoveAt (a_idx--);
                                        --arg_count;
+                                       a.Expr = conv;
                                        continue;
                                }
 
index 31b69fbeb86f5ff247936fde0b3b329c0416257e..3dd8709d20af2106f894057c7e288fb77b55c9fc 100644 (file)
@@ -1713,7 +1713,7 @@ namespace Mono.CSharp {
                        }
                }
 
-               public override bool IsGenericIterateInterface {
+               public override bool IsArrayGenericInterface {
                        get {
                                return (open_type.state & StateFlags.GenericIterateInterface) != 0;
                        }
@@ -3363,7 +3363,7 @@ namespace Mono.CSharp {
                                        return LowerBoundInference (u_ac.Element, v_ac.Element, inversed);
                                }
 
-                               if (u_ac.Rank != 1 || !v.IsGenericIterateInterface)
+                               if (u_ac.Rank != 1 || !v.IsArrayGenericInterface)
                                        return 0;
 
                                var v_i = TypeManager.GetTypeArguments (v) [0];
index d5788cc35c08aa7a267e5ea65f390b8ff26eae24..2d787dd4e3095c4746c71e22abd13b0480568ba0 100644 (file)
@@ -2110,7 +2110,13 @@ namespace Mono.CSharp
                                                if (get == null && set == null)
                                                        continue;
 
-                                               imported = importer.CreateProperty (p, declaringType, get, set);
+                                               try {
+                                                       imported = importer.CreateProperty (p, declaringType, get, set);
+                                               } catch (Exception ex) {
+                                                       throw new InternalErrorException (ex, "Could not import property `{0}' inside `{1}'",
+                                                               p.Name, declaringType.GetSignatureForError ());
+                                               }
+
                                                if (imported == null)
                                                        continue;
 
index 62ee7ab5aa8d6417ef00f8db80335abef0e570e7..fb940b4c2269c2f9f90fa966ee7f6ce515bba06a 100644 (file)
@@ -972,10 +972,18 @@ namespace Mono.CSharp {
                                        if (inflated_types[i] == expr.Type)
                                                continue;
 
-                                       if (expr is DefaultValueExpression)
+                                       var c = expr as Constant;
+                                       if (c != null) {
+                                               //
+                                               // It may fail we are inflating before type validation is done
+                                               //
+                                               c = Constant.ExtractConstantFromValue (inflated_types[i], c.GetValue (), expr.Location);
+                                               if (c == null)
+                                                       expr = new DefaultValueExpression (new TypeExpression (inflated_types[i], expr.Location), expr.Location);
+                                               else
+                                                       expr = c;
+                                       } else if (expr is DefaultValueExpression)
                                                expr = new DefaultValueExpression (new TypeExpression (inflated_types[i], expr.Location), expr.Location);
-                                       else if (expr is Constant)
-                                               expr = Constant.CreateConstantFromValue (inflated_types[i], ((Constant) expr).GetValue (), expr.Location);
 
                                        clone.FixedParameters[i] = new ParameterData (fp.Name, fp.ModFlags, expr);
                                }
@@ -1378,6 +1386,8 @@ namespace Mono.CSharp {
                        rc.Report.Error (1750, Location,
                                "Optional parameter expression of type `{0}' cannot be converted to parameter type `{1}'",
                                type.GetSignatureForError (), parameter_type.GetSignatureForError ());
+
+                       this.expr = ErrorExpression.Instance;
                }
                
                public override object Accept (StructuralVisitor visitor)
index 64d205081d5f023b4bd8636eececc9465376dd0e..b90f7aa06b4c9d14ebff2a78a05b241ee17663c1 100644 (file)
@@ -4170,7 +4170,7 @@ namespace Mono.CSharp {
                        var ok = block.Resolve (ec);
 
                        if (case_default == null)
-                               ec.CurrentBranching.CurrentUsageVector.ResetBarrier ();
+                               ec.CurrentBranching.CreateSibling (null, FlowBranching.SiblingType.SwitchSection);
 
                        ec.EndFlowBranching ();
                        ec.Switch = old_switch;
@@ -6448,14 +6448,20 @@ namespace Mono.CSharp {
 
                protected override void DoEmit (EmitContext ec)
                {
-                       variable.CreateBuilder (ec);
-
                        Label old_begin = ec.LoopBegin, old_end = ec.LoopEnd;
                        ec.LoopBegin = ec.DefineLabel ();
                        ec.LoopEnd = ec.DefineLabel ();
 
+                       if (!(statement is Block))
+                               ec.BeginCompilerScope ();
+
+                       variable.CreateBuilder (ec);
+
                        statement.Emit (ec);
 
+                       if (!(statement is Block))
+                               ec.EndScope ();
+
                        ec.LoopBegin = old_begin;
                        ec.LoopEnd = old_end;
                }
index b77dfef531fb6c6e9fddc1914ffa2641302857dd..870b7be2a754773b25c721b29e0fb28b38d4315c 100644 (file)
@@ -186,7 +186,9 @@ namespace Mono.CSharp
                public readonly PredefinedType IsVolatile;
                public readonly PredefinedType IEnumeratorGeneric;
                public readonly PredefinedType IListGeneric;
+               public readonly PredefinedType IReadOnlyListGeneric;
                public readonly PredefinedType ICollectionGeneric;
+               public readonly PredefinedType IReadOnlyCollectionGeneric;
                public readonly PredefinedType IEnumerableGeneric;
                public readonly PredefinedType Nullable;
                public readonly PredefinedType Activator;
@@ -246,7 +248,9 @@ namespace Mono.CSharp
                        IsVolatile = new PredefinedType (module, MemberKind.Class, "System.Runtime.CompilerServices", "IsVolatile");
                        IEnumeratorGeneric = new PredefinedType (module, MemberKind.Interface, "System.Collections.Generic", "IEnumerator", 1);
                        IListGeneric = new PredefinedType (module, MemberKind.Interface, "System.Collections.Generic", "IList", 1);
+                       IReadOnlyListGeneric = new PredefinedType (module, MemberKind.Interface, "System.Collections.Generic", "IReadOnlyList", 1);
                        ICollectionGeneric = new PredefinedType (module, MemberKind.Interface, "System.Collections.Generic", "ICollection", 1);
+                       IReadOnlyCollectionGeneric = new PredefinedType (module, MemberKind.Interface, "System.Collections.Generic", "IReadOnlyCollection", 1);
                        IEnumerableGeneric = new PredefinedType (module, MemberKind.Interface, "System.Collections.Generic", "IEnumerable", 1);
                        Nullable = new PredefinedType (module, MemberKind.Struct, "System", "Nullable", 1);
                        Activator = new PredefinedType (module, MemberKind.Class, "System", "Activator");
@@ -294,13 +298,19 @@ namespace Mono.CSharp
                                ArgIterator.TypeSpec.IsSpecialRuntimeType = true;
 
                        if (IEnumerableGeneric.Define ())
-                               IEnumerableGeneric.TypeSpec.IsGenericIterateInterface = true;
+                               IEnumerableGeneric.TypeSpec.IsArrayGenericInterface = true;
 
                        if (IListGeneric.Define ())
-                               IListGeneric.TypeSpec.IsGenericIterateInterface = true;
+                               IListGeneric.TypeSpec.IsArrayGenericInterface = true;
+
+                       if (IReadOnlyListGeneric.Define ())
+                               IReadOnlyListGeneric.TypeSpec.IsArrayGenericInterface = true;
 
                        if (ICollectionGeneric.Define ())
-                               ICollectionGeneric.TypeSpec.IsGenericIterateInterface = true;
+                               ICollectionGeneric.TypeSpec.IsArrayGenericInterface = true;
+
+                       if (IReadOnlyCollectionGeneric.Define ())
+                               IReadOnlyCollectionGeneric.TypeSpec.IsArrayGenericInterface = true;
 
                        if (Nullable.Define ())
                                Nullable.TypeSpec.IsNullableType = true;
index fd727a4a80c9a2f0b7179e39f1195ce68bef122b..a36033926bddace71f68d5083d969c5d91c2398a 100644 (file)
@@ -211,7 +211,7 @@ namespace Mono.CSharp
                //
                // Returns true for instances of IList<T>, IEnumerable<T>, ICollection<T>
                //
-               public virtual bool IsGenericIterateInterface {
+               public virtual bool IsArrayGenericInterface {
                        get {
                                return false;
                        }
diff --git a/mcs/tests/gtest-592.cs b/mcs/tests/gtest-592.cs
new file mode 100644 (file)
index 0000000..f32700c
--- /dev/null
@@ -0,0 +1,25 @@
+using System;
+using System.Collections.Generic;
+
+public class Tests
+{
+       static void A<T>(IReadOnlyCollection<T> otherList)
+       {
+       }
+
+       static void B<T>(IReadOnlyList<T> otherList)
+       {
+       }
+
+       public static void Main ()
+       {
+               var ifacers = typeof(int[]).GetInterfaces ();
+
+               var args = new string [0];
+               A (args);
+               B (args);
+
+               IReadOnlyList<int> e1 = new int[0];
+               IReadOnlyCollection<int> e2 = new int[0];
+       }
+}
diff --git a/mcs/tests/gtest-optional-28.cs b/mcs/tests/gtest-optional-28.cs
new file mode 100644 (file)
index 0000000..d8eaaa3
--- /dev/null
@@ -0,0 +1,31 @@
+using System;
+
+public class NoTypeOptionalParameters
+{
+       public static void Lambda (bool asc = true, params Func<string,bool>[] where)
+       {
+       }
+
+       public static void MethodGroup (bool asc = true, params Func<string,bool>[] where)
+       {
+       }
+
+       static bool Foo (string arg)
+       {
+               return false;
+       }
+
+       bool FooInstance (string arg)
+       {
+               return false;
+       }
+
+       public static int Main ()
+       {
+               bool i = false;
+               Lambda (where: x => true, asc: i);
+               MethodGroup (where: Foo, asc: i);
+               MethodGroup (where: new NoTypeOptionalParameters ().FooInstance, asc: false);
+               return 0;
+       }
+}
index 60ce461555d9ed94b2b6e91924ca8a336b443ba7..3792704d7124f56d7b49f02d6a22bbbf295a5934 100644 (file)
         <entry il="0x1e" row="243" col="2" file_ref="1" hidden="false" />
       </sequencepoints>
       <locals>
-        <entry name="a" il_index="0" scope_ref="0" />
+        <entry name="a" il_index="0" scope_ref="1" />
       </locals>
       <scopes>
-        <entry index="0" start="0xf" end="0x11" />
-        <entry index="1" start="0x10" end="0x10" />
+        <entry index="0" start="0x1" end="0x1e" />
+        <entry index="1" start="0xf" end="0x11" />
+        <entry index="2" start="0x10" end="0x10" />
       </scopes>
     </method>
     <method token="0x6000019">
         <entry il="0x37" row="253" col="2" file_ref="1" hidden="false" />
       </sequencepoints>
       <locals>
-        <entry name="a" il_index="0" scope_ref="0" />
+        <entry name="a" il_index="0" scope_ref="1" />
       </locals>
       <scopes>
-        <entry index="0" start="0x16" end="0x18" />
-        <entry index="1" start="0x17" end="0x17" />
+        <entry index="0" start="0x1" end="0x37" />
+        <entry index="1" start="0x16" end="0x18" />
+        <entry index="2" start="0x17" end="0x17" />
       </scopes>
     </method>
     <method token="0x600001a">
         <entry il="0x3c" row="263" col="2" file_ref="1" hidden="false" />
       </sequencepoints>
       <locals>
-        <entry name="a" il_index="0" scope_ref="0" />
+        <entry name="a" il_index="0" scope_ref="1" />
       </locals>
       <scopes>
-        <entry index="0" start="0x16" end="0x18" />
-        <entry index="1" start="0x17" end="0x17" />
+        <entry index="0" start="0x1" end="0x3c" />
+        <entry index="1" start="0x16" end="0x18" />
+        <entry index="2" start="0x17" end="0x17" />
       </scopes>
     </method>
     <method token="0x600001b">
         <entry il="0x4d" row="272" col="2" file_ref="1" hidden="false" />
       </sequencepoints>
       <locals>
-        <entry name="a" il_index="0" scope_ref="0" />
+        <entry name="a" il_index="0" scope_ref="1" />
       </locals>
       <scopes>
-        <entry index="0" start="0x2f" end="0x31" />
-        <entry index="1" start="0x30" end="0x30" />
+        <entry index="0" start="0x1" end="0x4d" />
+        <entry index="1" start="0x2f" end="0x31" />
+        <entry index="2" start="0x30" end="0x30" />
       </scopes>
     </method>
   </methods>
diff --git a/mcs/tests/test-debug-28-ref.xml b/mcs/tests/test-debug-28-ref.xml
new file mode 100644 (file)
index 0000000..d4a51b8
--- /dev/null
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="utf-8"?>
+<symbols>
+  <files>
+    <file id="1" name="test-debug-28.cs" checksum="0908758b6671839a79620b83da354859" />
+  </files>
+  <methods>
+    <method token="0x6000001">
+      <sequencepoints />
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x6000002">
+      <sequencepoints>
+        <entry il="0x0" row="4" col="2" file_ref="1" hidden="false" />
+        <entry il="0x1" row="5" col="3" file_ref="1" hidden="false" />
+        <entry il="0x2" row="5" col="21" file_ref="1" hidden="false" />
+        <entry il="0xb" row="5" col="12" file_ref="1" hidden="false" />
+        <entry il="0xf" row="5" col="21" file_ref="1" hidden="false" />
+        <entry il="0x1c" row="7" col="3" file_ref="1" hidden="false" />
+        <entry il="0x1d" row="7" col="21" file_ref="1" hidden="false" />
+        <entry il="0x28" row="7" col="12" file_ref="1" hidden="false" />
+        <entry il="0x2e" row="7" col="21" file_ref="1" hidden="false" />
+        <entry il="0x3f" row="9" col="2" file_ref="1" hidden="false" />
+      </sequencepoints>
+      <locals>
+        <entry name="v" il_index="0" scope_ref="1" />
+        <entry name="v" il_index="3" scope_ref="3" />
+      </locals>
+      <scopes>
+        <entry index="0" start="0x1" end="0x1c" />
+        <entry index="1" start="0xf" end="0xf" />
+        <entry index="2" start="0x1c" end="0x3f" />
+        <entry index="3" start="0x2e" end="0x2e" />
+      </scopes>
+    </method>
+    <method token="0x6000003">
+      <sequencepoints>
+        <entry il="0x0" row="12" col="2" file_ref="1" hidden="false" />
+        <entry il="0x1" row="13" col="3" file_ref="1" hidden="false" />
+        <entry il="0x8" row="14" col="2" file_ref="1" hidden="false" />
+      </sequencepoints>
+      <locals />
+      <scopes />
+    </method>
+  </methods>
+</symbols>
\ No newline at end of file
diff --git a/mcs/tests/test-debug-28.cs b/mcs/tests/test-debug-28.cs
new file mode 100644 (file)
index 0000000..8aa9f69
--- /dev/null
@@ -0,0 +1,15 @@
+public class StatementsAsBlocks
+{
+       static void ForEach (string[] args)
+       {
+               foreach (var v in args)
+                       ;
+               foreach (var v in args)
+                       ;
+       }
+       
+       public static int Main ()
+       {
+               return 0;
+       }
+}
\ No newline at end of file
diff --git a/mcs/tests/test-partial-32.cs b/mcs/tests/test-partial-32.cs
new file mode 100644 (file)
index 0000000..0fb0cd5
--- /dev/null
@@ -0,0 +1,36 @@
+namespace A
+{
+       using X;
+
+       partial class C
+       {
+               private class N : N1
+               {
+               }
+
+               public static void Main ()
+               {                       
+               }
+       }
+}
+
+namespace A
+{
+       using X;
+
+       partial class C : C1
+       {
+       }
+}
+
+
+namespace X
+{
+       public class C1
+       {
+               public class N1
+               {
+
+               }
+       }
+}
\ No newline at end of file
index 51201065dbcbfe7363db906cef98fd6dd2842997..07f3e4d04305766488219fd972349c2ee6fdfe35 100644 (file)
       </method>\r
     </type>\r
   </test>\r
+  <test name="gtest-optional-28.cs">\r
+    <type name="NoTypeOptionalParameters">\r
+      <method name="Void Lambda(Boolean, System.Func`2[System.String,System.Boolean][])" attrs="150">\r
+        <size>2</size>\r
+      </method>\r
+      <method name="Void MethodGroup(Boolean, System.Func`2[System.String,System.Boolean][])" attrs="150">\r
+        <size>2</size>\r
+      </method>\r
+      <method name="Boolean Foo(System.String)" attrs="145">\r
+        <size>10</size>\r
+      </method>\r
+      <method name="Boolean FooInstance(System.String)" attrs="129">\r
+        <size>10</size>\r
+      </method>\r
+      <method name="Int32 Main()" attrs="150">\r
+        <size>148</size>\r
+      </method>\r
+      <method name="Boolean &lt;Main&gt;m__0(System.String)" attrs="145">\r
+        <size>9</size>\r
+      </method>\r
+      <method name="Void .ctor()" attrs="6278">\r
+        <size>7</size>\r
+      </method>\r
+    </type>\r
+  </test>\r
   <test name="gtest-partial-01.cs">\r
     <type name="B`1[U]">\r
       <method name="Void .ctor()" attrs="6278">\r
       </method>\r
     </type>\r
   </test>\r
+  <test name="test-debug-28.cs">\r
+    <type name="StatementsAsBlocks">\r
+      <method name="Void ForEach(System.String[])" attrs="145">\r
+        <size>64</size>\r
+      </method>\r
+      <method name="Int32 Main()" attrs="150">\r
+        <size>10</size>\r
+      </method>\r
+      <method name="Void .ctor()" attrs="6278">\r
+        <size>7</size>\r
+      </method>\r
+    </type>\r
+  </test>\r
   <test name="test-externalias-01.cs">\r
     <type name="Test">\r
       <method name="Int32 Main()" attrs="150">\r
       </method>\r
     </type>\r
   </test>\r
+  <test name="test-partial-32.cs">\r
+    <type name="A.C">\r
+      <method name="Void Main()" attrs="150">\r
+        <size>2</size>\r
+      </method>\r
+      <method name="Void .ctor()" attrs="6278">\r
+        <size>7</size>\r
+      </method>\r
+    </type>\r
+    <type name="A.C+N">\r
+      <method name="Void .ctor()" attrs="6278">\r
+        <size>7</size>\r
+      </method>\r
+    </type>\r
+    <type name="X.C1">\r
+      <method name="Void .ctor()" attrs="6278">\r
+        <size>7</size>\r
+      </method>\r
+    </type>\r
+    <type name="X.C1+N1">\r
+      <method name="Void .ctor()" attrs="6278">\r
+        <size>7</size>\r
+      </method>\r
+    </type>\r
+  </test>\r
   <test name="test-var-01.cs">\r
     <type name="Test">\r
       <method name="Int32 Main()" attrs="150">\r
index 1c3175fbf4fc6af3276120b61c066af8f06cb7c1..08761871fd6c2ce4e517009daf8b127357828edf 100644 (file)
@@ -26,7 +26,6 @@
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
-using System.Collections;
 using System.IO;
 using System.Reflection;
 using System.Xml.XPath;
@@ -54,7 +53,7 @@ namespace Mono.Linker.Steps {
 
                static string GetAssemblyName (string descriptor)
                {
-                       int pos = descriptor.LastIndexOf (".");
+                       int pos = descriptor.LastIndexOf ('.');
                        if (pos == -1)
                                return descriptor;
 
index af3325a77af5c30cbc841ab080dcfdb9a54c8229..5dfa488d6251b22d5c556edcc0a2ea3bea074909 100644 (file)
@@ -61,6 +61,7 @@ namespace Mono.Linker.Steps {
                        CopyConfigFileIfNeeded (assembly, directory);
 
                        switch (Annotations.GetAction (assembly)) {
+                       case AssemblyAction.Save:
                        case AssemblyAction.Link:
                                assembly.Write (GetAssemblyFileName (assembly, directory), SaveSymbols (assembly));
                                break;
index 0f2518843ff243603907cdc3292cc63cb7819ff0..5cea341b09980ebd629fcbe1774bf8f6a2f74577 100644 (file)
@@ -100,6 +100,13 @@ namespace Mono.Linker.Steps {
                                        continue;
 
                                references.RemoveAt (i);
+                               // Removing the reference does not mean it will be saved back to disk!
+                               // That depends on the AssemblyAction set for the `assembly`
+                               if (Annotations.GetAction (assembly) == AssemblyAction.Copy) {
+                                       // Copy means even if "unlinked" we still want that assembly to be saved back 
+                                       // to disk (OutputStep) without the (removed) reference
+                                       Annotations.SetAction (assembly, AssemblyAction.Save);
+                               }
                                return;
                        }
                }
index 8eac19e5e4872f987dda8f53ed318f8eb34c49a8..14282b376be1b1091e0481d5286606deedd8f170 100644 (file)
 namespace Mono.Linker {
 
        public enum AssemblyAction {
+               // Ignore the assembly
                Skip,
+               // Copy the existing files, assembly and symbols, into the output destination. E.g. .dll and .mdb
+               // The linker still analyze the assemblies (to know what they require) but does not modify them
                Copy,
+               // Link the assembly
                Link,
+               // Remove the assembly from the output
                Delete,
+               // Save the assembly/symbols in memory without linking it. 
+               // E.g. useful to remove unneeded assembly references (as done in SweepStep), 
+               //  resolving [TypeForwardedTo] attributes (like PCL) to their final location
+               Save
        }
 }
index fe14e2cdd26fcb7ab185b717742cb1be4ed096b3..7755b2c6e863ab5463f0c3f86e9c78ad44f0869b 100644 (file)
@@ -351,7 +351,7 @@ add masterdoc support?
   <xs:element name="format">
     <xs:complexType>
       <xs:sequence>
-        <xs:any minOccurs="0" processContents="lax" />
+        <xs:any minOccurs="0" maxOccurs="unbounded" processContents="lax" />
       </xs:sequence>
       <xs:attribute ref="type" />
     </xs:complexType>
index 185bac96510019c80a80bfcc9ccd0964dfad3c5d..bdb04a94db239e4935bd20139ca2fc0392e443f6 100644 (file)
@@ -62,7 +62,7 @@ namespace Mono.Tuner {
                {
                        methodName = null;
 
-                       int pos = fullName.IndexOf (prefix);
+                       int pos = fullName.IndexOf (prefix, StringComparison.Ordinal);
                        if (pos == -1)
                                return false;
 
@@ -74,7 +74,7 @@ namespace Mono.Tuner {
                {
                        methodName = null;
 
-                       int pos = fullName.LastIndexOf (suffix);
+                       int pos = fullName.LastIndexOf (suffix, StringComparison.Ordinal);
                        if (pos == -1)
                                return false;
 
index 1d0c4c235733cdbb5329e14e102a60b6aa1cd847..58ba773a1107e959264f9ea21d2428184ed2b2dc 100644 (file)
@@ -565,6 +565,7 @@ Provides:       mono(Mono.Data.Tds) = 1.0.5000.0
 Provides:       mono(Novell.Directory.Ldap) = 1.0.5000.0
 Provides:       mono(System.Data) = 1.0.5000.0
 Provides:       mono(System.DirectoryServices) = 1.0.5000.0
+Provides:       mono(System.DirectoryServices.Protocols) = 1.0.5000.0
 Provides:       mono(System.EnterpriseServices) = 1.0.5000.0
 
 %description -n mono-data
@@ -587,6 +588,7 @@ Database connectivity for Mono.
 %_prefix/lib/mono/2.0/System.Data.Linq.dll
 %_prefix/lib/mono/2.0/System.Data.dll
 %_prefix/lib/mono/2.0/System.DirectoryServices.dll
+%_prefix/lib/mono/2.0/System.DirectoryServices.Protocols.dll
 %_prefix/lib/mono/2.0/System.EnterpriseServices.dll
 %_prefix/lib/mono/2.0/System.Runtime.Serialization.dll
 %_prefix/lib/mono/2.0/System.Transactions.dll
@@ -596,6 +598,7 @@ Database connectivity for Mono.
 %_prefix/lib/mono/4.0/System.Data.Linq.dll
 %_prefix/lib/mono/4.0/System.Data.dll
 %_prefix/lib/mono/4.0/System.DirectoryServices.dll
+%_prefix/lib/mono/4.0/System.DirectoryServices.Protocols.dll
 %_prefix/lib/mono/4.0/System.EnterpriseServices.dll
 %_prefix/lib/mono/4.0/System.Runtime.Serialization.dll
 %_prefix/lib/mono/4.0/System.Transactions.dll
@@ -606,6 +609,7 @@ Database connectivity for Mono.
 %_prefix/lib/mono/4.5/System.Data.Linq.dll
 %_prefix/lib/mono/4.5/System.Data.dll
 %_prefix/lib/mono/4.5/System.DirectoryServices.dll
+%_prefix/lib/mono/4.5/System.DirectoryServices.Protocols.dll
 %_prefix/lib/mono/4.5/System.EnterpriseServices.dll
 %_prefix/lib/mono/4.5/System.Runtime.Serialization.dll
 %_prefix/lib/mono/4.5/System.Transactions.dll
@@ -620,6 +624,7 @@ Database connectivity for Mono.
 %_prefix/lib/mono/gac/System.Data.DataSetExtensions
 %_prefix/lib/mono/gac/System.Data.Linq
 %_prefix/lib/mono/gac/System.DirectoryServices
+%_prefix/lib/mono/gac/System.DirectoryServices.Protocols
 %_prefix/lib/mono/gac/System.EnterpriseServices
 %_prefix/lib/mono/gac/System.Runtime.Serialization
 %_prefix/lib/mono/gac/System.Transactions
old mode 100644 (file)
new mode 100755 (executable)
index 93300c2..3d6cd25
@@ -17,6 +17,7 @@
 #include "mono/utils/mono-compiler.h"
 
 #include "declsec.h"
+#include "util.h"
 
 static char*
 declsec_20_get_classname (const char* p, const char **rptr)
@@ -113,12 +114,12 @@ declsec_20_write_value (GString *str, char type, const char *value)
                float val;
                int inf;
                readr4 (value, &val);
-               inf = isinf (val);
+               inf = dis_isinf (val);
                if (inf == -1) 
                        g_string_append_printf (str, "0xFF800000"); /* negative infinity */
                else if (inf == 1)
                        g_string_append_printf (str, "0x7F800000"); /* positive infinity */
-               else if (isnan (val))
+               else if (dis_isnan (val))
                        g_string_append_printf (str, "0xFFC00000"); /* NaN */
                else
                        g_string_append_printf (str, "%.8g", val);
@@ -128,7 +129,7 @@ declsec_20_write_value (GString *str, char type, const char *value)
                double val;
                int inf;
                readr8 (value, &val);
-               inf = isinf (val);
+               inf = dis_isinf (val);
                if (inf == -1) 
                        g_string_append_printf (str, "0xFFF00000000000000"); /* negative infinity */
                else if (inf == 1)
old mode 100644 (file)
new mode 100755 (executable)
index 52af86c..79f68fb
 #include "get.h"
 #include "dump.h"
 #include "dis-cil.h"
+#include "util.h"
 #include "mono/metadata/opcodes.h"
 #include "mono/metadata/class-internals.h"
 #include "mono/utils/mono-compiler.h"
 
-#ifndef HAVE_ISINF
-
-#ifdef HAVE_IEEEFP_H
-#include <ieeefp.h>
-int isinf (double);
-int
-isinf (double num)
-{
-       fpclass_t klass;
-
-       klass = fpclass (num);
-       if (klass == FP_NINF)
-               return -1;
-
-       if (klass == FP_PINF)
-               return 1;
-
-       return 0;
-}
-#else
-#error "Don't know how to implement isinf for this platform."
-#endif
-
-#endif
-
 #define CODE_INDENT g_assert (indent_level < 512); \
        indent[indent_level*2] = ' ';   \
        indent[indent_level*2+1] = ' '; \
@@ -191,12 +167,12 @@ disassemble_cil (MonoImage *m, MonoMethodHeader *mh, MonoGenericContainer *conta
                        double r;
                        int inf;
                        readr8 (ptr, &r);
-                       inf = isinf (r);
+                       inf = dis_isinf (r);
                        if (inf == -1) 
                                fprintf (output, "(00 00 00 00 00 00 f0 ff)"); /* negative infinity */
                        else if (inf == 1)
                                fprintf (output, "(00 00 00 00 00 00 f0 7f)"); /* positive infinity */
-                       else if (isnan (r))
+                       else if (dis_isnan (r))
                                fprintf (output, "(00 00 00 00 00 00 f8 ff)"); /* NaN */
                        else {
                                char *str = stringify_double (r);
@@ -300,12 +276,12 @@ disassemble_cil (MonoImage *m, MonoMethodHeader *mh, MonoGenericContainer *conta
                        
                        readr4 (ptr, &f);
 
-                       inf = isinf (f);
+                       inf = dis_isinf (f);
                        if (inf == -1) 
                                fprintf (output, "(00 00 80 ff)"); /* negative infinity */
                        else if (inf == 1)
                                fprintf (output, "(00 00 80 7f)"); /* positive infinity */
-                       else if (isnan (f))
+                       else if (dis_isnan (f))
                                fprintf (output, "(00 00 c0 ff)"); /* NaN */
                        else {
                                char *str = stringify_double ((double) f);
old mode 100644 (file)
new mode 100755 (executable)
index 72e528d..2b3a485
 #include "mono/metadata/class-internals.h"
 #include "mono/utils/mono-compiler.h"
 
-#ifndef HAVE_ISINF
-
-#ifdef HAVE_IEEEFP_H
-extern int isinf (double);
-#endif
-
-#endif
-
 #if defined(__native_client__) && defined(__GLIBC__)
 volatile int __nacl_thread_suspension_needed = 0;
 void __nacl_suspend_thread_if_needed() {}
@@ -870,12 +862,12 @@ handle_enum:
                        float val;
                        int inf;
                        readr4 (p, &val);
-                       inf = isinf (val);
+                       inf = dis_isinf (val);
                        if (inf == -1) 
                                g_string_append_printf (res, "(00 00 80 ff)"); /* negative infinity */
                        else if (inf == 1)
                                g_string_append_printf (res, "(00 00 80 7f)"); /* positive infinity */
-                       else if (isnan (val))
+                       else if (dis_isnan (val))
                                g_string_append_printf (res, "(00 00 c0 ff)"); /* NaN */
                        else
                                g_string_append_printf (res, "%g", val);
@@ -887,7 +879,7 @@ handle_enum:
                        int inf;
                        
                        readr8 (p, &val);
-                       inf = isinf (val);
+                       inf = dis_isinf (val);
                        if (inf == -1) 
                                g_string_append_printf (res, "(00 00 00 00 00 00 f0 ff)"); /* negative infinity */
                        else if (inf == 1)
old mode 100644 (file)
new mode 100755 (executable)
index 9c9ffaa..34f87b0
@@ -2310,7 +2310,7 @@ get_constant (MonoImage *m, MonoTypeEnum t, guint32 blob_index)
 #ifdef HAVE_ISFINITE
                normal = isfinite (r);
 #else
-               normal = isnormal (r);
+               normal = !dis_isinf (r) && !dis_isnan (r);
 #endif
                if (!normal) {
                        return g_strdup_printf ("float32(0x%08x)", read32 (ptr));
old mode 100644 (file)
new mode 100755 (executable)
index 737f6fd..116824d
 #include <glib.h>
 #include <string.h>
 #include <stdio.h>
+#include <math.h>
 #include "util.h"
 
+#ifdef HAVE_IEEEFP_H
+#include <ieeefp.h>
+#endif
+
 /**
  * map:
  * @code: code to lookup in table
@@ -122,3 +127,36 @@ data_dump (const char *data, int len, const char* prefix) {
        return g_string_free (str, FALSE);
 }
 
+int
+dis_isinf (double num)
+{
+#ifdef HAVE_ISINF
+       return isinf (num);
+#elif defined(HAVE_IEEEFP_H)
+       fpclass_t klass;
+
+       klass = fpclass (num);
+       if (klass == FP_NINF)
+               return -1;
+
+       if (klass == FP_PINF)
+               return 1;
+
+       return 0;
+#elif defined(HAVE__FINITE)
+       return _finite (num) ? 0 : 1;
+#else
+#error "Don't know how to implement isinf for this platform."
+#endif
+}
+
+int
+dis_isnan (double num)
+{
+#ifdef __MINGW32_VERSION
+return _isnan (num);
+#else
+return isnan (num);
+#endif
+}
+
old mode 100644 (file)
new mode 100755 (executable)
index cbb9a4f..d8ff7bf
@@ -8,3 +8,5 @@ const char *flags     (guint32 code, dis_map_t *table);
 void        hex_dump  (const char *buffer, int base, int count);
 char*       data_dump (const char *data, int len, const char* prefix);
 
+extern int dis_isinf (double num);
+extern int dis_isnan (double num);
old mode 100644 (file)
new mode 100755 (executable)
index 014c9a9..394799b
 #include <winsock2.h>
 #include <windows.h>
 #include <winbase.h>
+/*
+ * The mingw version says:
+ * /usr/i686-pc-mingw32/sys-root/mingw/include/ws2tcpip.h:38:2: error: #error "ws2tcpip.h is not compatible with winsock.h. Include winsock2.h instead."
+ */
+#ifdef _MSC_VER
 #include <ws2tcpip.h>
+#endif
 #include <psapi.h>
 #include <shlobj.h>
 #include <mswsock.h>
index a8a7db80ffd6a6b48ce453e11608be748949ee78..1b052dbaca7762a9091872067680eabe8634faa0 100644 (file)
@@ -23,7 +23,7 @@
 
 typedef struct {
        int id;
-       const char const *txt;
+       const char *txt;
 } ErrorDesc;
 
 static ErrorDesc common_messages [] = {
index 282d3e52d3bad084a161140ab2a78e9cb8b4bfdc..3b3884330f903df3a395e3275f7548dbdd9b98af 100644 (file)
@@ -26,190 +26,190 @@ typedef struct _MonoJitInfo MonoJitInfo;
 
 typedef void (*MonoDomainFunc) (MonoDomain *domain, void* user_data);
 
-MonoDomain*
+MONO_API MonoDomain*
 mono_init                  (const char *filename);
 
-MonoDomain *
+MONO_API MonoDomain *
 mono_init_from_assembly    (const char *domain_name, const char *filename);
 
-MonoDomain *
+MONO_API MonoDomain *
 mono_init_version          (const char *domain_name, const char *version);
 
-MonoDomain*
+MONO_API MonoDomain*
 mono_get_root_domain       (void);
 
-void
+MONO_API void
 mono_runtime_init          (MonoDomain *domain, MonoThreadStartCB start_cb,
                            MonoThreadAttachCB attach_cb);
 
-void
+MONO_API void
 mono_runtime_cleanup       (MonoDomain *domain);
 
-void
+MONO_API void
 mono_install_runtime_cleanup (MonoDomainFunc func);
 
-void
+MONO_API void
 mono_runtime_quit (void);
 
-void
+MONO_API void
 mono_runtime_set_shutting_down (void);
 
-mono_bool
+MONO_API mono_bool
 mono_runtime_is_shutting_down (void);
 
-const char*
+MONO_API const char*
 mono_check_corlib_version (void);
 
-MonoDomain *
+MONO_API MonoDomain *
 mono_domain_create         (void);
 
-MonoDomain *
+MONO_API MonoDomain *
 mono_domain_create_appdomain (char *friendly_name, char *configuration_file);
 
-MonoDomain *
+MONO_API MonoDomain *
 mono_domain_get            (void);
 
-MonoDomain *
+MONO_API MonoDomain *
 mono_domain_get_by_id      (int32_t domainid);
 
-int32_t
+MONO_API int32_t
 mono_domain_get_id         (MonoDomain *domain);
 
-mono_bool
+MONO_API mono_bool
 mono_domain_set            (MonoDomain *domain, mono_bool force);
 
-void
+MONO_API void
 mono_domain_set_internal   (MonoDomain *domain);
 
-void
+MONO_API void
 mono_domain_unload (MonoDomain *domain);
 
-void
+MONO_API void
 mono_domain_try_unload (MonoDomain *domain, MonoObject **exc);
 
-mono_bool
+MONO_API mono_bool
 mono_domain_is_unloading   (MonoDomain *domain);
 
-MonoDomain *
+MONO_API MonoDomain *
 mono_domain_from_appdomain (MonoAppDomain *appdomain);
 
-void
+MONO_API void
 mono_domain_foreach        (MonoDomainFunc func, void* user_data);
 
-MonoAssembly *
+MONO_API MonoAssembly *
 mono_domain_assembly_open  (MonoDomain *domain, const char *name);
 
-mono_bool
+MONO_API mono_bool
 mono_domain_finalize       (MonoDomain *domain, uint32_t timeout);
 
-void
+MONO_API void
 mono_domain_free           (MonoDomain *domain, mono_bool force);
 
-mono_bool
+MONO_API mono_bool
 mono_domain_has_type_resolve (MonoDomain *domain);
 
-MonoReflectionAssembly *
+MONO_API MonoReflectionAssembly *
 mono_domain_try_type_resolve (MonoDomain *domain, char *name, MonoObject *tb);
 
-mono_bool
+MONO_API mono_bool
 mono_domain_owns_vtable_slot (MonoDomain *domain, void* vtable_slot);
 
-void
+MONO_API void
 mono_context_init                                 (MonoDomain *domain);
 
-void 
+MONO_API void 
 mono_context_set                                  (MonoAppContext *new_context);
 
-MonoAppContext * 
+MONO_API MonoAppContext * 
 mono_context_get                                  (void);
 
-MonoJitInfo *
+MONO_API MonoJitInfo *
 mono_jit_info_table_find   (MonoDomain *domain, char *addr);
 
 /* MonoJitInfo accessors */
 
-void*
+MONO_API void*
 mono_jit_info_get_code_start (MonoJitInfo* ji);
 
-int
+MONO_API int
 mono_jit_info_get_code_size (MonoJitInfo* ji);
 
-MonoMethod*
+MONO_API MonoMethod*
 mono_jit_info_get_method (MonoJitInfo* ji);
 
 
-MonoImage*
+MONO_API MonoImage*
 mono_get_corlib            (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_object_class      (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_byte_class        (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_void_class        (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_boolean_class     (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_sbyte_class       (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_int16_class       (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_uint16_class      (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_int32_class       (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_uint32_class      (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_intptr_class         (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_uintptr_class        (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_int64_class       (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_uint64_class      (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_single_class      (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_double_class      (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_char_class        (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_string_class      (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_enum_class        (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_array_class       (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_thread_class       (void);
 
-MonoClass*
+MONO_API MonoClass*
 mono_get_exception_class    (void);
 
-void
+MONO_API void
 mono_security_enable_core_clr (void);
 
 typedef mono_bool (*MonoCoreClrPlatformCB) (const char *image_name);
 
-void
+MONO_API void
 mono_security_set_core_clr_platform_callback (MonoCoreClrPlatformCB callback);
 
 MONO_END_DECLS
index 607dde5037b1c2a01d5007d50316c9cb17759310..c93fc82c1c280c945c0e6b7276fd2710679db5ba 100644 (file)
@@ -107,6 +107,8 @@ static const AssemblyVersionMap framework_assemblies [] = {
        {"System.Data", 0},
        {"System.Data.Linq", 2},
        {"System.Data.OracleClient", 0},
+       {"System.Data.Services", 2},
+       {"System.Data.Services.Client", 2},
        {"System.Data.SqlXml", 0},
        {"System.Design", 0},
        {"System.DirectoryServices", 0},
@@ -115,19 +117,25 @@ static const AssemblyVersionMap framework_assemblies [] = {
        {"System.EnterpriseServices", 0},
        {"System.Management", 0},
        {"System.Messaging", 0},
+       {"System.Net", 2},
        {"System.Runtime.Remoting", 0},
        {"System.Runtime.Serialization", 3},
        {"System.Runtime.Serialization.Formatters.Soap", 0},
        {"System.Security", 0},
+       {"System.ServiceModel.Web", 2},
        {"System.ServiceProcess", 0},
        {"System.Transactions", 0},
        {"System.Web", 0},
        {"System.Web.Abstractions", 2},
+       {"System.Web.DynamicData", 2},
+       {"System.Web.Extensions", 2},
        {"System.Web.Mobile", 0},
        {"System.Web.Routing", 2},
        {"System.Web.Services", 0},
        {"System.Windows.Forms", 0},
        {"System.Xml", 0},
+       {"System.Xml.Linq", 2},
+       {"WindowsBase", 3},
        {"mscorlib", 0}
 };
 #endif
index be01cf975153a9d046a418f212505be3fa415d7b..50488658fa246c55abeefa31507ad5da390e64fc 100644 (file)
@@ -5,67 +5,67 @@
 
 MONO_BEGIN_DECLS
 
-void          mono_assemblies_init     (void);
-void          mono_assemblies_cleanup  (void);
-MonoAssembly *mono_assembly_open       (const char *filename,
+MONO_API void          mono_assemblies_init     (void);
+MONO_API void          mono_assemblies_cleanup  (void);
+MONO_API MonoAssembly *mono_assembly_open       (const char *filename,
                                        MonoImageOpenStatus *status);
-MonoAssembly *mono_assembly_open_full (const char *filename,
+MONO_API MonoAssembly *mono_assembly_open_full (const char *filename,
                                        MonoImageOpenStatus *status,
                                        mono_bool refonly);
-MonoAssembly* mono_assembly_load       (MonoAssemblyName *aname, 
+MONO_API MonoAssembly* mono_assembly_load       (MonoAssemblyName *aname, 
                                                const char       *basedir, 
                                        MonoImageOpenStatus *status);
-MonoAssembly* mono_assembly_load_full (MonoAssemblyName *aname, 
+MONO_API MonoAssembly* mono_assembly_load_full (MonoAssemblyName *aname, 
                                                const char       *basedir, 
                                        MonoImageOpenStatus *status,
                                        mono_bool refonly);
-MonoAssembly* mono_assembly_load_from  (MonoImage *image, const char *fname,
+MONO_API MonoAssembly* mono_assembly_load_from  (MonoImage *image, const char *fname,
                                        MonoImageOpenStatus *status);
-MonoAssembly* mono_assembly_load_from_full  (MonoImage *image, const char *fname,
+MONO_API MonoAssembly* mono_assembly_load_from_full  (MonoImage *image, const char *fname,
                                        MonoImageOpenStatus *status,
                                        mono_bool refonly);
 
-MonoAssembly* mono_assembly_load_with_partial_name (const char *name, MonoImageOpenStatus *status);
-
-MonoAssembly* mono_assembly_loaded     (MonoAssemblyName *aname);
-MonoAssembly* mono_assembly_loaded_full (MonoAssemblyName *aname, mono_bool refonly);
-void          mono_assembly_get_assemblyref (MonoImage *image, int index, MonoAssemblyName *aname);
-void          mono_assembly_load_reference (MonoImage *image, int index);
-void          mono_assembly_load_references (MonoImage *image, MonoImageOpenStatus *status);
-MonoImage*    mono_assembly_load_module (MonoAssembly *assembly, uint32_t idx);
-void          mono_assembly_close      (MonoAssembly *assembly);
-void          mono_assembly_setrootdir (const char *root_dir);
-MONO_CONST_RETURN char *mono_assembly_getrootdir (void);
-void         mono_assembly_foreach    (MonoFunc func, void* user_data);
-void          mono_assembly_set_main   (MonoAssembly *assembly);
-MonoAssembly *mono_assembly_get_main   (void);
-MonoImage    *mono_assembly_get_image  (MonoAssembly *assembly);
-mono_bool      mono_assembly_fill_assembly_name (MonoImage *image, MonoAssemblyName *aname);
-mono_bool      mono_assembly_names_equal (MonoAssemblyName *l, MonoAssemblyName *r);
-char*         mono_stringify_assembly_name (MonoAssemblyName *aname);
+MONO_API MonoAssembly* mono_assembly_load_with_partial_name (const char *name, MonoImageOpenStatus *status);
+
+MONO_API MonoAssembly* mono_assembly_loaded     (MonoAssemblyName *aname);
+MONO_API MonoAssembly* mono_assembly_loaded_full (MonoAssemblyName *aname, mono_bool refonly);
+MONO_API void          mono_assembly_get_assemblyref (MonoImage *image, int index, MonoAssemblyName *aname);
+MONO_API void          mono_assembly_load_reference (MonoImage *image, int index);
+MONO_API void          mono_assembly_load_references (MonoImage *image, MonoImageOpenStatus *status);
+MONO_API MonoImage*    mono_assembly_load_module (MonoAssembly *assembly, uint32_t idx);
+MONO_API void          mono_assembly_close      (MonoAssembly *assembly);
+MONO_API void          mono_assembly_setrootdir (const char *root_dir);
+MONO_API MONO_CONST_RETURN char *mono_assembly_getrootdir (void);
+MONO_API void        mono_assembly_foreach    (MonoFunc func, void* user_data);
+MONO_API void          mono_assembly_set_main   (MonoAssembly *assembly);
+MONO_API MonoAssembly *mono_assembly_get_main   (void);
+MONO_API MonoImage    *mono_assembly_get_image  (MonoAssembly *assembly);
+MONO_API mono_bool      mono_assembly_fill_assembly_name (MonoImage *image, MonoAssemblyName *aname);
+MONO_API mono_bool      mono_assembly_names_equal (MonoAssemblyName *l, MonoAssemblyName *r);
+MONO_API char*         mono_stringify_assembly_name (MonoAssemblyName *aname);
 
 /* Installs a function which is called each time a new assembly is loaded. */
 typedef void  (*MonoAssemblyLoadFunc)         (MonoAssembly *assembly, void* user_data);
-void          mono_install_assembly_load_hook (MonoAssemblyLoadFunc func, void* user_data);
+MONO_API void          mono_install_assembly_load_hook (MonoAssemblyLoadFunc func, void* user_data);
 
 /* 
  * Installs a new function which is used to search the list of loaded 
  * assemblies for a given assembly name.
  */
 typedef MonoAssembly *(*MonoAssemblySearchFunc)         (MonoAssemblyName *aname, void* user_data);
-void          mono_install_assembly_search_hook (MonoAssemblySearchFunc func, void* user_data);
-void         mono_install_assembly_refonly_search_hook (MonoAssemblySearchFunc func, void* user_data);
+MONO_API void          mono_install_assembly_search_hook (MonoAssemblySearchFunc func, void* user_data);
+MONO_API void        mono_install_assembly_refonly_search_hook (MonoAssemblySearchFunc func, void* user_data);
 
-MonoAssembly* mono_assembly_invoke_search_hook (MonoAssemblyName *aname);
+MONO_API MonoAssembly* mono_assembly_invoke_search_hook (MonoAssemblyName *aname);
 
 /*
  * Installs a new search function which is used as a last resort when loading 
  * an assembly fails. This could invoke AssemblyResolve events.
  */
-void          
+MONO_API void          
 mono_install_assembly_postload_search_hook (MonoAssemblySearchFunc func, void* user_data);
 
-void          
+MONO_API void          
 mono_install_assembly_postload_refonly_search_hook (MonoAssemblySearchFunc func, void* user_data);
 
 
@@ -76,20 +76,20 @@ typedef MonoAssembly * (*MonoAssemblyPreLoadFunc) (MonoAssemblyName *aname,
                                                   char **assemblies_path,
                                                   void* user_data);
 
-void          mono_install_assembly_preload_hook (MonoAssemblyPreLoadFunc func,
+MONO_API void          mono_install_assembly_preload_hook (MonoAssemblyPreLoadFunc func,
                                                  void* user_data);
-void          mono_install_assembly_refonly_preload_hook (MonoAssemblyPreLoadFunc func,
+MONO_API void          mono_install_assembly_refonly_preload_hook (MonoAssemblyPreLoadFunc func,
                                                  void* user_data);
 
-void          mono_assembly_invoke_load_hook (MonoAssembly *ass);
+MONO_API void          mono_assembly_invoke_load_hook (MonoAssembly *ass);
 
-MonoAssemblyName* mono_assembly_name_new             (const char *name);
-const char*       mono_assembly_name_get_name        (MonoAssemblyName *aname);
-const char*       mono_assembly_name_get_culture     (MonoAssemblyName *aname);
-uint16_t          mono_assembly_name_get_version     (MonoAssemblyName *aname,
+MONO_API MonoAssemblyName* mono_assembly_name_new             (const char *name);
+MONO_API const char*       mono_assembly_name_get_name        (MonoAssemblyName *aname);
+MONO_API const char*       mono_assembly_name_get_culture     (MonoAssemblyName *aname);
+MONO_API uint16_t          mono_assembly_name_get_version     (MonoAssemblyName *aname,
                                                      uint16_t *minor, uint16_t *build, uint16_t *revision);
-mono_byte*        mono_assembly_name_get_pubkeytoken (MonoAssemblyName *aname);
-void              mono_assembly_name_free            (MonoAssemblyName *aname);
+MONO_API mono_byte*        mono_assembly_name_get_pubkeytoken (MonoAssemblyName *aname);
+MONO_API void              mono_assembly_name_free            (MonoAssemblyName *aname);
 
 typedef struct {
        const char *name;
@@ -97,14 +97,14 @@ typedef struct {
        const unsigned int size;
 } MonoBundledAssembly;
 
-void          mono_register_bundled_assemblies (const MonoBundledAssembly **assemblies);
-void          mono_register_config_for_assembly (const char* assembly_name, const char* config_xml);
-void          mono_register_symfile_for_assembly (const char* assembly_name, const mono_byte *raw_contents, int size);
-void         mono_register_machine_config (const char *config_xml);
+MONO_API void          mono_register_bundled_assemblies (const MonoBundledAssembly **assemblies);
+MONO_API void          mono_register_config_for_assembly (const char* assembly_name, const char* config_xml);
+MONO_API void          mono_register_symfile_for_assembly (const char* assembly_name, const mono_byte *raw_contents, int size);
+MONO_API void        mono_register_machine_config (const char *config_xml);
 
-void          mono_set_rootdir (void);
-void          mono_set_dirs (const char *assembly_dir, const char *config_dir);
-void          mono_set_assemblies_path (const char* path);
+MONO_API void          mono_set_rootdir (void);
+MONO_API void          mono_set_dirs (const char *assembly_dir, const char *config_dir);
+MONO_API void          mono_set_assemblies_path (const char* path);
 MONO_END_DECLS
 
 #endif
index 91ede875aad5d2380ae75c6a422ec7937b8b09eb..8d6fdcf4d89bf34958fbd2d28f057c446e16526d 100644 (file)
@@ -320,6 +320,6 @@ typedef struct {
        MonoCLIHeader     cli_cli_header;
 } MonoCLIImageInfo;
 
-guint32       mono_cli_rva_image_map (MonoImage *image, guint32 rva);
+MONO_API guint32       mono_cli_rva_image_map (MonoImage *image, guint32 rva);
 
 #endif /* __MONO_CIL_COFF_H__ */
index 2fa919ace45a39e93e76fd53e254056a6adf30a5..942b1f4d1029b4435a0470244fb8e7b3782d15a6 100644 (file)
@@ -439,7 +439,7 @@ int mono_class_interface_match (const uint8_t *bitmap, int id) MONO_INTERNAL;
 #endif
 
 
-int mono_class_interface_offset (MonoClass *klass, MonoClass *itf);
+MONO_API int mono_class_interface_offset (MonoClass *klass, MonoClass *itf);
 int mono_class_interface_offset_with_variance (MonoClass *klass, MonoClass *itf, gboolean *non_exact_match) MONO_INTERNAL;
 
 typedef gpointer MonoRuntimeGenericContext;
@@ -835,7 +835,7 @@ typedef struct {
 
 extern MonoPerfCounters *mono_perfcounters MONO_INTERNAL;
 
-void mono_perfcounters_init (void);
+MONO_API void mono_perfcounters_init (void);
 
 /*
  * The definition of the first field in SafeHandle,
@@ -1001,7 +1001,7 @@ MonoGenericContext*
 mono_method_get_context (MonoMethod *method) MONO_INTERNAL;
 
 /* Used by monodis, thus cannot be MONO_INTERNAL */
-MonoGenericContainer*
+MONO_API MonoGenericContainer*
 mono_method_get_generic_container (MonoMethod *method);
 
 MonoGenericContext*
@@ -1022,7 +1022,7 @@ mono_class_inflate_generic_method_full_checked (MonoMethod *method, MonoClass *k
 MonoMethodInflated*
 mono_method_inflated_lookup (MonoMethodInflated* method, gboolean cache) MONO_INTERNAL;
 
-MonoMethodSignature *
+MONO_API MonoMethodSignature *
 mono_metadata_get_inflated_signature (MonoMethodSignature *sig, MonoGenericContext *context);
 
 MonoType*
@@ -1034,7 +1034,7 @@ mono_class_inflate_generic_class (MonoClass *gklass, MonoGenericContext *context
 MonoType*
 mono_class_inflate_generic_type_checked (MonoType *type, MonoGenericContext *context, MonoError *error) MONO_INTERNAL;
 
-void
+MONO_API void
 mono_metadata_free_inflated_signature (MonoMethodSignature *sig);
 
 MonoMethodSignature*
@@ -1218,11 +1218,11 @@ mono_method_get_wrapper_data (MonoMethod *method, guint32 id) MONO_INTERNAL;
 gboolean
 mono_metadata_has_generic_params (MonoImage *image, guint32 token) MONO_INTERNAL;
 
-MonoGenericContainer *
+MONO_API MonoGenericContainer *
 mono_metadata_load_generic_params (MonoImage *image, guint32 token,
                                   MonoGenericContainer *parent_container);
 
-void
+MONO_API void
 mono_metadata_load_generic_param_constraints (MonoImage *image, guint32 token,
                                              MonoGenericContainer *container);
 
@@ -1272,23 +1272,23 @@ mono_type_get_full_name (MonoClass *class) MONO_INTERNAL;
 MonoArrayType *mono_dup_array_type (MonoImage *image, MonoArrayType *a) MONO_INTERNAL;
 MonoMethodSignature *mono_metadata_signature_deep_dup (MonoImage *image, MonoMethodSignature *sig) MONO_INTERNAL;
 
-void
+MONO_API void
 mono_image_init_name_cache (MonoImage *image);
 
 gboolean mono_class_is_nullable (MonoClass *klass) MONO_INTERNAL;
 MonoClass *mono_class_get_nullable_param (MonoClass *klass) MONO_INTERNAL;
 
 /* object debugging functions, for use inside gdb */
-void mono_object_describe        (MonoObject *obj);
-void mono_object_describe_fields (MonoObject *obj);
-void mono_value_describe_fields  (MonoClass* klass, const char* addr);
-void mono_class_describe_statics (MonoClass* klass);
+MONO_API void mono_object_describe        (MonoObject *obj);
+MONO_API void mono_object_describe_fields (MonoObject *obj);
+MONO_API void mono_value_describe_fields  (MonoClass* klass, const char* addr);
+MONO_API void mono_class_describe_statics (MonoClass* klass);
 
 /*Enum validation related functions*/
-gboolean
+MONO_API gboolean
 mono_type_is_valid_enum_basetype (MonoType * type);
 
-gboolean
+MONO_API gboolean
 mono_class_is_valid_enum (MonoClass *klass);
 
 MonoType *
index 1142dca5bdf308c2c70d46f0632167d8fb429a67..27710839cd27a150b78305383def3a919c550091 100644 (file)
@@ -13,249 +13,249 @@ typedef struct _MonoClassField MonoClassField;
 typedef struct _MonoProperty MonoProperty;
 typedef struct _MonoEvent MonoEvent;
 
-MonoClass *
+MONO_API MonoClass *
 mono_class_get             (MonoImage *image, uint32_t type_token);
 
-MonoClass *
+MONO_API MonoClass *
 mono_class_get_full        (MonoImage *image, uint32_t type_token, MonoGenericContext *context);
 
-mono_bool
+MONO_API mono_bool
 mono_class_init            (MonoClass *klass);
 
-MonoVTable *
+MONO_API MonoVTable *
 mono_class_vtable          (MonoDomain *domain, MonoClass *klass);
 
-MonoClass *
+MONO_API MonoClass *
 mono_class_from_name       (MonoImage *image, const char* name_space, const char *name);
 
-MonoClass *
+MONO_API MonoClass *
 mono_class_from_name_case  (MonoImage *image, const char* name_space, const char *name);
 
-MonoMethod *
+MONO_API MonoMethod *
 mono_class_get_method_from_name_flags (MonoClass *klass, const char *name, int param_count, int flags);
 
-MonoClass * 
+MONO_API MonoClass * 
 mono_class_from_typeref    (MonoImage *image, uint32_t type_token);
 
-MonoClass *
+MONO_API MonoClass *
 mono_class_from_generic_parameter (MonoGenericParam *param, MonoImage *image, mono_bool is_mvar);
 
-MonoType*
+MONO_API MonoType*
 mono_class_inflate_generic_type (MonoType *type, MonoGenericContext *context) /* MONO_DEPRECATED */;
 
-MonoMethod*
+MONO_API MonoMethod*
 mono_class_inflate_generic_method (MonoMethod *method, MonoGenericContext *context);
 
-MonoMethod *
+MONO_API MonoMethod *
 mono_get_inflated_method (MonoMethod *method);
 
-MonoClassField*
+MONO_API MonoClassField*
 mono_field_from_token      (MonoImage *image, uint32_t token, MonoClass **retklass, MonoGenericContext *context);
 
-MonoClass *
+MONO_API MonoClass *
 mono_bounded_array_class_get (MonoClass *element_class, uint32_t rank, mono_bool bounded);
 
-MonoClass *
+MONO_API MonoClass *
 mono_array_class_get       (MonoClass *element_class, uint32_t rank);
 
-MonoClass *
+MONO_API MonoClass *
 mono_ptr_class_get         (MonoType *type);
 
-MonoClassField *
+MONO_API MonoClassField *
 mono_class_get_field       (MonoClass *klass, uint32_t field_token);
 
-MonoClassField *
+MONO_API MonoClassField *
 mono_class_get_field_from_name (MonoClass *klass, const char *name);
 
-uint32_t
+MONO_API uint32_t
 mono_class_get_field_token (MonoClassField *field);
 
-uint32_t
+MONO_API uint32_t
 mono_class_get_event_token (MonoEvent *event);
 
-MonoProperty*
+MONO_API MonoProperty*
 mono_class_get_property_from_name (MonoClass *klass, const char *name);
 
-uint32_t
+MONO_API uint32_t
 mono_class_get_property_token (MonoProperty *prop);
 
-int32_t
+MONO_API int32_t
 mono_array_element_size    (MonoClass *ac);
 
-int32_t
+MONO_API int32_t
 mono_class_instance_size   (MonoClass *klass);
 
-int32_t
+MONO_API int32_t
 mono_class_array_element_size (MonoClass *klass);
 
-int32_t
+MONO_API int32_t
 mono_class_data_size       (MonoClass *klass);
 
-int32_t
+MONO_API int32_t
 mono_class_value_size      (MonoClass *klass, uint32_t *align);
 
-int32_t
+MONO_API int32_t
 mono_class_min_align       (MonoClass *klass);
 
-MonoClass *
+MONO_API MonoClass *
 mono_class_from_mono_type  (MonoType *type);
 
-mono_bool
+MONO_API mono_bool
 mono_class_is_subclass_of (MonoClass *klass, MonoClass *klassc, 
                                                   mono_bool check_interfaces);
 
-mono_bool
+MONO_API mono_bool
 mono_class_is_assignable_from (MonoClass *klass, MonoClass *oklass);
 
-void*
+MONO_API void*
 mono_ldtoken               (MonoImage *image, uint32_t token, MonoClass **retclass, MonoGenericContext *context);
 
-char*         
+MONO_API char*         
 mono_type_get_name         (MonoType *type);
 
-MonoType*
+MONO_API MonoType*
 mono_type_get_underlying_type (MonoType *type);
 
 /* MonoClass accessors */
-MonoImage*
+MONO_API MonoImage*
 mono_class_get_image         (MonoClass *klass);
 
-MonoClass*
+MONO_API MonoClass*
 mono_class_get_element_class (MonoClass *klass);
 
-mono_bool
+MONO_API mono_bool
 mono_class_is_valuetype      (MonoClass *klass);
 
-mono_bool
+MONO_API mono_bool
 mono_class_is_enum          (MonoClass *klass);
 
-MonoType*
+MONO_API MonoType*
 mono_class_enum_basetype    (MonoClass *klass);
 
-MonoClass*
+MONO_API MonoClass*
 mono_class_get_parent        (MonoClass *klass);
 
-MonoClass*
+MONO_API MonoClass*
 mono_class_get_nesting_type  (MonoClass *klass);
 
-int
+MONO_API int
 mono_class_get_rank          (MonoClass *klass);
 
-uint32_t
+MONO_API uint32_t
 mono_class_get_flags         (MonoClass *klass);
 
-const char*
+MONO_API const char*
 mono_class_get_name          (MonoClass *klass);
 
-const char*
+MONO_API const char*
 mono_class_get_namespace     (MonoClass *klass);
 
-MonoType*
+MONO_API MonoType*
 mono_class_get_type          (MonoClass *klass);
 
-uint32_t
+MONO_API uint32_t
 mono_class_get_type_token    (MonoClass *klass);
 
-MonoType*
+MONO_API MonoType*
 mono_class_get_byref_type    (MonoClass *klass);
 
-int
+MONO_API int
 mono_class_num_fields        (MonoClass *klass);
 
-int
+MONO_API int
 mono_class_num_methods       (MonoClass *klass);
 
-int
+MONO_API int
 mono_class_num_properties    (MonoClass *klass);
 
-int
+MONO_API int
 mono_class_num_events        (MonoClass *klass);
 
-MonoClassField*
+MONO_API MonoClassField*
 mono_class_get_fields        (MonoClass* klass, void **iter);
 
-MonoMethod*
+MONO_API MonoMethod*
 mono_class_get_methods       (MonoClass* klass, void **iter);
 
-MonoProperty*
+MONO_API MonoProperty*
 mono_class_get_properties    (MonoClass* klass, void **iter);
 
-MonoEvent*
+MONO_API MonoEvent*
 mono_class_get_events        (MonoClass* klass, void **iter);
 
-MonoClass*
+MONO_API MonoClass*
 mono_class_get_interfaces    (MonoClass* klass, void **iter);
 
-MonoClass*
+MONO_API MonoClass*
 mono_class_get_nested_types  (MonoClass* klass, void **iter);
 
 /* MonoClassField accessors */
-const char*
+MONO_API const char*
 mono_field_get_name   (MonoClassField *field);
 
-MonoType*
+MONO_API MonoType*
 mono_field_get_type   (MonoClassField *field);
 
-MonoClass*
+MONO_API MonoClass*
 mono_field_get_parent (MonoClassField *field);
 
-uint32_t
+MONO_API uint32_t
 mono_field_get_flags  (MonoClassField *field);
 
-uint32_t
+MONO_API uint32_t
 mono_field_get_offset  (MonoClassField *field);
 
-const char *
+MONO_API const char *
 mono_field_get_data  (MonoClassField *field);
 
 /* MonoProperty acessors */
-const char*
+MONO_API const char*
 mono_property_get_name       (MonoProperty *prop);
 
-MonoMethod*
+MONO_API MonoMethod*
 mono_property_get_set_method (MonoProperty *prop);
 
-MonoMethod*
+MONO_API MonoMethod*
 mono_property_get_get_method (MonoProperty *prop);
 
-MonoClass*
+MONO_API MonoClass*
 mono_property_get_parent     (MonoProperty *prop);
 
-uint32_t
+MONO_API uint32_t
 mono_property_get_flags      (MonoProperty *prop);
 
 /* MonoEvent accessors */
-const char*
+MONO_API const char*
 mono_event_get_name          (MonoEvent *event);
 
-MonoMethod*
+MONO_API MonoMethod*
 mono_event_get_add_method    (MonoEvent *event);
 
-MonoMethod*
+MONO_API MonoMethod*
 mono_event_get_remove_method (MonoEvent *event);
 
-MonoMethod*
+MONO_API MonoMethod*
 mono_event_get_remove_method (MonoEvent *event);
 
-MonoMethod*
+MONO_API MonoMethod*
 mono_event_get_raise_method  (MonoEvent *event);
 
-MonoClass*
+MONO_API MonoClass*
 mono_event_get_parent        (MonoEvent *event);
 
-uint32_t
+MONO_API uint32_t
 mono_event_get_flags         (MonoEvent *event);
 
-MonoMethod *
+MONO_API MonoMethod *
 mono_class_get_method_from_name (MonoClass *klass, const char *name, int param_count);
 
-char *
+MONO_API char *
 mono_class_name_from_token (MonoImage *image, uint32_t type_token);
 
-mono_bool
+MONO_API mono_bool
 mono_method_can_access_field (MonoMethod *method, MonoClassField *field);
 
-mono_bool
+MONO_API mono_bool
 mono_method_can_access_method (MonoMethod *method, MonoMethod *called);
 
 MONO_END_DECLS
index d3da2d93f4675af84daaa1843246e117fe898994..f65aae2fb03e101f137b26d3ed4a4a0d6d41678b 100644 (file)
@@ -47,10 +47,10 @@ mono_cominterop_emit_marshal_safearray (EmitMarshalContext *m, int argnum,
                                                                                int conv_arg, MonoType **conv_arg_type,
                                                                                MarshalAction action) MONO_INTERNAL;
 
-MonoString * 
+MONO_API MonoString * 
 mono_string_from_bstr (gpointer bstr);
 
-void 
+MONO_API void 
 mono_free_bstr (gpointer bstr);
 
 #endif /* __MONO_COMINTEROP_H__ */
index 7e0d598a2820635795a691bd69ca99f0869e5264..15efa5a30507b51b903a5a20d60c16cbb1aea864 100644 (file)
@@ -44,9 +44,10 @@ mono_console_handle_async_ops (void)
 MonoBoolean
 ves_icall_System_ConsoleDriver_Isatty (HANDLE handle)
 {
+       DWORD mode;
+
        MONO_ARCH_SAVE_REGS;
 
-       DWORD mode;
        return GetConsoleMode (handle, &mode) != 0;
 }
 
index 8743dced04a955f59866fbd3b0065111a168e46c..09092f9e380b3c69807c4a0c83d15a12d4c556dc 100644 (file)
@@ -19,28 +19,28 @@ struct MonoDisHelper {
        void* user_data;
 };
 
-char* mono_disasm_code_one (MonoDisHelper *dh, MonoMethod *method, const mono_byte *ip, const mono_byte** endp);
-char* mono_disasm_code     (MonoDisHelper *dh, MonoMethod *method, const mono_byte *ip, const mono_byte* end);
+MONO_API char* mono_disasm_code_one (MonoDisHelper *dh, MonoMethod *method, const mono_byte *ip, const mono_byte** endp);
+MONO_API char* mono_disasm_code     (MonoDisHelper *dh, MonoMethod *method, const mono_byte *ip, const mono_byte* end);
 
 typedef struct MonoMethodDesc MonoMethodDesc;
 
-char*           mono_type_full_name (MonoType *type);
+MONO_API char*           mono_type_full_name (MonoType *type);
 
-char*           mono_signature_get_desc (MonoMethodSignature *sig, mono_bool include_namespace);
+MONO_API char*           mono_signature_get_desc (MonoMethodSignature *sig, mono_bool include_namespace);
 
-char*           mono_context_get_desc (MonoGenericContext *context);
+MONO_API char*           mono_context_get_desc (MonoGenericContext *context);
 
-MonoMethodDesc* mono_method_desc_new (const char *name, mono_bool include_namespace);
-MonoMethodDesc* mono_method_desc_from_method (MonoMethod *method);
-void            mono_method_desc_free (MonoMethodDesc *desc);
-mono_bool       mono_method_desc_match (MonoMethodDesc *desc, MonoMethod *method);
-mono_bool       mono_method_desc_full_match (MonoMethodDesc *desc, MonoMethod *method);
-MonoMethod*     mono_method_desc_search_in_class (MonoMethodDesc *desc, MonoClass *klass);
-MonoMethod*     mono_method_desc_search_in_image (MonoMethodDesc *desc, MonoImage *image);
+MONO_API MonoMethodDesc* mono_method_desc_new (const char *name, mono_bool include_namespace);
+MONO_API MonoMethodDesc* mono_method_desc_from_method (MonoMethod *method);
+MONO_API void            mono_method_desc_free (MonoMethodDesc *desc);
+MONO_API mono_bool       mono_method_desc_match (MonoMethodDesc *desc, MonoMethod *method);
+MONO_API mono_bool       mono_method_desc_full_match (MonoMethodDesc *desc, MonoMethod *method);
+MONO_API MonoMethod*     mono_method_desc_search_in_class (MonoMethodDesc *desc, MonoClass *klass);
+MONO_API MonoMethod*     mono_method_desc_search_in_image (MonoMethodDesc *desc, MonoImage *image);
 
-char*           mono_method_full_name (MonoMethod *method, mono_bool signature);
+MONO_API char*           mono_method_full_name (MonoMethod *method, mono_bool signature);
 
-char*           mono_field_full_name (MonoClassField *field);
+MONO_API char*           mono_field_full_name (MonoClassField *field);
 
 MONO_END_DECLS
 
index 36805ea3b6ff938193df8d4936332e7f266587e8..6ea3bccfc6edff1c6a01caaec81ee281751550f0 100644 (file)
@@ -122,43 +122,43 @@ typedef struct {
 
 MONO_BEGIN_DECLS
 
-MonoSymbolFile *
+MONO_API MonoSymbolFile *
 mono_debug_open_mono_symbols       (MonoDebugHandle          *handle,
                                    const uint8_t            *raw_contents,
                                    int                       size,
                                    mono_bool                 in_the_debugger);
 
-void
+MONO_API void
 mono_debug_close_mono_symbol_file  (MonoSymbolFile           *symfile);
 
-mono_bool
+MONO_API mono_bool
 mono_debug_symfile_is_loaded       (MonoSymbolFile           *symfile);
 
-MonoDebugSourceLocation *
+MONO_API MonoDebugSourceLocation *
 mono_debug_symfile_lookup_location (MonoDebugMethodInfo      *minfo,
                                    uint32_t                  offset);
 
-void
+MONO_API void
 mono_debug_symfile_free_location   (MonoDebugSourceLocation  *location);
 
 int32_t
 _mono_debug_address_from_il_offset (MonoDebugMethodJitInfo   *jit,
                                    uint32_t                  il_offset);
 
-MonoDebugMethodInfo *
+MONO_API MonoDebugMethodInfo *
 mono_debug_symfile_lookup_method   (MonoDebugHandle          *handle,
                                    MonoMethod               *method);
 
-MonoDebugLocalsInfo*
+MONO_API MonoDebugLocalsInfo*
 mono_debug_symfile_lookup_locals (MonoDebugMethodInfo *minfo);
 
-void
+MONO_API void
 mono_debug_symfile_free_locals (MonoDebugLocalsInfo *info);
 
-void
+MONO_API void
 mono_debug_symfile_get_line_numbers (MonoDebugMethodInfo *minfo, char **source_file, int *n_il_offsets, int **il_offsets, int **line_numbers);
 
-void
+MONO_API void
 mono_debug_symfile_get_line_numbers_full (MonoDebugMethodInfo *minfo, char **source_file, GPtrArray **source_file_list, int *n_il_offsets, int **il_offsets, int **line_numbers, int **column_numbers, int **source_files);
 
 MONO_END_DECLS
index f337d0770a958826b26f9bc8e89c253685d87a5d..79370cbe5f20d30d340990077cd494c91ba87fd3 100644 (file)
@@ -608,7 +608,7 @@ MonoImage *mono_assembly_open_from_bundle (const char *filename,
                                           MonoImageOpenStatus *status,
                                           gboolean refonly) MONO_INTERNAL;
 
-void
+MONO_API void
 mono_domain_add_class_static_data (MonoDomain *domain, MonoClass *klass, gpointer data, guint32 *bitmap);
 
 MonoReflectionAssembly *
index 619249a4715592e877bf72947066e7c394c3e82c..360ba3baa8ad9454daf22d513a3a4d1fb39928cc 100644 (file)
@@ -14,8 +14,8 @@
 
 MONO_BEGIN_DECLS
 
-extern int32_t mono_environment_exitcode_get (void);
-extern void mono_environment_exitcode_set (int32_t value);
+MONO_API extern int32_t mono_environment_exitcode_get (void);
+MONO_API extern void mono_environment_exitcode_set (int32_t value);
 
 MONO_END_DECLS
 
index fa17fa29e241a8ba920b2ea10c198c0ec2ae50e8..17279507a010c68d2fa2c5bfd151fe4e7197eb16 100644 (file)
 
 MONO_BEGIN_DECLS
 
-extern MonoException *
+extern MONO_API MonoException *
 mono_exception_from_name               (MonoImage *image, 
                                        const char* name_space, 
                                        const char *name);
 
-MonoException *
+MONO_API MonoException *
 mono_exception_from_token              (MonoImage *image, uint32_t token);
 
-MonoException *
+MONO_API MonoException *
 mono_exception_from_name_two_strings (MonoImage *image, const char *name_space,
                                      const char *name, MonoString *a1, MonoString *a2);
 
-MonoException *
+MONO_API MonoException *
 mono_exception_from_name_msg          (MonoImage *image, const char *name_space,
                                        const char *name, const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_exception_from_token_two_strings (MonoImage *image, uint32_t token,
                                                   MonoString *a1, MonoString *a2);
 
-extern MonoException *
+extern MONO_API MonoException *
 mono_exception_from_name_domain        (MonoDomain *domain, MonoImage *image, 
                                        const char* name_space, 
                                        const char *name);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_divide_by_zero      (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_security            (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_arithmetic          (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_overflow            (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_null_reference      (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_execution_engine    (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_thread_abort        (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_thread_state        (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_thread_interrupted  (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_serialization       (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_invalid_cast        (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_invalid_operation (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_index_out_of_range  (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_array_type_mismatch (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_type_load           (MonoString *class_name, char *assembly_name);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_missing_method      (const char *class_name, const char *member_name);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_missing_field       (const char *class_name, const char *member_name);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_not_implemented     (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_not_supported       (const char *msg);
 
-MonoException*
+MONO_API MonoException*
 mono_get_exception_argument_null       (const char *arg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_argument            (const char *arg, const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_argument_out_of_range (const char *arg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_io                    (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_file_not_found        (MonoString *fname);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_file_not_found2       (const char *msg, MonoString *fname);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_type_initialization (const char *type_name, MonoException *inner);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_synchronization_lock (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_cannot_unload_appdomain (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_appdomain_unloaded (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_bad_image_format (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_bad_image_format2 (const char *msg, MonoString *fname);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_stack_overflow (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_out_of_memory (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_field_access (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_method_access (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_reflection_type_load (MonoArray *types, MonoArray *exceptions);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_runtime_wrapped (MonoObject *wrapped_exception);
 
 MONO_END_DECLS
index 2ef9a933b32d4dd9ac68fe75a183c6f8ed3dcd35..9ac75836d3263a570941b56308003570ae6048c9 100644 (file)
@@ -112,10 +112,10 @@ extern void mono_gc_set_stack_end (void *stack_end) MONO_INTERNAL;
 /* only valid after the RECLAIM_START GC event and before RECLAIM_END
  * Not exported in public headers, but can be linked to (unsupported).
  */
-extern gboolean mono_object_is_alive (MonoObject* obj);
-extern gboolean mono_gc_is_finalizer_thread (MonoThread *thread);
-extern gpointer mono_gc_out_of_memory (size_t size);
-extern void     mono_gc_enable_events (void);
+extern MONO_API gboolean mono_object_is_alive (MonoObject* obj);
+extern MONO_API gboolean mono_gc_is_finalizer_thread (MonoThread *thread);
+extern MONO_API gpointer mono_gc_out_of_memory (size_t size);
+extern MONO_API void     mono_gc_enable_events (void);
 
 /* disappearing link functionality */
 void        mono_gc_weak_link_add    (void **link_addr, MonoObject *obj, gboolean track) MONO_INTERNAL;
@@ -146,7 +146,7 @@ typedef void (*MonoGCMarkFunc)     (void **addr);
 typedef void (*MonoGCRootMarkFunc) (void *addr, MonoGCMarkFunc mark_func);
 
 /* Create a descriptor with a user defined marking function */
-void *mono_gc_make_root_descr_user (MonoGCRootMarkFunc marker);
+MONO_API void *mono_gc_make_root_descr_user (MonoGCRootMarkFunc marker);
 
 /* Return whenever user defined marking functions are supported */
 gboolean mono_gc_user_markers_supported (void) MONO_INTERNAL;
index 430af42c0cf90c9147866f834a83fdb8b975a07f..5b40a125c11d6171fe223df70e7366413f5803aa 100644 (file)
@@ -1625,6 +1625,7 @@ mono_image_close_except_pools (MonoImage *image)
        free_hash (image->synchronized_generic_cache);
        free_hash (image->remoting_invoke_cache);
        free_hash (image->runtime_invoke_cache);
+       free_hash (image->runtime_invoke_vtype_cache);
        free_hash (image->runtime_invoke_direct_cache);
        free_hash (image->runtime_invoke_vcall_cache);
        free_hash (image->synchronized_cache);
index a42be33a3e4eaa981dab58f76627e2533816ac62..c3ad58b3431c00e04a95676339e5f07ea2e3291f 100644 (file)
@@ -18,65 +18,65 @@ typedef enum {
        MONO_IMAGE_IMAGE_INVALID
 } MonoImageOpenStatus;
 
-void          mono_images_init    (void);
-void          mono_images_cleanup (void);
+MONO_API void          mono_images_init    (void);
+MONO_API void          mono_images_cleanup (void);
 
-MonoImage    *mono_image_open     (const char *fname,
+MONO_API MonoImage    *mono_image_open     (const char *fname,
                                   MonoImageOpenStatus *status);
-MonoImage    *mono_image_open_full (const char *fname,
+MONO_API MonoImage    *mono_image_open_full (const char *fname,
                                   MonoImageOpenStatus *status, mono_bool refonly);
-MonoImage    *mono_pe_file_open     (const char *fname,
+MONO_API MonoImage    *mono_pe_file_open     (const char *fname,
                                     MonoImageOpenStatus *status);
-MonoImage    *mono_image_open_from_data (char *data, uint32_t data_len, mono_bool need_copy,
+MONO_API MonoImage    *mono_image_open_from_data (char *data, uint32_t data_len, mono_bool need_copy,
                                          MonoImageOpenStatus *status);
-MonoImage    *mono_image_open_from_data_full (char *data, uint32_t data_len, mono_bool need_copy,
+MONO_API MonoImage    *mono_image_open_from_data_full (char *data, uint32_t data_len, mono_bool need_copy,
                                          MonoImageOpenStatus *status, mono_bool refonly);
-MonoImage    *mono_image_open_from_data_with_name (char *data, uint32_t data_len, mono_bool need_copy,
+MONO_API MonoImage    *mono_image_open_from_data_with_name (char *data, uint32_t data_len, mono_bool need_copy,
                                                    MonoImageOpenStatus *status, mono_bool refonly, const char *name);
-void          mono_image_fixup_vtable (MonoImage *image);
-MonoImage    *mono_image_loaded   (const char *name);
-MonoImage    *mono_image_loaded_full   (const char *name, mono_bool refonly);
-MonoImage    *mono_image_loaded_by_guid (const char *guid);
-MonoImage    *mono_image_loaded_by_guid_full (const char *guid, mono_bool refonly);
-void          mono_image_init     (MonoImage *image);
-void          mono_image_close    (MonoImage *image);
-void          mono_image_addref   (MonoImage *image);
-const char   *mono_image_strerror (MonoImageOpenStatus status);
+MONO_API void          mono_image_fixup_vtable (MonoImage *image);
+MONO_API MonoImage    *mono_image_loaded   (const char *name);
+MONO_API MonoImage    *mono_image_loaded_full   (const char *name, mono_bool refonly);
+MONO_API MonoImage    *mono_image_loaded_by_guid (const char *guid);
+MONO_API MonoImage    *mono_image_loaded_by_guid_full (const char *guid, mono_bool refonly);
+MONO_API void          mono_image_init     (MonoImage *image);
+MONO_API void          mono_image_close    (MonoImage *image);
+MONO_API void          mono_image_addref   (MonoImage *image);
+MONO_API const char   *mono_image_strerror (MonoImageOpenStatus status);
 
-int           mono_image_ensure_section     (MonoImage *image,
+MONO_API int           mono_image_ensure_section     (MonoImage *image,
                                             const char *section);
-int           mono_image_ensure_section_idx (MonoImage *image,
+MONO_API int           mono_image_ensure_section_idx (MonoImage *image,
                                             int section);
 
-uint32_t       mono_image_get_entry_point    (MonoImage *image);
-const char   *mono_image_get_resource       (MonoImage *image, uint32_t offset, uint32_t *size);
-MonoImage*    mono_image_load_file_for_image (MonoImage *image, int fileidx);
+MONO_API uint32_t       mono_image_get_entry_point    (MonoImage *image);
+MONO_API const char   *mono_image_get_resource       (MonoImage *image, uint32_t offset, uint32_t *size);
+MONO_API MonoImage*    mono_image_load_file_for_image (MonoImage *image, int fileidx);
 
-MonoImage*    mono_image_load_module (MonoImage *image, int idx);
+MONO_API MonoImage*    mono_image_load_module (MonoImage *image, int idx);
 
-const char*   mono_image_get_name       (MonoImage *image);
-const char*   mono_image_get_filename   (MonoImage *image);
-const char *  mono_image_get_guid       (MonoImage *image);
-MonoAssembly* mono_image_get_assembly   (MonoImage *image);
-mono_bool     mono_image_is_dynamic     (MonoImage *image);
-char*         mono_image_rva_map        (MonoImage *image, uint32_t rva);
+MONO_API const char*   mono_image_get_name       (MonoImage *image);
+MONO_API const char*   mono_image_get_filename   (MonoImage *image);
+MONO_API const char *  mono_image_get_guid       (MonoImage *image);
+MONO_API MonoAssembly* mono_image_get_assembly   (MonoImage *image);
+MONO_API mono_bool     mono_image_is_dynamic     (MonoImage *image);
+MONO_API char*         mono_image_rva_map        (MonoImage *image, uint32_t rva);
 
-const MonoTableInfo *mono_image_get_table_info (MonoImage *image, int table_id);
-int                  mono_image_get_table_rows (MonoImage *image, int table_id);
-int                  mono_table_info_get_rows  (const MonoTableInfo *table);
+MONO_API const MonoTableInfo *mono_image_get_table_info (MonoImage *image, int table_id);
+MONO_API int                  mono_image_get_table_rows (MonoImage *image, int table_id);
+MONO_API int                  mono_table_info_get_rows  (const MonoTableInfo *table);
 
 /* This actually returns a MonoPEResourceDataEntry *, but declaring it
  * causes an include file loop.
  */
-void*      mono_image_lookup_resource (MonoImage *image, uint32_t res_id,
+MONO_API void*      mono_image_lookup_resource (MonoImage *image, uint32_t res_id,
                                          uint32_t lang_id, mono_unichar2 *name);
 
-const char*   mono_image_get_public_key  (MonoImage *image, uint32_t *size);
-const char*   mono_image_get_strong_name (MonoImage *image, uint32_t *size);
-uint32_t       mono_image_strong_name_position (MonoImage *image, uint32_t *size);
-void          mono_image_add_to_name_cache (MonoImage *image, 
+MONO_API const char*   mono_image_get_public_key  (MonoImage *image, uint32_t *size);
+MONO_API const char*   mono_image_get_strong_name (MonoImage *image, uint32_t *size);
+MONO_API uint32_t       mono_image_strong_name_position (MonoImage *image, uint32_t *size);
+MONO_API void          mono_image_add_to_name_cache (MonoImage *image, 
                        const char *nspace, const char *name, uint32_t idx);
-mono_bool     mono_image_has_authenticode_entry (MonoImage *image);
+MONO_API mono_bool     mono_image_has_authenticode_entry (MonoImage *image);
 
 MONO_END_DECLS
 
index c519c30607f2826f5729f6dc603a5281453b7e28..b159dee727ab7a6bb55896e513bb25ed90634fa6 100644 (file)
@@ -8,86 +8,86 @@ MONO_BEGIN_DECLS
 
 typedef mono_bool (*MonoStackWalk)     (MonoMethod *method, int32_t native_offset, int32_t il_offset, mono_bool managed, void* data);
 
-MonoMethod *
+MONO_API MonoMethod *
 mono_get_method             (MonoImage *image, uint32_t token, MonoClass *klass);
 
-MonoMethod *
+MONO_API MonoMethod *
 mono_get_method_full        (MonoImage *image, uint32_t token, MonoClass *klass,
                             MonoGenericContext *context);
 
-MonoMethod *
+MONO_API MonoMethod *
 mono_get_method_constrained (MonoImage *image, uint32_t token, MonoClass *constrained_class,
                             MonoGenericContext *context, MonoMethod **cil_method);
 
-void               
+MONO_API void               
 mono_free_method           (MonoMethod *method);
 
-MonoMethodSignature*
+MONO_API MonoMethodSignature*
 mono_method_get_signature_full (MonoMethod *method, MonoImage *image, uint32_t token,
                                MonoGenericContext *context);
 
-MonoMethodSignature* 
+MONO_API MonoMethodSignature* 
 mono_method_get_signature  (MonoMethod *method, MonoImage *image, uint32_t token);
 
-MonoMethodSignature* 
+MONO_API MonoMethodSignature* 
 mono_method_signature      (MonoMethod *method);
 
-MonoMethodHeader* 
+MONO_API MonoMethodHeader* 
 mono_method_get_header     (MonoMethod *method);
 
-const char*
+MONO_API const char*
 mono_method_get_name       (MonoMethod *method);
 
-MonoClass*
+MONO_API MonoClass*
 mono_method_get_class      (MonoMethod *method);
 
-uint32_t
+MONO_API uint32_t
 mono_method_get_token      (MonoMethod *method);
 
-uint32_t
+MONO_API uint32_t
 mono_method_get_flags      (MonoMethod *method, uint32_t *iflags);
 
-uint32_t
+MONO_API uint32_t
 mono_method_get_index      (MonoMethod *method);
 
-MonoImage *
+MONO_API MonoImage *
 mono_load_image            (const char *fname, MonoImageOpenStatus *status);
 
-void
+MONO_API void
 mono_add_internal_call     (const char *name, const void* method);
 
-void*
+MONO_API void*
 mono_lookup_internal_call (MonoMethod *method);
 
-const char*
+MONO_API const char*
 mono_lookup_icall_symbol (MonoMethod *m);
 
-void
+MONO_API void
 mono_dllmap_insert (MonoImage *assembly, const char *dll, const char *func, const char *tdll, const char *tfunc);
 
-void*
+MONO_API void*
 mono_lookup_pinvoke_call (MonoMethod *method, const char **exc_class, const char **exc_arg);
 
-void
+MONO_API void
 mono_method_get_param_names (MonoMethod *method, const char **names);
 
-uint32_t
+MONO_API uint32_t
 mono_method_get_param_token (MonoMethod *method, int idx);
 
-void
+MONO_API void
 mono_method_get_marshal_info (MonoMethod *method, MonoMarshalSpec **mspecs);
 
-mono_bool
+MONO_API mono_bool
 mono_method_has_marshal_info (MonoMethod *method);
 
-MonoMethod*
+MONO_API MonoMethod*
 mono_method_get_last_managed  (void);
 
-void
+MONO_API void
 mono_stack_walk         (MonoStackWalk func, void* user_data);
 
 /* Use this if the IL offset is not needed: it's faster */
-void
+MONO_API void
 mono_stack_walk_no_il   (MonoStackWalk func, void* user_data);
 
 MONO_END_DECLS
index c094574146c845b5e932628805dec6da996f0d5c..49670a16bd103aad7389176a43ba7f20871f2897 100644 (file)
@@ -98,7 +98,7 @@ emit_struct_conv_full (MonoMethodBuilder *mb, MonoClass *klass, gboolean to_obje
 static void 
 mono_struct_delete_old (MonoClass *klass, char *ptr);
 
-void *
+MONO_API void *
 mono_marshal_string_to_utf16 (MonoString *s);
 
 static void *
@@ -150,7 +150,7 @@ mono_marshal_check_domain_image (gint32 domain_id, MonoImage *image);
 static MonoObject *
 mono_remoting_wrapper (MonoMethod *method, gpointer *params);
 
-void
+MONO_API void
 mono_upgrade_remote_class_wrapper (MonoReflectionType *rtype, MonoTransparentProxy *tproxy);
 
 #endif
@@ -4968,9 +4968,15 @@ mono_marshal_get_runtime_invoke (MonoMethod *method, gboolean virtual)
 
                callsig = mono_marshal_get_runtime_invoke_sig (callsig);
 
-               cache = get_cache (&target_klass->image->runtime_invoke_cache, 
-                                                  (GHashFunc)mono_signature_hash, 
-                                                  (GCompareFunc)runtime_invoke_signature_equal);
+               if (method->klass->valuetype && mono_method_signature (method)->hasthis)
+                       /* These have a different csig */
+                       cache = get_cache (&target_klass->image->runtime_invoke_vtype_cache,
+                                                          (GHashFunc)mono_signature_hash,
+                                                          (GCompareFunc)runtime_invoke_signature_equal);
+               else
+                       cache = get_cache (&target_klass->image->runtime_invoke_cache,
+                                                          (GHashFunc)mono_signature_hash,
+                                                          (GCompareFunc)runtime_invoke_signature_equal);
 
                /* from mono_marshal_find_in_cache */
                mono_marshal_lock ();
@@ -12951,6 +12957,8 @@ mono_marshal_free_inflated_wrappers (MonoMethod *method)
                g_hash_table_remove (method->klass->image->delegate_invoke_cache, sig);
        if (sig && method->klass->image->runtime_invoke_cache)
                g_hash_table_remove (method->klass->image->runtime_invoke_cache, sig);
+       if (sig && method->klass->image->runtime_invoke_vtype_cache)
+               g_hash_table_remove (method->klass->image->runtime_invoke_vtype_cache, sig);
 
         /*
          * indexed by SignatureMethodPair
index 9046b14589e9a8cd71631811fa1850e5a32242b4..22db7a6b330d99e3f068e5cc47dc9d213bc35b70 100644 (file)
@@ -524,16 +524,16 @@ ves_icall_Mono_Interop_ComInteropProxy_AddProxy (gpointer pUnk, MonoComInteropPr
 MonoComInteropProxy*
 ves_icall_Mono_Interop_ComInteropProxy_FindProxy (gpointer pUnk) MONO_INTERNAL;
 
-void
+MONO_API void
 mono_win32_compat_CopyMemory (gpointer dest, gconstpointer source, gsize length);
 
-void
+MONO_API void
 mono_win32_compat_FillMemory (gpointer dest, gsize length, guchar fill);
 
-void
+MONO_API void
 mono_win32_compat_MoveMemory (gpointer dest, gconstpointer source, gsize length);
 
-void
+MONO_API void
 mono_win32_compat_ZeroMemory (gpointer dest, gsize length);
 
 void
index b8226ed616838d300c2fafb81e9f6e9fc9bc022b..b096be6e4fd4e52bd6d50aa91e8ca7731d0d4891 100644 (file)
@@ -7,37 +7,37 @@ MONO_BEGIN_DECLS
 
 typedef struct _MonoMemPool MonoMemPool;
 
-MonoMemPool *
+MONO_API MonoMemPool *
 mono_mempool_new           (void);
 
-MonoMemPool *
+MONO_API MonoMemPool *
 mono_mempool_new_size      (int initial_size);
 
-void
+MONO_API void
 mono_mempool_destroy       (MonoMemPool *pool);
 
-void
+MONO_API void
 mono_mempool_invalidate    (MonoMemPool *pool);
 
-void
+MONO_API void
 mono_mempool_empty         (MonoMemPool *pool);
 
-void
+MONO_API void
 mono_mempool_stats         (MonoMemPool *pool);
 
-void*
+MONO_API void*
 mono_mempool_alloc         (MonoMemPool *pool, unsigned int size);
 
-void*
+MONO_API void*
 mono_mempool_alloc0        (MonoMemPool *pool, unsigned int size);
 
-mono_bool
+MONO_API mono_bool
 mono_mempool_contains_addr (MonoMemPool *pool, void* addr);
 
-char*
+MONO_API char*
 mono_mempool_strdup        (MonoMemPool *pool, const char *s);
 
-uint32_t
+MONO_API uint32_t
 mono_mempool_get_allocated (MonoMemPool *pool);
 
 MONO_END_DECLS
index ae7b87601719be46a436d053a491ef2db3689ce3..bbf66fbefa387ddbc421ec5c0b187a9b977111e1 100644 (file)
@@ -256,6 +256,7 @@ struct _MonoImage {
        GHashTable *delegate_end_invoke_cache;
        GHashTable *delegate_invoke_cache;
        GHashTable *runtime_invoke_cache;
+       GHashTable *runtime_invoke_vtype_cache;
 
        /*
         * indexed by SignatureMethodPair
@@ -590,7 +591,7 @@ mono_metadata_clean_for_image (MonoImage *image) MONO_INTERNAL;
 void
 mono_metadata_clean_generic_classes_for_image (MonoImage *image) MONO_INTERNAL;
 
-void
+MONO_API void
 mono_metadata_cleanup (void);
 
 const char *   mono_meta_table_name              (int table) MONO_INTERNAL;
@@ -610,7 +611,7 @@ mono_metadata_parse_array_full              (MonoImage             *image,
                                             const char            *ptr,
                                             const char           **rptr) MONO_INTERNAL;
 
-MonoType *
+MONO_API MonoType *
 mono_metadata_parse_type_full               (MonoImage             *image,
                                             MonoGenericContainer  *container,
                                             MonoParseTypeMode      mode,
@@ -623,14 +624,14 @@ mono_metadata_parse_signature_full          (MonoImage             *image,
                                             MonoGenericContainer  *generic_container,
                                             guint32                token) MONO_INTERNAL;
 
-MonoMethodSignature *
+MONO_API MonoMethodSignature *
 mono_metadata_parse_method_signature_full   (MonoImage             *image,
                                             MonoGenericContainer  *generic_container,
                                             int                     def,
                                             const char             *ptr,
                                             const char            **rptr);
 
-MonoMethodHeader *
+MONO_API MonoMethodHeader *
 mono_metadata_parse_mh_full                 (MonoImage             *image,
                                             MonoGenericContainer  *container,
                                             const char            *ptr);
@@ -689,7 +690,7 @@ mono_assembly_name_parse_full                    (const char           *name,
                                              gboolean *is_version_defined,
                                                  gboolean *is_token_defined) MONO_INTERNAL;
 
-guint32 mono_metadata_get_generic_param_row (MonoImage *image, guint32 token, guint32 *owner);
+MONO_API guint32 mono_metadata_get_generic_param_row (MonoImage *image, guint32 token, guint32 *owner);
 
 void mono_unload_interface_ids (MonoBitSet *bitset) MONO_INTERNAL;
 
@@ -704,7 +705,7 @@ mono_get_shared_generic_inst (MonoGenericContainer *container) MONO_INTERNAL;
 int
 mono_type_stack_size_internal (MonoType *t, int *align, gboolean allow_open) MONO_INTERNAL;
 
-void            mono_type_get_desc (GString *res, MonoType *type, mono_bool include_namespace);
+MONO_API void            mono_type_get_desc (GString *res, MonoType *type, mono_bool include_namespace);
 
 gboolean
 mono_metadata_type_equal_full (MonoType *t1, MonoType *t2, gboolean signature_only) MONO_INTERNAL;
@@ -715,7 +716,7 @@ mono_metadata_parse_marshal_spec_full (MonoImage *image, const char *ptr) MONO_I
 guint         mono_metadata_generic_inst_hash (gconstpointer data) MONO_INTERNAL;
 gboolean       mono_metadata_generic_inst_equal (gconstpointer ka, gconstpointer kb) MONO_INTERNAL;
 
-void
+MONO_API void
 mono_metadata_field_info_with_mempool (
                                          MonoImage *meta, 
                                      guint32       table_index,
index 4d83adf9ead5bdccd00e61744694780317bfc095..b9c591bf771347047fe23cb859c056bc34c55029 100644 (file)
@@ -198,14 +198,14 @@ typedef struct {
        } data;
 } MonoMarshalSpec;
 
-void         mono_metadata_init (void);
+MONO_API void         mono_metadata_init (void);
 
-void         mono_metadata_decode_row (const MonoTableInfo   *t,
+MONO_API void         mono_metadata_decode_row (const MonoTableInfo   *t,
                                       int                    idx,
                                       uint32_t               *res,
                                       int                    res_size);
 
-uint32_t      mono_metadata_decode_row_col (const MonoTableInfo *t, 
+MONO_API uint32_t      mono_metadata_decode_row_col (const MonoTableInfo *t, 
                                           int            idx, 
                                           unsigned int          col);
 
@@ -216,61 +216,61 @@ uint32_t      mono_metadata_decode_row_col (const MonoTableInfo *t,
 #define mono_metadata_table_size(bitfield,table) ((((bitfield) >> ((table)*2)) & 0x3) + 1)
 #define mono_metadata_table_count(bitfield) ((bitfield) >> 24)
 
-int mono_metadata_compute_size (MonoImage   *meta,
+MONO_API int mono_metadata_compute_size (MonoImage   *meta,
                                 int             tableindex,
                                 uint32_t        *result_bitfield);
 
 /*
  *
  */
-const char    *mono_metadata_locate        (MonoImage *meta, int table, int idx);
-const char    *mono_metadata_locate_token  (MonoImage *meta, uint32_t token);
+MONO_API const char    *mono_metadata_locate        (MonoImage *meta, int table, int idx);
+MONO_API const char    *mono_metadata_locate_token  (MonoImage *meta, uint32_t token);
                                           
-const char    *mono_metadata_string_heap   (MonoImage *meta, uint32_t table_index);
-const char    *mono_metadata_blob_heap     (MonoImage *meta, uint32_t table_index);
-const char    *mono_metadata_user_string   (MonoImage *meta, uint32_t table_index);
-const char    *mono_metadata_guid_heap     (MonoImage *meta, uint32_t table_index);
+MONO_API const char    *mono_metadata_string_heap   (MonoImage *meta, uint32_t table_index);
+MONO_API const char    *mono_metadata_blob_heap     (MonoImage *meta, uint32_t table_index);
+MONO_API const char    *mono_metadata_user_string   (MonoImage *meta, uint32_t table_index);
+MONO_API const char    *mono_metadata_guid_heap     (MonoImage *meta, uint32_t table_index);
 
-uint32_t mono_metadata_typedef_from_field  (MonoImage *meta, uint32_t table_index);
-uint32_t mono_metadata_typedef_from_method (MonoImage *meta, uint32_t table_index);
-uint32_t mono_metadata_nested_in_typedef   (MonoImage *meta, uint32_t table_index);
-uint32_t mono_metadata_nesting_typedef     (MonoImage *meta, uint32_t table_index, uint32_t start_index);
+MONO_API uint32_t mono_metadata_typedef_from_field  (MonoImage *meta, uint32_t table_index);
+MONO_API uint32_t mono_metadata_typedef_from_method (MonoImage *meta, uint32_t table_index);
+MONO_API uint32_t mono_metadata_nested_in_typedef   (MonoImage *meta, uint32_t table_index);
+MONO_API uint32_t mono_metadata_nesting_typedef     (MonoImage *meta, uint32_t table_index, uint32_t start_index);
 
-MonoClass** mono_metadata_interfaces_from_typedef (MonoImage *meta, uint32_t table_index, unsigned int *count);
+MONO_API MonoClass** mono_metadata_interfaces_from_typedef (MonoImage *meta, uint32_t table_index, unsigned int *count);
 
-uint32_t     mono_metadata_events_from_typedef     (MonoImage *meta, uint32_t table_index, unsigned int *end_idx);
-uint32_t     mono_metadata_methods_from_event      (MonoImage *meta, uint32_t table_index, unsigned int *end);
-uint32_t     mono_metadata_properties_from_typedef (MonoImage *meta, uint32_t table_index, unsigned int *end);
-uint32_t     mono_metadata_methods_from_property   (MonoImage *meta, uint32_t table_index, unsigned int *end);
-uint32_t     mono_metadata_packing_from_typedef    (MonoImage *meta, uint32_t table_index, uint32_t *packing, uint32_t *size);
-const char* mono_metadata_get_marshal_info        (MonoImage *meta, uint32_t idx, mono_bool is_field);
-uint32_t     mono_metadata_custom_attrs_from_index (MonoImage *meta, uint32_t cattr_index);
+MONO_API uint32_t     mono_metadata_events_from_typedef     (MonoImage *meta, uint32_t table_index, unsigned int *end_idx);
+MONO_API uint32_t     mono_metadata_methods_from_event      (MonoImage *meta, uint32_t table_index, unsigned int *end);
+MONO_API uint32_t     mono_metadata_properties_from_typedef (MonoImage *meta, uint32_t table_index, unsigned int *end);
+MONO_API uint32_t     mono_metadata_methods_from_property   (MonoImage *meta, uint32_t table_index, unsigned int *end);
+MONO_API uint32_t     mono_metadata_packing_from_typedef    (MonoImage *meta, uint32_t table_index, uint32_t *packing, uint32_t *size);
+MONO_API const char* mono_metadata_get_marshal_info        (MonoImage *meta, uint32_t idx, mono_bool is_field);
+MONO_API uint32_t     mono_metadata_custom_attrs_from_index (MonoImage *meta, uint32_t cattr_index);
 
-MonoMarshalSpec *mono_metadata_parse_marshal_spec (MonoImage *image, const char *ptr);
+MONO_API MonoMarshalSpec *mono_metadata_parse_marshal_spec (MonoImage *image, const char *ptr);
 
-void mono_metadata_free_marshal_spec (MonoMarshalSpec *spec);
+MONO_API void mono_metadata_free_marshal_spec (MonoMarshalSpec *spec);
 
-uint32_t     mono_metadata_implmap_from_method     (MonoImage *meta, uint32_t method_idx);
+MONO_API uint32_t     mono_metadata_implmap_from_method     (MonoImage *meta, uint32_t method_idx);
 
-void        mono_metadata_field_info (MonoImage *meta, 
+MONO_API void        mono_metadata_field_info (MonoImage *meta, 
                                      uint32_t       table_index,
                                      uint32_t      *offset,
                                      uint32_t      *rva,
                                      MonoMarshalSpec **marshal_spec);
 
-uint32_t     mono_metadata_get_constant_index (MonoImage *meta, uint32_t token, uint32_t hint);
+MONO_API uint32_t     mono_metadata_get_constant_index (MonoImage *meta, uint32_t token, uint32_t hint);
 
 /*
  * Functions to extract information from the Blobs
  */
-uint32_t mono_metadata_decode_value     (const char            *ptr,
+MONO_API uint32_t mono_metadata_decode_value     (const char            *ptr,
                                         const char           **rptr);
-int32_t mono_metadata_decode_signed_value (const char *ptr, const char **rptr);
+MONO_API int32_t mono_metadata_decode_signed_value (const char *ptr, const char **rptr);
 
-uint32_t mono_metadata_decode_blob_size (const char            *ptr,
+MONO_API uint32_t mono_metadata_decode_blob_size (const char            *ptr,
                                         const char           **rptr);
 
-void mono_metadata_encode_value (uint32_t value, char *bug, char **endbuf);
+MONO_API void mono_metadata_encode_value (uint32_t value, char *bug, char **endbuf);
 
 #define MONO_OFFSET_IN_CLAUSE(clause,offset) \
        ((clause)->try_offset <= (offset) && (offset) < ((clause)->try_offset + (clause)->try_len))
@@ -329,133 +329,133 @@ typedef enum {
        MONO_PARSE_FIELD
 } MonoParseTypeMode;
 
-mono_bool
+MONO_API mono_bool
 mono_type_is_byref       (MonoType *type);
 
-int
+MONO_API int
 mono_type_get_type       (MonoType *type);
 
 /* For MONO_TYPE_FNPTR */
-MonoMethodSignature*
+MONO_API MonoMethodSignature*
 mono_type_get_signature  (MonoType *type);
 
 /* For MONO_TYPE_CLASS, VALUETYPE */
-MonoClass*
+MONO_API MonoClass*
 mono_type_get_class      (MonoType *type);
 
-MonoArrayType*
+MONO_API MonoArrayType*
 mono_type_get_array_type (MonoType *type);
 
 /* For MONO_TYPE_PTR */
-MonoType*
+MONO_API MonoType*
 mono_type_get_ptr_type (MonoType *type);
 
-MonoClass*
+MONO_API MonoClass*
 mono_type_get_modifiers  (MonoType *type, mono_bool *is_required, void **iter);
 
-mono_bool mono_type_is_struct    (MonoType *type);
-mono_bool mono_type_is_void      (MonoType *type);
-mono_bool mono_type_is_pointer   (MonoType *type);
-mono_bool mono_type_is_reference (MonoType *type);
+MONO_API mono_bool mono_type_is_struct    (MonoType *type);
+MONO_API mono_bool mono_type_is_void      (MonoType *type);
+MONO_API mono_bool mono_type_is_pointer   (MonoType *type);
+MONO_API mono_bool mono_type_is_reference (MonoType *type);
 
-MonoType*
+MONO_API MonoType*
 mono_signature_get_return_type (MonoMethodSignature *sig);
 
-MonoType*
+MONO_API MonoType*
 mono_signature_get_params      (MonoMethodSignature *sig, void **iter);
 
-uint32_t
+MONO_API uint32_t
 mono_signature_get_param_count (MonoMethodSignature *sig);
 
-uint32_t
+MONO_API uint32_t
 mono_signature_get_call_conv   (MonoMethodSignature *sig);
 
-int
+MONO_API int
 mono_signature_vararg_start    (MonoMethodSignature *sig);
 
-mono_bool
+MONO_API mono_bool
 mono_signature_is_instance     (MonoMethodSignature *sig);
 
-mono_bool
+MONO_API mono_bool
 mono_signature_explicit_this   (MonoMethodSignature *sig);
 
-uint32_t     mono_metadata_parse_typedef_or_ref (MonoImage      *m,
+MONO_API uint32_t     mono_metadata_parse_typedef_or_ref (MonoImage      *m,
                                                 const char      *ptr,
                                                 const char     **rptr);
-int            mono_metadata_parse_custom_mod  (MonoImage      *m,
+MONO_API int            mono_metadata_parse_custom_mod  (MonoImage      *m,
                                                MonoCustomMod   *dest,
                                                const char      *ptr,
                                                const char     **rptr);
-MonoArrayType *mono_metadata_parse_array       (MonoImage      *m,
+MONO_API MonoArrayType *mono_metadata_parse_array       (MonoImage      *m,
                                                const char      *ptr,
                                                const char     **rptr);
-void           mono_metadata_free_array        (MonoArrayType     *array);
-MonoType      *mono_metadata_parse_type        (MonoImage      *m,
+MONO_API void           mono_metadata_free_array        (MonoArrayType     *array);
+MONO_API MonoType      *mono_metadata_parse_type        (MonoImage      *m,
                                                MonoParseTypeMode  mode,
                                                short              opt_attrs,
                                                const char        *ptr,
                                                const char       **rptr);
-MonoType      *mono_metadata_parse_param       (MonoImage      *m,
+MONO_API MonoType      *mono_metadata_parse_param       (MonoImage      *m,
                                                const char      *ptr,
                                                const char      **rptr);
-MonoType      *mono_metadata_parse_ret_type    (MonoImage      *m,
+MONO_API MonoType      *mono_metadata_parse_ret_type    (MonoImage      *m,
                                                const char      *ptr,
                                                const char      **rptr);
-MonoType      *mono_metadata_parse_field_type  (MonoImage      *m,
+MONO_API MonoType      *mono_metadata_parse_field_type  (MonoImage      *m,
                                                short            field_flags,
                                                const char      *ptr,
                                                const char      **rptr);
-MonoType      *mono_type_create_from_typespec  (MonoImage        *image, 
+MONO_API MonoType      *mono_type_create_from_typespec  (MonoImage        *image, 
                                                uint32_t           type_spec);
-void           mono_metadata_free_type         (MonoType        *type);
-int            mono_type_size                  (MonoType        *type, 
+MONO_API void           mono_metadata_free_type         (MonoType        *type);
+MONO_API int            mono_type_size                  (MonoType        *type, 
                                                int             *alignment);
-int            mono_type_stack_size            (MonoType        *type, 
+MONO_API int            mono_type_stack_size            (MonoType        *type, 
                                                int             *alignment);
 
-mono_bool       mono_type_generic_inst_is_valuetype      (MonoType *type);
-mono_bool       mono_metadata_generic_class_is_valuetype (MonoGenericClass *gclass);
-unsigned int          mono_metadata_generic_class_hash  (MonoGenericClass *gclass);
-mono_bool       mono_metadata_generic_class_equal (MonoGenericClass *g1, MonoGenericClass *g2);
+MONO_API mono_bool       mono_type_generic_inst_is_valuetype      (MonoType *type);
+MONO_API mono_bool       mono_metadata_generic_class_is_valuetype (MonoGenericClass *gclass);
+MONO_API unsigned int          mono_metadata_generic_class_hash  (MonoGenericClass *gclass);
+MONO_API mono_bool       mono_metadata_generic_class_equal (MonoGenericClass *g1, MonoGenericClass *g2);
 
-unsigned int          mono_metadata_type_hash         (MonoType *t1);
-mono_bool       mono_metadata_type_equal        (MonoType *t1, MonoType *t2);
+MONO_API unsigned int          mono_metadata_type_hash         (MonoType *t1);
+MONO_API mono_bool       mono_metadata_type_equal        (MonoType *t1, MonoType *t2);
 
-MonoMethodSignature  *mono_metadata_signature_alloc (MonoImage *image, uint32_t nparams);
+MONO_API MonoMethodSignature  *mono_metadata_signature_alloc (MonoImage *image, uint32_t nparams);
 
-MonoMethodSignature  *mono_metadata_signature_dup (MonoMethodSignature *sig);
+MONO_API MonoMethodSignature  *mono_metadata_signature_dup (MonoMethodSignature *sig);
 
-MonoMethodSignature  *mono_metadata_parse_signature (MonoImage *image, 
+MONO_API MonoMethodSignature  *mono_metadata_parse_signature (MonoImage *image, 
                                                     uint32_t    token);
 
-MonoMethodSignature  *mono_metadata_parse_method_signature (MonoImage            *m,
+MONO_API MonoMethodSignature  *mono_metadata_parse_method_signature (MonoImage            *m,
                                                             int                    def,
                                                             const char            *ptr,
                                                             const char           **rptr);
-void                  mono_metadata_free_method_signature  (MonoMethodSignature   *method);
+MONO_API void                  mono_metadata_free_method_signature  (MonoMethodSignature   *method);
 
-mono_bool          mono_metadata_signature_equal (MonoMethodSignature *sig1, 
+MONO_API mono_bool          mono_metadata_signature_equal (MonoMethodSignature *sig1, 
                                                 MonoMethodSignature *sig2);
 
-unsigned int             mono_signature_hash (MonoMethodSignature *sig);
+MONO_API unsigned int             mono_signature_hash (MonoMethodSignature *sig);
 
-MonoMethodHeader *mono_metadata_parse_mh (MonoImage *m, const char *ptr);
-void              mono_metadata_free_mh  (MonoMethodHeader *mh);
+MONO_API MonoMethodHeader *mono_metadata_parse_mh (MonoImage *m, const char *ptr);
+MONO_API void              mono_metadata_free_mh  (MonoMethodHeader *mh);
 
 /* MonoMethodHeader acccessors */
-const unsigned char*
+MONO_API const unsigned char*
 mono_method_header_get_code (MonoMethodHeader *header, uint32_t* code_size, uint32_t* max_stack);
 
-MonoType**
+MONO_API MonoType**
 mono_method_header_get_locals (MonoMethodHeader *header, uint32_t* num_locals, mono_bool *init_locals);
 
-int
+MONO_API int
 mono_method_header_get_num_clauses (MonoMethodHeader *header);
 
-int
+MONO_API int
 mono_method_header_get_clauses (MonoMethodHeader *header, MonoMethod *method, void **iter, MonoExceptionClause *clause);
 
-uint32_t 
+MONO_API uint32_t 
 mono_type_to_unmanaged (MonoType *type, MonoMarshalSpec *mspec, 
                        mono_bool as_field, mono_bool unicode, MonoMarshalConv *conv);
 
@@ -477,20 +477,20 @@ mono_type_to_unmanaged (MonoType *type, MonoMarshalSpec *mspec,
 
 #define mono_metadata_token_code(token) ((token & 0xff000000))
 
-uint32_t mono_metadata_token_from_dor (uint32_t dor_index);
+MONO_API uint32_t mono_metadata_token_from_dor (uint32_t dor_index);
 
-char *mono_guid_to_string (const uint8_t *guid);
+MONO_API char *mono_guid_to_string (const uint8_t *guid);
 
-uint32_t mono_metadata_declsec_from_index (MonoImage *meta, uint32_t idx);
+MONO_API uint32_t mono_metadata_declsec_from_index (MonoImage *meta, uint32_t idx);
 
-uint32_t mono_metadata_translate_token_index (MonoImage *image, int table, uint32_t idx);
+MONO_API uint32_t mono_metadata_translate_token_index (MonoImage *image, int table, uint32_t idx);
 
-void    mono_metadata_decode_table_row (MonoImage *image, int table,
+MONO_API void    mono_metadata_decode_table_row (MonoImage *image, int table,
                                       int                    idx,
                                       uint32_t               *res,
                                       int                    res_size);
 
-uint32_t      mono_metadata_decode_table_row_col (MonoImage *image, int table,
+MONO_API uint32_t      mono_metadata_decode_table_row_col (MonoImage *image, int table,
                                           int            idx, 
                                           unsigned int          col);
 
index 9933f1dd48730ba5f4d5ae377a67752543063a85..b701fb622173df9bcf4156fb06eb8563c977197b 100644 (file)
@@ -161,7 +161,7 @@ void
 mono_monitor_init_tls (void)
 {
 #if !defined(HOST_WIN32) && defined(HAVE_KW_THREAD)
-       tls_pthread_self = pthread_self ();
+       tls_pthread_self = (gsize) pthread_self ();
 #endif
 }
 
index a034cfb3dddb6caf029a7161536dfabac419a48b..183c2ec0b52371a31601b76efe469fc801cb53ab 100644 (file)
@@ -16,7 +16,7 @@
 
 G_BEGIN_DECLS
 
-void mono_locks_dump (gboolean include_untaken);
+MONO_API void mono_locks_dump (gboolean include_untaken);
 
 void mono_monitor_init (void) MONO_INTERNAL;
 void mono_monitor_cleanup (void) MONO_INTERNAL;
index 0b46425cdb5985a4a5a094a29b811266f3480df9..8ac5de0ebbe75f4e111fbbc446c4836fcd1df2c9 100644 (file)
 
 MONO_BEGIN_DECLS
 
-const char* mono_get_config_dir (void);
-void        mono_set_config_dir (const char *dir);
+MONO_API const char* mono_get_config_dir (void);
+MONO_API void        mono_set_config_dir (const char *dir);
 
-const char* mono_get_machine_config (void);
+MONO_API const char* mono_get_machine_config (void);
 
-void mono_config_cleanup      (void);
-void mono_config_parse        (const char *filename);
-void mono_config_for_assembly (MonoImage *assembly);
-void mono_config_parse_memory (const char *buffer);
+MONO_API void mono_config_cleanup      (void);
+MONO_API void mono_config_parse        (const char *filename);
+MONO_API void mono_config_for_assembly (MonoImage *assembly);
+MONO_API void mono_config_parse_memory (const char *buffer);
 
-const char* mono_config_string_for_assembly_file (const char *filename);
+MONO_API const char* mono_config_string_for_assembly_file (const char *filename);
 
 MONO_END_DECLS
 
index 450302a443d109c9f8d28c6757554937b275c30b..838b7ef4fa7b4cf9ad3e62256818462fed67f7f0 100644 (file)
@@ -50,42 +50,42 @@ extern volatile gint32 _mono_debugger_interruption_request;
 
 extern void (*mono_debugger_event_handler) (MonoDebuggerEvent event, guint64 data, guint64 arg);
 
-void            mono_debugger_initialize                    (gboolean use_debugger);
-void            mono_debugger_cleanup                       (void);
+MONO_API void            mono_debugger_initialize                    (gboolean use_debugger);
+MONO_API void            mono_debugger_cleanup                       (void);
 
-void            mono_debugger_lock                          (void);
-void            mono_debugger_unlock                        (void);
-void            mono_debugger_event                         (MonoDebuggerEvent event, guint64 data, guint64 arg);
+MONO_API void            mono_debugger_lock                          (void);
+MONO_API void            mono_debugger_unlock                        (void);
+MONO_API void            mono_debugger_event                         (MonoDebuggerEvent event, guint64 data, guint64 arg);
 
-gchar *
+MONO_API gchar *
 mono_debugger_check_runtime_version (const char *filename);
 
-void
+MONO_API void
 mono_debugger_class_initialized (MonoClass *klass);
 
-void
+MONO_API void
 mono_debugger_check_interruption (void);
 
-void
+MONO_API void
 mono_debugger_event_create_appdomain (MonoDomain *domain, gchar *shadow_path);
 
-void
+MONO_API void
 mono_debugger_event_unload_appdomain (MonoDomain *domain);
 
-MonoDebugMethodAddressList *
+MONO_API MonoDebugMethodAddressList *
 mono_debugger_insert_method_breakpoint (MonoMethod *method, guint64 idx);
 
-int
+MONO_API int
 mono_debugger_remove_method_breakpoint (guint64 index);
 
-void
+MONO_API void
 mono_debugger_check_breakpoints (MonoMethod *method, MonoDebugMethodAddress *debug_info);
 
-MonoClass *
+MONO_API MonoClass *
 mono_debugger_register_class_init_callback (MonoImage *image, const gchar *full_name,
                                            guint32 token, guint32 index);
 
-void
+MONO_API void
 mono_debugger_remove_class_init_callback (int index);
 
 #endif /* __MONO_DEBUG_DEBUGGER_H__ */
index daba9e2ee1cdf81f35105014fd1b097b0bd296e0..06ba9ffd47a5ff29cb2f5d0d6761d22defaf7097 100644 (file)
@@ -148,59 +148,59 @@ extern MonoDebugFormat mono_debug_format;
 extern int32_t mono_debug_debugger_version;
 extern int32_t _mono_debug_using_mono_debugger;
 
-void mono_debug_list_add (MonoDebugList **list, const void* data);
-void mono_debug_list_remove (MonoDebugList **list, const void* data);
+MONO_API void mono_debug_list_add (MonoDebugList **list, const void* data);
+MONO_API void mono_debug_list_remove (MonoDebugList **list, const void* data);
 
-void mono_debug_init (MonoDebugFormat format);
-void mono_debug_open_image_from_memory (MonoImage *image, const mono_byte *raw_contents, int size);
-void mono_debug_cleanup (void);
+MONO_API void mono_debug_init (MonoDebugFormat format);
+MONO_API void mono_debug_open_image_from_memory (MonoImage *image, const mono_byte *raw_contents, int size);
+MONO_API void mono_debug_cleanup (void);
 
-void mono_debug_close_image (MonoImage *image);
+MONO_API void mono_debug_close_image (MonoImage *image);
 
-void mono_debug_domain_unload (MonoDomain *domain);
-void mono_debug_domain_create (MonoDomain *domain);
+MONO_API void mono_debug_domain_unload (MonoDomain *domain);
+MONO_API void mono_debug_domain_create (MonoDomain *domain);
 
-mono_bool mono_debug_using_mono_debugger (void);
+MONO_API mono_bool mono_debug_using_mono_debugger (void);
 
-MonoDebugMethodAddress *
+MONO_API MonoDebugMethodAddress *
 mono_debug_add_method (MonoMethod *method, MonoDebugMethodJitInfo *jit, MonoDomain *domain);
 
-void
+MONO_API void
 mono_debug_remove_method (MonoMethod *method, MonoDomain *domain);
 
-MonoDebugMethodInfo *
+MONO_API MonoDebugMethodInfo *
 mono_debug_lookup_method (MonoMethod *method);
 
-MonoDebugMethodAddressList *
+MONO_API MonoDebugMethodAddressList *
 mono_debug_lookup_method_addresses (MonoMethod *method);
 
-MonoDebugMethodJitInfo*
+MONO_API MonoDebugMethodJitInfo*
 mono_debug_find_method (MonoMethod *method, MonoDomain *domain);
 
-void
+MONO_API void
 mono_debug_free_method_jit_info (MonoDebugMethodJitInfo *jit);
 
 
-void
+MONO_API void
 mono_debug_add_delegate_trampoline (void* code, int size);
 
-MonoDebugLocalsInfo*
+MONO_API MonoDebugLocalsInfo*
 mono_debug_lookup_locals (MonoMethod *method);
 
 /*
  * Line number support.
  */
 
-MonoDebugSourceLocation *
+MONO_API MonoDebugSourceLocation *
 mono_debug_lookup_source_location (MonoMethod *method, uint32_t address, MonoDomain *domain);
 
-int32_t
+MONO_API int32_t
 mono_debug_il_offset_from_address (MonoMethod *method, MonoDomain *domain, uint32_t native_offset);
 
-void
+MONO_API void
 mono_debug_free_source_location (MonoDebugSourceLocation *location);
 
-char *
+MONO_API char *
 mono_debug_print_stack_frame (MonoMethod *method, uint32_t native_offset, MonoDomain *domain);
 
 /*
@@ -209,11 +209,11 @@ mono_debug_print_stack_frame (MonoMethod *method, uint32_t native_offset, MonoDo
  * These methods are used by the JIT while running inside the Mono Debugger.
  */
 
-int             mono_debugger_method_has_breakpoint       (MonoMethod *method);
-int             mono_debugger_insert_breakpoint           (const char *method_name, mono_bool include_namespace);
+MONO_API int             mono_debugger_method_has_breakpoint       (MonoMethod *method);
+MONO_API int             mono_debugger_insert_breakpoint           (const char *method_name, mono_bool include_namespace);
 
-void mono_set_is_debugger_attached (mono_bool attached);
-mono_bool mono_is_debugger_attached (void);
+MONO_API void mono_set_is_debugger_attached (mono_bool attached);
+MONO_API mono_bool mono_is_debugger_attached (void);
 
 MONO_END_DECLS
 
index f2ff92b53b82cd2532217226f4b14f76fa367cb6..689cad28a88b142337ea997146cace72324c5283 100644 (file)
@@ -11,15 +11,15 @@ MONO_BEGIN_DECLS
 
 typedef int (*MonoGCReferences) (MonoObject *obj, MonoClass *klass, uintptr_t size, uintptr_t num, MonoObject **refs, uintptr_t *offsets, void *data);
 
-void   mono_gc_collect         (int generation);
-int    mono_gc_max_generation  (void);
-int    mono_gc_get_generation  (MonoObject *object);
-int    mono_gc_collection_count (int generation);
-int64_t mono_gc_get_used_size   (void);
-int64_t mono_gc_get_heap_size   (void);
-int    mono_gc_invoke_finalizers (void);
+MONO_API void   mono_gc_collect         (int generation);
+MONO_API int    mono_gc_max_generation  (void);
+MONO_API int    mono_gc_get_generation  (MonoObject *object);
+MONO_API int    mono_gc_collection_count (int generation);
+MONO_API int64_t mono_gc_get_used_size   (void);
+MONO_API int64_t mono_gc_get_heap_size   (void);
+MONO_API int    mono_gc_invoke_finalizers (void);
 /* heap walking is only valid in the pre-stop-world event callback */
-int    mono_gc_walk_heap        (int flags, MonoGCReferences callback, void *data);
+MONO_API int    mono_gc_walk_heap        (int flags, MonoGCReferences callback, void *data);
 
 MONO_END_DECLS
 
index 79c80b78d8dfe1824eff324cf7a568a7eba6b0be..7f451c37dda291ec849f792d016115b80961d1d6 100644 (file)
@@ -34,6 +34,7 @@
  */
 
 #include <glib.h>
+#include <mono/utils/mono-publib.h>
 
 G_BEGIN_DECLS
 
@@ -52,51 +53,51 @@ typedef enum {
 
 /* Hash tables
  */
-MonoGHashTable* mono_g_hash_table_new             (GHashFunc       hash_func,
+MONO_API MonoGHashTable* mono_g_hash_table_new            (GHashFunc       hash_func,
                                            GEqualFunc      key_equal_func);
-MonoGHashTable* mono_g_hash_table_new_type                (GHashFunc       hash_func,
+MONO_API MonoGHashTable* mono_g_hash_table_new_type               (GHashFunc       hash_func,
                                            GEqualFunc      key_equal_func,
                                            MonoGHashGCType type);
-MonoGHashTable* mono_g_hash_table_new_full                (GHashFunc       hash_func,
+MONO_API MonoGHashTable* mono_g_hash_table_new_full               (GHashFunc       hash_func,
                                            GEqualFunc      key_equal_func,
                                            GDestroyNotify  key_destroy_func,
                                            GDestroyNotify  value_destroy_func);
-void       mono_g_hash_table_destroy      (MonoGHashTable         *hash_table);
-void       mono_g_hash_table_insert               (MonoGHashTable         *hash_table,
+MONO_API void      mono_g_hash_table_destroy      (MonoGHashTable         *hash_table);
+MONO_API void      mono_g_hash_table_insert               (MonoGHashTable         *hash_table,
                                            gpointer        key,
                                            gpointer        value);
-void        mono_g_hash_table_replace           (MonoGHashTable     *hash_table,
+MONO_API void        mono_g_hash_table_replace           (MonoGHashTable     *hash_table,
                                            gpointer        key,
                                            gpointer        value);
-gboolean    mono_g_hash_table_remove              (MonoGHashTable         *hash_table,
+MONO_API gboolean    mono_g_hash_table_remove             (MonoGHashTable         *hash_table,
                                            gconstpointer   key);
-gboolean    mono_g_hash_table_steal             (MonoGHashTable     *hash_table,
+MONO_API gboolean    mono_g_hash_table_steal             (MonoGHashTable     *hash_table,
                                            gconstpointer   key);
-gpointer    mono_g_hash_table_lookup              (MonoGHashTable         *hash_table,
+MONO_API gpointer    mono_g_hash_table_lookup             (MonoGHashTable         *hash_table,
                                            gconstpointer   key);
-gboolean    mono_g_hash_table_lookup_extended   (MonoGHashTable           *hash_table,
+MONO_API gboolean    mono_g_hash_table_lookup_extended   (MonoGHashTable          *hash_table,
                                            gconstpointer   lookup_key,
                                            gpointer       *orig_key,
                                            gpointer       *value);
-void       mono_g_hash_table_foreach      (MonoGHashTable         *hash_table,
+MONO_API void      mono_g_hash_table_foreach      (MonoGHashTable         *hash_table,
                                            GHFunc          func,
                                            gpointer        user_data);
-guint      mono_g_hash_table_foreach_remove       (MonoGHashTable         *hash_table,
+MONO_API guint     mono_g_hash_table_foreach_remove       (MonoGHashTable         *hash_table,
                                            GHRFunc         func,
                                            gpointer        user_data);
-guint      mono_g_hash_table_foreach_steal        (MonoGHashTable         *hash_table,
+MONO_API guint     mono_g_hash_table_foreach_steal        (MonoGHashTable         *hash_table,
                                            GHRFunc         func,
                                            gpointer        user_data);
-gpointer    mono_g_hash_table_find (MonoGHashTable *hash_table,
+MONO_API gpointer    mono_g_hash_table_find (MonoGHashTable *hash_table,
                                                                        GHRFunc predicate,
                                                                        gpointer user_data);
-guint      mono_g_hash_table_size                 (MonoGHashTable         *hash_table);
+MONO_API guint     mono_g_hash_table_size                 (MonoGHashTable         *hash_table);
 
-void        mono_g_hash_table_remap (MonoGHashTable *hash_table,
+MONO_API void        mono_g_hash_table_remap (MonoGHashTable *hash_table,
                                                                         MonoGRemapperFunc func,
                                                                         gpointer user_data);
 
-void        mono_g_hash_table_print_stats (MonoGHashTable *table);
+MONO_API void        mono_g_hash_table_print_stats (MonoGHashTable *table);
 
 G_END_DECLS
 
index 0dc0b4b5d58f8918fd597deb3dc9cb413ed9aed6..199496a42eeee2dfa64e709910f73c9e7be8804e 100644 (file)
@@ -8,16 +8,16 @@
 #include <mono/metadata/object.h>
 
 typedef struct _MonoMList MonoMList;
-MonoMList*  mono_mlist_alloc       (MonoObject *data);
-MonoObject* mono_mlist_get_data    (MonoMList* list);
-void        mono_mlist_set_data    (MonoMList* list, MonoObject *data);
-MonoMList*  mono_mlist_set_next    (MonoMList* list, MonoMList *next);
-int         mono_mlist_length      (MonoMList* list);
-MonoMList*  mono_mlist_next        (MonoMList* list);
-MonoMList*  mono_mlist_last        (MonoMList* list);
-MonoMList*  mono_mlist_prepend     (MonoMList* list, MonoObject *data);
-MonoMList*  mono_mlist_append      (MonoMList* list, MonoObject *data);
-MonoMList*  mono_mlist_remove_item (MonoMList* list, MonoMList *item);
+MONO_API MonoMList*  mono_mlist_alloc       (MonoObject *data);
+MONO_API MonoObject* mono_mlist_get_data    (MonoMList* list);
+MONO_API void        mono_mlist_set_data    (MonoMList* list, MonoObject *data);
+MONO_API MonoMList*  mono_mlist_set_next    (MonoMList* list, MonoMList *next);
+MONO_API int         mono_mlist_length      (MonoMList* list);
+MONO_API MonoMList*  mono_mlist_next        (MonoMList* list);
+MONO_API MonoMList*  mono_mlist_last        (MonoMList* list);
+MONO_API MonoMList*  mono_mlist_prepend     (MonoMList* list, MonoObject *data);
+MONO_API MonoMList*  mono_mlist_append      (MonoMList* list, MonoObject *data);
+MONO_API MonoMList*  mono_mlist_remove_item (MonoMList* list, MonoMList *item);
 
 #endif /* __MONO_METADATA_MONO_MLIST_H__ */
 
index 40e542dfa61642aea95f69666c460f4611c35d55..a856c1cfa6d4da274df5dddbe1bdb0b468cf1363 100644 (file)
@@ -1584,7 +1584,7 @@ void
 mono_field_static_get_value_for_thread (MonoInternalThread *thread, MonoVTable *vt, MonoClassField *field, void *value) MONO_INTERNAL;
 
 /* exported, used by the debugger */
-void *
+MONO_API void *
 mono_vtable_get_static_field_data (MonoVTable *vt);
 
 char *
index dec04e059cf71c8980dcb2b8d77f57f0f4faa8e7..5c74a4aee6b8b5b69453b6a6ad80c6f7290f6bdd 100644 (file)
@@ -6050,6 +6050,7 @@ mono_object_to_string (MonoObject *obj, MonoObject **exc)
 {
        static MonoMethod *to_string = NULL;
        MonoMethod *method;
+       void *target = obj;
 
        g_assert (obj);
 
@@ -6058,7 +6059,12 @@ mono_object_to_string (MonoObject *obj, MonoObject **exc)
 
        method = mono_object_get_virtual_method (obj, to_string);
 
-       return (MonoString *) mono_runtime_invoke (method, obj, NULL, exc);
+       // Unbox value type if needed
+       if (mono_class_is_valuetype (mono_method_get_class (method))) {
+               target = mono_object_unbox (obj);
+       }
+
+       return (MonoString *) mono_runtime_invoke (method, target, NULL, exc);
 }
 
 /**
index e975298e88164f946290c40cd7e4badb65f1ecd5..70ff5814b323cb37e50fcdb9d870b2798bf17eef 100644 (file)
@@ -65,231 +65,231 @@ typedef void          (*MonoMainThreadFunc)    (void* user_data);
                mono_gc_wbarrier_arrayref_copy (__p, __s, (count));     \
        } while (0)
 
-mono_unichar2 *mono_string_chars  (MonoString *s);
-int            mono_string_length (MonoString *s);
+MONO_API mono_unichar2 *mono_string_chars  (MonoString *s);
+MONO_API int            mono_string_length (MonoString *s);
 
-MonoObject *
+MONO_API MonoObject *
 mono_object_new                    (MonoDomain *domain, MonoClass *klass);
 
-MonoObject *
+MONO_API MonoObject *
 mono_object_new_specific    (MonoVTable *vtable);
 
 /* can be used for classes without finalizer in non-profiling mode */
-MonoObject *
+MONO_API MonoObject *
 mono_object_new_fast       (MonoVTable *vtable);
 
-MonoObject *
+MONO_API MonoObject *
 mono_object_new_alloc_specific (MonoVTable *vtable);
 
-MonoObject *
+MONO_API MonoObject *
 mono_object_new_from_token  (MonoDomain *domain, MonoImage *image, uint32_t token);
 
-MonoArray*
+MONO_API MonoArray*
 mono_array_new             (MonoDomain *domain, MonoClass *eclass, uintptr_t n);
 
-MonoArray*
+MONO_API MonoArray*
 mono_array_new_full        (MonoDomain *domain, MonoClass *array_class,
                             uintptr_t *lengths, intptr_t *lower_bounds);
 
-MonoArray *
+MONO_API MonoArray *
 mono_array_new_specific            (MonoVTable *vtable, uintptr_t n);
 
-MonoArray*
+MONO_API MonoArray*
 mono_array_clone           (MonoArray *array);
 
-char*
+MONO_API char*
 mono_array_addr_with_size   (MonoArray *array, int size, uintptr_t idx);
 
-uintptr_t
+MONO_API uintptr_t
 mono_array_length           (MonoArray *array);
 
-MonoString*
+MONO_API MonoString*
 mono_string_new_utf16      (MonoDomain *domain, const mono_unichar2 *text, int32_t len);
 
-MonoString*
+MONO_API MonoString*
 mono_string_new_size       (MonoDomain *domain, int32_t len);
 
-MonoString*
+MONO_API MonoString*
 mono_ldstr                 (MonoDomain *domain, MonoImage *image, uint32_t str_index);
 
-MonoString*
+MONO_API MonoString*
 mono_string_is_interned            (MonoString *str);
 
-MonoString*
+MONO_API MonoString*
 mono_string_intern         (MonoString *str);
 
-MonoString*
+MONO_API MonoString*
 mono_string_new                    (MonoDomain *domain, const char *text);
 
-MonoString*
+MONO_API MonoString*
 mono_string_new_wrapper            (const char *text);
 
-MonoString*
+MONO_API MonoString*
 mono_string_new_len        (MonoDomain *domain, const char *text, unsigned int length);
 
-char *
+MONO_API char *
 mono_string_to_utf8        (MonoString *string_obj);
 
-char *
+MONO_API char *
 mono_string_to_utf8_checked (MonoString *string_obj, MonoError *error);
 
-mono_unichar2 *
+MONO_API mono_unichar2 *
 mono_string_to_utf16       (MonoString *string_obj);
 
-MonoString *
+MONO_API MonoString *
 mono_string_from_utf16     (mono_unichar2 *data);
 
-mono_bool
+MONO_API mono_bool
 mono_string_equal           (MonoString *s1, MonoString *s2);
 
-unsigned int
+MONO_API unsigned int
 mono_string_hash            (MonoString *s);
 
-int
+MONO_API int
 mono_object_hash            (MonoObject* obj);
 
-MonoString *
+MONO_API MonoString *
 mono_object_to_string (MonoObject *obj, MonoObject **exc);
 
-MonoObject *
+MONO_API MonoObject *
 mono_value_box             (MonoDomain *domain, MonoClass *klass, void* val);
 
-void
+MONO_API void
 mono_value_copy             (void* dest, void* src, MonoClass *klass);
 
-void
+MONO_API void
 mono_value_copy_array       (MonoArray *dest, int dest_idx, void* src, int count);
 
-MonoDomain*
+MONO_API MonoDomain*
 mono_object_get_domain      (MonoObject *obj);
 
-MonoClass*
+MONO_API MonoClass*
 mono_object_get_class       (MonoObject *obj);
 
-void*
+MONO_API void*
 mono_object_unbox          (MonoObject *obj);
 
-MonoObject *
+MONO_API MonoObject *
 mono_object_clone          (MonoObject *obj);
 
-MonoObject *
+MONO_API MonoObject *
 mono_object_isinst         (MonoObject *obj, MonoClass *klass);
 
-MonoObject *
+MONO_API MonoObject *
 mono_object_isinst_mbyref   (MonoObject *obj, MonoClass *klass);
 
-MonoObject *
+MONO_API MonoObject *
 mono_object_castclass_mbyref (MonoObject *obj, MonoClass *klass);
 
-mono_bool 
+MONO_API mono_bool 
 mono_monitor_try_enter       (MonoObject *obj, uint32_t ms);
 
-mono_bool
+MONO_API mono_bool
 mono_monitor_enter           (MonoObject *obj);
 
-unsigned int
+MONO_API unsigned int
 mono_object_get_size         (MonoObject *o);
 
-void 
+MONO_API void 
 mono_monitor_exit            (MonoObject *obj);
 
-void
+MONO_API void
 mono_raise_exception       (MonoException *ex);
 
-void
+MONO_API void
 mono_runtime_object_init    (MonoObject *this_obj);
 
-void
+MONO_API void
 mono_runtime_class_init            (MonoVTable *vtable);
 
-MonoMethod*
+MONO_API MonoMethod*
 mono_object_get_virtual_method (MonoObject *obj, MonoMethod *method);
 
-MonoObject*
+MONO_API MonoObject*
 mono_runtime_invoke        (MonoMethod *method, void *obj, void **params,
                             MonoObject **exc);
 
-MonoMethod *
+MONO_API MonoMethod *
 mono_get_delegate_invoke    (MonoClass *klass);
 
-MonoMethod *
+MONO_API MonoMethod *
 mono_get_delegate_begin_invoke (MonoClass *klass);
 
-MonoMethod *
+MONO_API MonoMethod *
 mono_get_delegate_end_invoke (MonoClass *klass);
 
-MonoObject*
+MONO_API MonoObject*
 mono_runtime_delegate_invoke (MonoObject *delegate, void **params, 
                              MonoObject **exc);
 
-MonoObject*
+MONO_API MonoObject*
 mono_runtime_invoke_array   (MonoMethod *method, void *obj, MonoArray *params,
                             MonoObject **exc);
 
-void*
+MONO_API void*
 mono_method_get_unmanaged_thunk (MonoMethod *method);
 
-MonoArray*
+MONO_API MonoArray*
 mono_runtime_get_main_args  (void);
 
-void
+MONO_API void
 mono_runtime_exec_managed_code (MonoDomain *domain,
                                MonoMainThreadFunc main_func,
                                void* main_args);
 
-int
+MONO_API int
 mono_runtime_run_main      (MonoMethod *method, int argc, char* argv[], 
                             MonoObject **exc);
 
-int
+MONO_API int
 mono_runtime_exec_main     (MonoMethod *method, MonoArray *args,
                             MonoObject **exc);
 
 /* The following functions won't be available with mono was configured with remoting disabled. */
 /*#ifndef DISABLE_REMOTING */
-void*
+MONO_API void*
 mono_load_remote_field (MonoObject *this_obj, MonoClass *klass, MonoClassField *field, void **res);
 
-MonoObject *
+MONO_API MonoObject *
 mono_load_remote_field_new (MonoObject *this_obj, MonoClass *klass, MonoClassField *field);
 
-void
+MONO_API void
 mono_store_remote_field (MonoObject *this_obj, MonoClass *klass, MonoClassField *field, void* val);
 
-void
+MONO_API void
 mono_store_remote_field_new (MonoObject *this_obj, MonoClass *klass, MonoClassField *field, MonoObject *arg);
 
 /* #endif */
 
-void
+MONO_API void
 mono_unhandled_exception    (MonoObject *exc);
 
-void
+MONO_API void
 mono_print_unhandled_exception (MonoObject *exc);
 
-void* 
+MONO_API void* 
 mono_compile_method       (MonoMethod *method);
 
 /* accessors for fields and properties */
-void
+MONO_API void
 mono_field_set_value (MonoObject *obj, MonoClassField *field, void *value);
 
-void
+MONO_API void
 mono_field_static_set_value (MonoVTable *vt, MonoClassField *field, void *value);
 
-void
+MONO_API void
 mono_field_get_value (MonoObject *obj, MonoClassField *field, void *value);
 
-void
+MONO_API void
 mono_field_static_get_value (MonoVTable *vt, MonoClassField *field, void *value);
 
-MonoObject *
+MONO_API MonoObject *
 mono_field_get_value_object (MonoDomain *domain, MonoClassField *field, MonoObject *obj);
 
-void
+MONO_API void
 mono_property_set_value (MonoProperty *prop, void *obj, void **params, MonoObject **exc);
 
-MonoObject*
+MONO_API MonoObject*
 mono_property_get_value (MonoProperty *prop, void *obj, void **params, MonoObject **exc);
 
 /* GC handles support 
@@ -306,19 +306,19 @@ mono_property_get_value (MonoProperty *prop, void *obj, void **params, MonoObjec
  * mono_gchandle_get_target () can be used to get the object referenced by both kinds
  * of handle: for a weakref handle, if an object has been collected, it will return NULL.
  */
-uint32_t      mono_gchandle_new         (MonoObject *obj, mono_bool pinned);
-uint32_t      mono_gchandle_new_weakref (MonoObject *obj, mono_bool track_resurrection);
-MonoObject*  mono_gchandle_get_target  (uint32_t gchandle);
-void         mono_gchandle_free        (uint32_t gchandle);
+MONO_API uint32_t      mono_gchandle_new         (MonoObject *obj, mono_bool pinned);
+MONO_API uint32_t      mono_gchandle_new_weakref (MonoObject *obj, mono_bool track_resurrection);
+MONO_API MonoObject*  mono_gchandle_get_target  (uint32_t gchandle);
+MONO_API void         mono_gchandle_free        (uint32_t gchandle);
 
 /* GC write barriers support */
-void mono_gc_wbarrier_set_field     (MonoObject *obj, void* field_ptr, MonoObject* value);
-void mono_gc_wbarrier_set_arrayref  (MonoArray *arr, void* slot_ptr, MonoObject* value);
-void mono_gc_wbarrier_arrayref_copy (void* dest_ptr, void* src_ptr, int count);
-void mono_gc_wbarrier_generic_store (void* ptr, MonoObject* value);
-void mono_gc_wbarrier_generic_nostore (void* ptr);
-void mono_gc_wbarrier_value_copy    (void* dest, void* src, int count, MonoClass *klass);
-void mono_gc_wbarrier_object_copy   (MonoObject* obj, MonoObject *src);
+MONO_API void mono_gc_wbarrier_set_field     (MonoObject *obj, void* field_ptr, MonoObject* value);
+MONO_API void mono_gc_wbarrier_set_arrayref  (MonoArray *arr, void* slot_ptr, MonoObject* value);
+MONO_API void mono_gc_wbarrier_arrayref_copy (void* dest_ptr, void* src_ptr, int count);
+MONO_API void mono_gc_wbarrier_generic_store (void* ptr, MonoObject* value);
+MONO_API void mono_gc_wbarrier_generic_nostore (void* ptr);
+MONO_API void mono_gc_wbarrier_value_copy    (void* dest, void* src, int count, MonoClass *klass);
+MONO_API void mono_gc_wbarrier_object_copy   (MonoObject* obj, MonoObject *src);
 
 MONO_END_DECLS
 
index 1c553f15b1d9c12ecb9ae8393dcf3f58ca3f616b..71b4cb495861d7f923827b6c07c23737b799a879 100644 (file)
@@ -64,10 +64,10 @@ typedef struct {
 
 extern const MonoOpcode mono_opcodes [];
 
-const char*
+MONO_API const char*
 mono_opcode_name (int opcode);
 
-MonoOpcodeEnum
+MONO_API MonoOpcodeEnum
 mono_opcode_value (const mono_byte **ip, const mono_byte *end);
 
 MONO_END_DECLS
old mode 100644 (file)
new mode 100755 (executable)
index 09299a7cfd7449ff68560bf6e781667375282ef0..c7b8f6d8a88463fad9c5be909cac96b5726ee3d1 100644 (file)
@@ -151,47 +151,47 @@ typedef void (*MonoProfilerCodeBufferNew) (MonoProfiler *prof, void* buffer, int
 /*
  * Function the profiler may call.
  */
-void mono_profiler_install       (MonoProfiler *prof, MonoProfileFunc shutdown_callback);
-void mono_profiler_set_events    (MonoProfileFlags events);
+MONO_API void mono_profiler_install       (MonoProfiler *prof, MonoProfileFunc shutdown_callback);
+MONO_API void mono_profiler_set_events    (MonoProfileFlags events);
 
-MonoProfileFlags mono_profiler_get_events (void);
+MONO_API MonoProfileFlags mono_profiler_get_events (void);
 
-void mono_profiler_install_appdomain   (MonoProfileAppDomainFunc start_load, MonoProfileAppDomainResult end_load,
+MONO_API void mono_profiler_install_appdomain   (MonoProfileAppDomainFunc start_load, MonoProfileAppDomainResult end_load,
                                         MonoProfileAppDomainFunc start_unload, MonoProfileAppDomainFunc end_unload);
-void mono_profiler_install_assembly    (MonoProfileAssemblyFunc start_load, MonoProfileAssemblyResult end_load,
+MONO_API void mono_profiler_install_assembly    (MonoProfileAssemblyFunc start_load, MonoProfileAssemblyResult end_load,
                                         MonoProfileAssemblyFunc start_unload, MonoProfileAssemblyFunc end_unload);
-void mono_profiler_install_module      (MonoProfileModuleFunc start_load, MonoProfileModuleResult end_load,
+MONO_API void mono_profiler_install_module      (MonoProfileModuleFunc start_load, MonoProfileModuleResult end_load,
                                         MonoProfileModuleFunc start_unload, MonoProfileModuleFunc end_unload);
-void mono_profiler_install_class       (MonoProfileClassFunc start_load, MonoProfileClassResult end_load,
+MONO_API void mono_profiler_install_class       (MonoProfileClassFunc start_load, MonoProfileClassResult end_load,
                                         MonoProfileClassFunc start_unload, MonoProfileClassFunc end_unload);
 
-void mono_profiler_install_jit_compile (MonoProfileMethodFunc start, MonoProfileMethodResult end);
-void mono_profiler_install_jit_end (MonoProfileJitResult end);
-void mono_profiler_install_method_free (MonoProfileMethodFunc callback);
-void mono_profiler_install_method_invoke (MonoProfileMethodFunc start, MonoProfileMethodFunc end);
-void mono_profiler_install_enter_leave (MonoProfileMethodFunc enter, MonoProfileMethodFunc fleave);
-void mono_profiler_install_thread      (MonoProfileThreadFunc start, MonoProfileThreadFunc end);
-void mono_profiler_install_thread_name (MonoProfileThreadNameFunc thread_name_cb);
-void mono_profiler_install_transition  (MonoProfileMethodResult callback);
-void mono_profiler_install_allocation  (MonoProfileAllocFunc callback);
-void mono_profiler_install_monitor     (MonoProfileMonitorFunc callback);
-void mono_profiler_install_statistical (MonoProfileStatFunc callback);
-void mono_profiler_install_statistical_call_chain (MonoProfileStatCallChainFunc callback, int call_chain_depth, MonoProfilerCallChainStrategy call_chain_strategy);
-void mono_profiler_install_exception   (MonoProfileExceptionFunc throw_callback, MonoProfileMethodFunc exc_method_leave, MonoProfileExceptionClauseFunc clause_callback);
-void mono_profiler_install_coverage_filter (MonoProfileCoverageFilterFunc callback);
-void mono_profiler_coverage_get  (MonoProfiler *prof, MonoMethod *method, MonoProfileCoverageFunc func);
-void mono_profiler_install_gc    (MonoProfileGCFunc callback, MonoProfileGCResizeFunc heap_resize_callback);
-void mono_profiler_install_gc_moves    (MonoProfileGCMoveFunc callback);
-void mono_profiler_install_gc_roots    (MonoProfileGCHandleFunc handle_callback, MonoProfileGCRootFunc roots_callback);
-void mono_profiler_install_runtime_initialized (MonoProfileFunc runtime_initialized_callback);
-
-void mono_profiler_install_code_chunk_new (MonoProfilerCodeChunkNew callback);
-void mono_profiler_install_code_chunk_destroy (MonoProfilerCodeChunkDestroy callback);
-void mono_profiler_install_code_buffer_new (MonoProfilerCodeBufferNew callback);
-
-void mono_profiler_install_iomap (MonoProfileIomapFunc callback);
-
-void mono_profiler_load             (const char *desc);
+MONO_API void mono_profiler_install_jit_compile (MonoProfileMethodFunc start, MonoProfileMethodResult end);
+MONO_API void mono_profiler_install_jit_end (MonoProfileJitResult end);
+MONO_API void mono_profiler_install_method_free (MonoProfileMethodFunc callback);
+MONO_API void mono_profiler_install_method_invoke (MonoProfileMethodFunc start, MonoProfileMethodFunc end);
+MONO_API void mono_profiler_install_enter_leave (MonoProfileMethodFunc enter, MonoProfileMethodFunc fleave);
+MONO_API void mono_profiler_install_thread      (MonoProfileThreadFunc start, MonoProfileThreadFunc end);
+MONO_API void mono_profiler_install_thread_name (MonoProfileThreadNameFunc thread_name_cb);
+MONO_API void mono_profiler_install_transition  (MonoProfileMethodResult callback);
+MONO_API void mono_profiler_install_allocation  (MonoProfileAllocFunc callback);
+MONO_API void mono_profiler_install_monitor     (MonoProfileMonitorFunc callback);
+MONO_API void mono_profiler_install_statistical (MonoProfileStatFunc callback);
+MONO_API void mono_profiler_install_statistical_call_chain (MonoProfileStatCallChainFunc callback, int call_chain_depth, MonoProfilerCallChainStrategy call_chain_strategy);
+MONO_API void mono_profiler_install_exception   (MonoProfileExceptionFunc throw_callback, MonoProfileMethodFunc exc_method_leave, MonoProfileExceptionClauseFunc clause_callback);
+MONO_API void mono_profiler_install_coverage_filter (MonoProfileCoverageFilterFunc callback);
+MONO_API void mono_profiler_coverage_get  (MonoProfiler *prof, MonoMethod *method, MonoProfileCoverageFunc func);
+MONO_API void mono_profiler_install_gc    (MonoProfileGCFunc callback, MonoProfileGCResizeFunc heap_resize_callback);
+MONO_API void mono_profiler_install_gc_moves    (MonoProfileGCMoveFunc callback);
+MONO_API void mono_profiler_install_gc_roots    (MonoProfileGCHandleFunc handle_callback, MonoProfileGCRootFunc roots_callback);
+MONO_API void mono_profiler_install_runtime_initialized (MonoProfileFunc runtime_initialized_callback);
+
+MONO_API void mono_profiler_install_code_chunk_new (MonoProfilerCodeChunkNew callback);
+MONO_API void mono_profiler_install_code_chunk_destroy (MonoProfilerCodeChunkDestroy callback);
+MONO_API void mono_profiler_install_code_buffer_new (MonoProfilerCodeBufferNew callback);
+
+MONO_API void mono_profiler_install_iomap (MonoProfileIomapFunc callback);
+
+MONO_API void mono_profiler_load             (const char *desc);
 
 MONO_END_DECLS
 
index 494a9a76216685d6999e76d46603f5effd33f8e4..0301342806f0fe51760da4024369520fc3f18f22 100644 (file)
@@ -41,44 +41,44 @@ typedef enum {
        ResolveTokenError_Other
 } MonoResolveTokenError;
 
-int           mono_reflection_parse_type (char *name, MonoTypeNameParse *info);
-MonoType*     mono_reflection_get_type   (MonoImage* image, MonoTypeNameParse *info, mono_bool ignorecase, mono_bool *type_resolve);
-void          mono_reflection_free_type_info (MonoTypeNameParse *info);
-MonoType*     mono_reflection_type_from_name (char *name, MonoImage *image);
-uint32_t      mono_reflection_get_token (MonoObject *obj);
-
-MonoReflectionAssembly* mono_assembly_get_object (MonoDomain *domain, MonoAssembly *assembly);
-MonoReflectionModule*   mono_module_get_object   (MonoDomain *domain, MonoImage *image);
-MonoReflectionModule*   mono_module_file_get_object (MonoDomain *domain, MonoImage *image, int table_index);
-MonoReflectionType*     mono_type_get_object     (MonoDomain *domain, MonoType *type);
-MonoReflectionMethod*   mono_method_get_object   (MonoDomain *domain, MonoMethod *method, MonoClass *refclass);
-MonoReflectionField*    mono_field_get_object    (MonoDomain *domain, MonoClass *klass, MonoClassField *field);
-MonoReflectionProperty* mono_property_get_object (MonoDomain *domain, MonoClass *klass, MonoProperty *property);
-MonoReflectionEvent*    mono_event_get_object    (MonoDomain *domain, MonoClass *klass, MonoEvent *event);
+MONO_API int           mono_reflection_parse_type (char *name, MonoTypeNameParse *info);
+MONO_API MonoType*     mono_reflection_get_type   (MonoImage* image, MonoTypeNameParse *info, mono_bool ignorecase, mono_bool *type_resolve);
+MONO_API void          mono_reflection_free_type_info (MonoTypeNameParse *info);
+MONO_API MonoType*     mono_reflection_type_from_name (char *name, MonoImage *image);
+MONO_API uint32_t      mono_reflection_get_token (MonoObject *obj);
+
+MONO_API MonoReflectionAssembly* mono_assembly_get_object (MonoDomain *domain, MonoAssembly *assembly);
+MONO_API MonoReflectionModule*   mono_module_get_object   (MonoDomain *domain, MonoImage *image);
+MONO_API MonoReflectionModule*   mono_module_file_get_object (MonoDomain *domain, MonoImage *image, int table_index);
+MONO_API MonoReflectionType*     mono_type_get_object     (MonoDomain *domain, MonoType *type);
+MONO_API MonoReflectionMethod*   mono_method_get_object   (MonoDomain *domain, MonoMethod *method, MonoClass *refclass);
+MONO_API MonoReflectionField*    mono_field_get_object    (MonoDomain *domain, MonoClass *klass, MonoClassField *field);
+MONO_API MonoReflectionProperty* mono_property_get_object (MonoDomain *domain, MonoClass *klass, MonoProperty *property);
+MONO_API MonoReflectionEvent*    mono_event_get_object    (MonoDomain *domain, MonoClass *klass, MonoEvent *event);
 /* note: this one is slightly different: we keep the whole array of params in the cache */
-MonoArray* mono_param_get_objects  (MonoDomain *domain, MonoMethod *method);
-MonoReflectionMethodBody* mono_method_body_get_object (MonoDomain *domain, MonoMethod *method);
-
-MonoObject *mono_get_dbnull_object (MonoDomain *domain);
-
-MonoArray*  mono_reflection_get_custom_attrs_by_type (MonoObject *obj, MonoClass *attr_klass, MonoError *error);
-MonoArray*  mono_reflection_get_custom_attrs (MonoObject *obj);
-MonoArray*  mono_reflection_get_custom_attrs_data (MonoObject *obj);
-MonoArray*  mono_reflection_get_custom_attrs_blob (MonoReflectionAssembly *assembly, MonoObject *ctor, MonoArray *ctorArgs, MonoArray *properties, MonoArray *porpValues, MonoArray *fields, MonoArray* fieldValues);
-
-MonoCustomAttrInfo* mono_reflection_get_custom_attrs_info (MonoObject *obj);
-MonoArray*  mono_custom_attrs_construct (MonoCustomAttrInfo *cinfo);
-MonoCustomAttrInfo* mono_custom_attrs_from_index    (MonoImage *image, uint32_t idx);
-MonoCustomAttrInfo* mono_custom_attrs_from_method   (MonoMethod *method);
-MonoCustomAttrInfo* mono_custom_attrs_from_class    (MonoClass *klass);
-MonoCustomAttrInfo* mono_custom_attrs_from_assembly (MonoAssembly *assembly);
-MonoCustomAttrInfo* mono_custom_attrs_from_property (MonoClass *klass, MonoProperty *property);
-MonoCustomAttrInfo* mono_custom_attrs_from_event    (MonoClass *klass, MonoEvent *event);
-MonoCustomAttrInfo* mono_custom_attrs_from_field    (MonoClass *klass, MonoClassField *field);
-MonoCustomAttrInfo* mono_custom_attrs_from_param    (MonoMethod *method, uint32_t param);
-mono_bool           mono_custom_attrs_has_attr      (MonoCustomAttrInfo *ainfo, MonoClass *attr_klass);
-MonoObject*         mono_custom_attrs_get_attr      (MonoCustomAttrInfo *ainfo, MonoClass *attr_klass);
-void                mono_custom_attrs_free          (MonoCustomAttrInfo *ainfo);
+MONO_API MonoArray* mono_param_get_objects  (MonoDomain *domain, MonoMethod *method);
+MONO_API MonoReflectionMethodBody* mono_method_body_get_object (MonoDomain *domain, MonoMethod *method);
+
+MONO_API MonoObject *mono_get_dbnull_object (MonoDomain *domain);
+
+MONO_API MonoArray*  mono_reflection_get_custom_attrs_by_type (MonoObject *obj, MonoClass *attr_klass, MonoError *error);
+MONO_API MonoArray*  mono_reflection_get_custom_attrs (MonoObject *obj);
+MONO_API MonoArray*  mono_reflection_get_custom_attrs_data (MonoObject *obj);
+MONO_API MonoArray*  mono_reflection_get_custom_attrs_blob (MonoReflectionAssembly *assembly, MonoObject *ctor, MonoArray *ctorArgs, MonoArray *properties, MonoArray *porpValues, MonoArray *fields, MonoArray* fieldValues);
+
+MONO_API MonoCustomAttrInfo* mono_reflection_get_custom_attrs_info (MonoObject *obj);
+MONO_API MonoArray*  mono_custom_attrs_construct (MonoCustomAttrInfo *cinfo);
+MONO_API MonoCustomAttrInfo* mono_custom_attrs_from_index    (MonoImage *image, uint32_t idx);
+MONO_API MonoCustomAttrInfo* mono_custom_attrs_from_method   (MonoMethod *method);
+MONO_API MonoCustomAttrInfo* mono_custom_attrs_from_class    (MonoClass *klass);
+MONO_API MonoCustomAttrInfo* mono_custom_attrs_from_assembly (MonoAssembly *assembly);
+MONO_API MonoCustomAttrInfo* mono_custom_attrs_from_property (MonoClass *klass, MonoProperty *property);
+MONO_API MonoCustomAttrInfo* mono_custom_attrs_from_event    (MonoClass *klass, MonoEvent *event);
+MONO_API MonoCustomAttrInfo* mono_custom_attrs_from_field    (MonoClass *klass, MonoClassField *field);
+MONO_API MonoCustomAttrInfo* mono_custom_attrs_from_param    (MonoMethod *method, uint32_t param);
+MONO_API mono_bool           mono_custom_attrs_has_attr      (MonoCustomAttrInfo *ainfo, MonoClass *attr_klass);
+MONO_API MonoObject*         mono_custom_attrs_get_attr      (MonoCustomAttrInfo *ainfo, MonoClass *attr_klass);
+MONO_API void                mono_custom_attrs_free          (MonoCustomAttrInfo *ainfo);
 
 
 #define MONO_DECLSEC_ACTION_MIN                0x1
@@ -105,9 +105,9 @@ enum {
        MONO_DECLSEC_FLAG_DEMAND_CHOICE                 = 0x00020000
 };
 
-uint32_t mono_declsec_flags_from_method (MonoMethod *method);
-uint32_t mono_declsec_flags_from_class (MonoClass *klass);
-uint32_t mono_declsec_flags_from_assembly (MonoAssembly *assembly);
+MONO_API uint32_t mono_declsec_flags_from_method (MonoMethod *method);
+MONO_API uint32_t mono_declsec_flags_from_class (MonoClass *klass);
+MONO_API uint32_t mono_declsec_flags_from_assembly (MonoAssembly *assembly);
 
 /* this structure MUST be kept in synch with RuntimeDeclSecurityEntry
  * located in /mcs/class/corlib/System.Security/SecurityFrame.cs */
@@ -123,16 +123,16 @@ typedef struct {
        MonoDeclSecurityEntry demandchoice;
 } MonoDeclSecurityActions;
 
-MonoBoolean mono_declsec_get_demands (MonoMethod *callee, MonoDeclSecurityActions* demands);
-MonoBoolean mono_declsec_get_linkdemands (MonoMethod *callee, MonoDeclSecurityActions* klass, MonoDeclSecurityActions* cmethod);
-MonoBoolean mono_declsec_get_inheritdemands_class (MonoClass *klass, MonoDeclSecurityActions* demands);
-MonoBoolean mono_declsec_get_inheritdemands_method (MonoMethod *callee, MonoDeclSecurityActions* demands);
+MONO_API MonoBoolean mono_declsec_get_demands (MonoMethod *callee, MonoDeclSecurityActions* demands);
+MONO_API MonoBoolean mono_declsec_get_linkdemands (MonoMethod *callee, MonoDeclSecurityActions* klass, MonoDeclSecurityActions* cmethod);
+MONO_API MonoBoolean mono_declsec_get_inheritdemands_class (MonoClass *klass, MonoDeclSecurityActions* demands);
+MONO_API MonoBoolean mono_declsec_get_inheritdemands_method (MonoMethod *callee, MonoDeclSecurityActions* demands);
 
-MonoBoolean mono_declsec_get_method_action (MonoMethod *method, uint32_t action, MonoDeclSecurityEntry *entry);
-MonoBoolean mono_declsec_get_class_action (MonoClass *klass, uint32_t action, MonoDeclSecurityEntry *entry);
-MonoBoolean mono_declsec_get_assembly_action (MonoAssembly *assembly, uint32_t action, MonoDeclSecurityEntry *entry);
+MONO_API MonoBoolean mono_declsec_get_method_action (MonoMethod *method, uint32_t action, MonoDeclSecurityEntry *entry);
+MONO_API MonoBoolean mono_declsec_get_class_action (MonoClass *klass, uint32_t action, MonoDeclSecurityEntry *entry);
+MONO_API MonoBoolean mono_declsec_get_assembly_action (MonoAssembly *assembly, uint32_t action, MonoDeclSecurityEntry *entry);
 
-MonoType* mono_reflection_type_get_type (MonoReflectionType *reftype);
+MONO_API MonoType* mono_reflection_type_get_type (MonoReflectionType *reftype);
 
 MONO_END_DECLS
 
index 96407dadf282cc6630f7e99f7045be140568d9be..126a48da2c75810b374ade2ef2064f9030df4ee4 100644 (file)
@@ -56,9 +56,9 @@ extern MonoSecurityCoreCLRLevel mono_security_core_clr_method_level (MonoMethod
 extern gboolean mono_security_core_clr_is_platform_image (MonoImage *image) MONO_INTERNAL;
 extern gboolean mono_security_core_clr_determine_platform_image (MonoImage *image) MONO_INTERNAL;
 
-extern gboolean mono_security_core_clr_require_elevated_permissions (void);
+extern MONO_API gboolean mono_security_core_clr_require_elevated_permissions (void);
 
-extern void mono_security_core_clr_set_options (MonoSecurityCoreCLROptions options);
-extern MonoSecurityCoreCLROptions mono_security_core_clr_get_options (void);
+extern MONO_API void mono_security_core_clr_set_options (MonoSecurityCoreCLROptions options);
+extern MONO_API MonoSecurityCoreCLROptions mono_security_core_clr_get_options (void);
 
 #endif /* _MONO_METADATA_SECURITY_CORE_CLR_H_ */
old mode 100644 (file)
new mode 100755 (executable)
index 8a2fa73..741d757
 #ifdef MONO_ARCH_HAS_MONO_CONTEXT
 #define USE_MONO_CTX
 #else
-#ifdef _MSC_VER
-#define ARCH_STORE_REGS(ptr) __asm {   \
-               __asm mov [ptr], edi \
-               __asm mov [ptr+4], esi \
-               __asm mov [ptr+8], ebx \
-               __asm mov [ptr+12], edx \
-               __asm mov [ptr+16], ecx \
-               __asm mov [ptr+20], eax \
-               __asm mov [ptr+24], ebp \
-               __asm mov [ptr+28], esp \
-       }
-#else
-#define ARCH_STORE_REGS(ptr)   \
-       __asm__ __volatile__(   \
-               "mov %%edi,0(%0)\n"     \
-               "mov %%esi,4(%0)\n"     \
-               "mov %%ebx,8(%0)\n"     \
-               "mov %%edx,12(%0)\n"    \
-               "mov %%ecx,16(%0)\n"    \
-               "mov %%eax,20(%0)\n"    \
-               "mov %%ebp,24(%0)\n"    \
-               "mov %%esp,28(%0)\n"    \
-               :                       \
-               : "r" (ptr)     \
-       )
-#endif
+#error 0
 #endif
 
 /*FIXME, move this to mono-sigcontext as this is generaly useful.*/
index affe3b06729e1ffef9ebd0dc3813694b64d4708a..f19977ec37b64cb19dd5982ce2ac680d53e9a5c9 100644 (file)
@@ -3263,6 +3263,9 @@ major_do_collection (const char *reason)
        TV_DECLARE (all_btv);
        int old_next_pin_slot;
 
+       if (disable_major_collections)
+               return FALSE;
+
        if (major_collector.get_and_reset_num_major_objects_marked) {
                long long num_marked = major_collector.get_and_reset_num_major_objects_marked ();
                g_assert (!num_marked);
@@ -3284,13 +3287,15 @@ major_do_collection (const char *reason)
        return bytes_pinned_from_failed_allocation > 0;
 }
 
-static gboolean major_do_collection (const char *reason);
-
 static void
 major_start_concurrent_collection (const char *reason)
 {
-       long long num_objects_marked = major_collector.get_and_reset_num_major_objects_marked ();
+       long long num_objects_marked;
 
+       if (disable_major_collections)
+               return;
+
+       num_objects_marked = major_collector.get_and_reset_num_major_objects_marked ();
        g_assert (num_objects_marked == 0);
 
        MONO_GC_CONCURRENT_START_BEGIN (GENERATION_OLD);
index deba1d93aefe4dc1736cf8192065855098c6389d..7d442497a9168449e9e8415afdfe9a71911bac90 100644 (file)
@@ -72,11 +72,46 @@ NurseryClearPolicy sgen_get_nursery_clear_policy (void) MONO_INTERNAL;
  */
 struct _SgenThreadInfo {
        MonoThreadInfo info;
+       /*
+       This is set to TRUE when STW fails to suspend a thread, most probably because the
+       underlying thread is dead.
+       */
        int skip;
        volatile int in_critical_region;
+
+       /*
+       Since threads can be created concurrently during STW, it's possible to reach a stable
+       state where we find that the world is stopped but there are registered threads that have
+       not been suspended.
+
+       Our hope is that those threads are harmlesly blocked in the GC lock trying to finish registration.
+
+       To handle this scenario we set this field on each thread that have joined the current STW phase.
+       The GC should ignore unjoined threads.
+       */
        gboolean joined_stw;
+
+       /*
+       This is set to TRUE by STW when it initiates suspension of a thread.
+       It's used so async suspend can catch the case where a thread is in the middle of unregistering
+       and need to cooperatively suspend itself.
+       */
        gboolean doing_handshake;
+
+       /*
+       This is set to TRUE when a thread start to dettach.
+       This gives STW the oportunity to ignore a thread that started to
+       unregister.
+       */
        gboolean thread_is_dying;
+
+       /*
+       This is set the argument of mono_gc_set_skip_thread.
+
+       A thread that knowingly holds no managed state can call this
+       function around blocking loops to reduce the GC burden by not
+       been scanned.
+       */
        gboolean gc_disabled;
        void *stack_end;
        void *stack_start;
@@ -90,11 +125,13 @@ struct _SgenThreadInfo {
        /* Only used on POSIX platforms */
        int signal;
        /* Ditto */
-       unsigned int stop_count; /* to catch duplicate signals */
+       /* FIXME: kill this, we only use signals on systems that have rt-posix, which doesn't have issues with duplicates. */
+       unsigned int stop_count; /* to catch duplicate signals. */
 
        gpointer stopped_ip;    /* only valid if the thread is stopped */
-       MonoDomain *stopped_domain; /* ditto */
+       MonoDomain *stopped_domain; /* dsto */
 
+       /*FIXME pretty please finish killing ARCH_NUM_REGS */
 #ifdef USE_MONO_CTX
        MonoContext ctx;                /* ditto */
 #else
index b273a5ab822bd0cf5f35c3a3590f6c5836723fff..5d51db7d8671de70ed44d642d4065b57a8c640f3 100644 (file)
@@ -568,7 +568,11 @@ sgen_los_object_size (LOSObject *obj)
 LOSObject*
 sgen_los_header_for_object (char *data)
 {
+#if _MSC_VER
+       return (LOSObject*)(data - (int)(&(((LOSObject*)0)->data)));
+#else
        return (LOSObject*)(data - sizeof (LOSObject));
+#endif
 }
 
 void
old mode 100644 (file)
new mode 100755 (executable)
index 69e0d56..23e03b7
@@ -1893,6 +1893,14 @@ major_have_computer_minor_collection_allowance (void)
                void **empty_block_arr;
                void **rebuild_next;
 
+#ifdef TARGET_WIN32
+               /*
+                * sgen_free_os_memory () asserts in mono_vfree () because windows doesn't like freeing the middle of
+                * a VirtualAlloc ()-ed block.
+                */
+               return;
+#endif
+
                if (num_empty_blocks <= section_reserve)
                        return;
                SGEN_ASSERT (0, num_empty_blocks > 0, "section reserve can't be negative");
index 7dc35fdbe3e88d61c372dd6aa97612c931b72960..96cb905011585634774180a7a0c3c4529010ced3 100644 (file)
@@ -215,7 +215,7 @@ log_timming (GGTimingInfo *info)
        full_timing_buff [0] = '\0';
 
        if (!info->is_overflow)
-               sprintf (full_timing_buff, "total %.2fms, bridge %.2f", info->stw_time / 1000.0f, (int)info->bridge_time / 1000.0f);
+               sprintf (full_timing_buff, "total %.2fms, bridge %.2fms", info->stw_time / 1000.0f, (int)info->bridge_time / 1000.0f);
        if (info->generation == GENERATION_OLD)
                mono_trace (G_LOG_LEVEL_INFO, MONO_TRACE_GC, "GC_MAJOR%s: (%s) pause %.2fms, %s major %dK/%dK los %dK/%dK",
                        info->is_overflow ? "_OVERFLOW" : "",
index 64be03ffa924aa46feca20f246d1c9b48b5c9d5d..15f7afa1b0d378d87533a6c0188486735a27e8a2 100644 (file)
@@ -57,7 +57,14 @@ suspend_thread (SgenThreadInfo *info, void *context)
 #endif
        gpointer stack_start;
 
-       g_assert (info->doing_handshake);
+       /*
+        * It's possible that a dying thread is parked via
+        * sgen_park_current_thread_if_doing_handshake(), and, while parked, STW tries to
+        * suspend it again.  In that case doing_handshake will not be set anymore, and the
+        * "nested" suspend must be ignored.
+        */
+       if (!info->doing_handshake)
+               return;
 
        info->stopped_domain = mono_domain_get ();
        info->stopped_ip = context ? (gpointer) ARCH_SIGCTX_IP (context) : NULL;
old mode 100644 (file)
new mode 100755 (executable)
index a476c73..760e3eb
@@ -60,6 +60,17 @@ sgen_suspend_thread (SgenThreadInfo *info)
        info->stopped_ip = (gpointer)context.Eip;
        info->stack_start = (char*)context.Esp - REDZONE_SIZE;
 
+#ifdef USE_MONO_CTX
+       memset (&info->ctx, 0, sizeof (MonoContext));
+       info->ctx.edi = context.Edi;
+       info->ctx.esi = context.Esi;
+       info->ctx.ebx = context.Ebx;
+       info->ctx.edx = context.Edx;
+       info->ctx.ecx = context.Ecx;
+       info->ctx.eax = context.Eax;
+       info->ctx.ebp = context.Ebp;
+       info->ctx.esp = context.Esp;
+#else
        info->regs [0] = context.Edi;
        info->regs [1] = context.Esi;
        info->regs [2] = context.Ebx;
@@ -68,6 +79,7 @@ sgen_suspend_thread (SgenThreadInfo *info)
        info->regs [5] = context.Eax;
        info->regs [6] = context.Ebp;
        info->regs [7] = context.Esp;
+#endif
 
        /* Notify the JIT */
        if (mono_gc_get_gc_callbacks ()->thread_suspend_func)
old mode 100644 (file)
new mode 100755 (executable)
index eb24a35..a72d76a
@@ -58,7 +58,7 @@ static void
 update_current_thread_stack (void *start)
 {
        int stack_guard = 0;
-#ifndef USE_MONO_CTX
+#if !defined(USE_MONO_CTX)
        void *reg_ptr = cur_thread_regs;
 #endif
        SgenThreadInfo *info = mono_thread_info_current ();
index 811c2852045508e0e56656b8287d9b27b2a79d71..32b914db0d692ab8d597f6440540994436b2aa15 100644 (file)
@@ -89,7 +89,7 @@ typedef struct {
 
        gint event_system;
        gpointer event_data;
-       void (*modify) (gpointer event_data, int fd, int operation, int events, gboolean is_new);
+       void (*modify) (gpointer p, int fd, int operation, int events, gboolean is_new);
        void (*wait) (gpointer sock_data);
        void (*shutdown) (gpointer event_data);
 } SocketIOData;
@@ -152,6 +152,7 @@ static void socket_io_cleanup (SocketIOData *data);
 static MonoObject *get_io_event (MonoMList **list, gint event);
 static int get_events_from_list (MonoMList *list);
 static int get_event_from_state (MonoSocketAsyncResult *state);
+static void check_for_interruption_critical (void);
 
 static MonoClass *async_call_klass;
 static MonoClass *socket_async_call_klass;
@@ -557,8 +558,7 @@ socket_io_add (MonoAsyncResult *ares, MonoSocketAsyncResult *state)
 
        mono_g_hash_table_replace (data->sock_to_state, state->handle, list);
        ievt = get_events_from_list (list);
-       LeaveCriticalSection (&data->io_lock);
-       data->modify (data->event_data, fd, state->operation, ievt, is_new);
+       data->modify (data, fd, state->operation, ievt, is_new);
 }
 
 #ifndef DISABLE_SOCKETS
@@ -1391,26 +1391,63 @@ should_i_die (ThreadPool *tp)
        return result;
 }
 
+static void
+set_tp_thread_info (ThreadPool *tp)
+{
+       const gchar *name;
+       MonoInternalThread *thread = mono_thread_internal_current ();
+
+       mono_profiler_thread_start (thread->tid);
+       name = (tp->is_io) ? "IO Threadpool worker" : "Threadpool worker";
+       mono_thread_set_name_internal (thread, mono_string_new (mono_domain_get (), name), FALSE);
+}
+
+static void
+clear_thread_state (void)
+{
+       MonoInternalThread *thread = mono_thread_internal_current ();
+       /* If the callee changes the background status, set it back to TRUE */
+       mono_thread_clr_state (thread , ~ThreadState_Background);
+       if (!mono_thread_test_state (thread , ThreadState_Background))
+               ves_icall_System_Threading_Thread_SetState (thread, ThreadState_Background);
+}
+
+static void
+check_for_interruption_critical (void)
+{
+       MonoInternalThread *thread;
+       /*RULE NUMBER ONE OF SKIP_THREAD: NEVER POKE MANAGED STATE.*/
+       mono_gc_set_skip_thread (FALSE);
+
+       thread = mono_thread_internal_current ();
+       if (THREAD_WANTS_A_BREAK (thread))
+               mono_thread_interruption_checkpoint ();
+
+       /*RULE NUMBER TWO OF SKIP_THREAD: READ RULE NUMBER ONE.*/
+       mono_gc_set_skip_thread (TRUE);
+}
+
+static void
+fire_profiler_thread_end (void)
+{
+       MonoInternalThread *thread = mono_thread_internal_current ();
+       mono_profiler_thread_end (thread->tid);
+}
+
 static void
 async_invoke_thread (gpointer data)
 {
        MonoDomain *domain;
-       MonoInternalThread *thread;
        MonoWSQ *wsq;
        ThreadPool *tp;
        gboolean must_die;
-       const gchar *name;
   
        tp = data;
        wsq = NULL;
        if (!tp->is_io)
                wsq = add_wsq ();
 
-       thread = mono_thread_internal_current ();
-
-       mono_profiler_thread_start (thread->tid);
-       name = (tp->is_io) ? "IO Threadpool worker" : "Threadpool worker";
-       mono_thread_set_name_internal (thread, mono_string_new (mono_domain_get (), name), FALSE);
+       set_tp_thread_info (tp);
 
        if (tp_start_func)
                tp_start_func (tp_hooks_user_data);
@@ -1492,10 +1529,7 @@ async_invoke_thread (gpointer data)
                                }
                                mono_thread_pop_appdomain_ref ();
                                InterlockedDecrement (&tp->busy_threads);
-                               /* If the callee changes the background status, set it back to TRUE */
-                               mono_thread_clr_state (thread , ~ThreadState_Background);
-                               if (!mono_thread_test_state (thread , ThreadState_Background))
-                                       ves_icall_System_Threading_Thread_SetState (thread, ThreadState_Background);
+                               clear_thread_state ();
                        }
                }
 
@@ -1528,8 +1562,7 @@ async_invoke_thread (gpointer data)
 #endif
                                if (mono_runtime_is_shutting_down ())
                                        break;
-                               if (THREAD_WANTS_A_BREAK (thread))
-                                       mono_thread_interruption_checkpoint ();
+                               check_for_interruption_critical ();
                        }
                        InterlockedDecrement (&tp->waiting);
 
@@ -1566,7 +1599,7 @@ async_invoke_thread (gpointer data)
                                                remove_wsq (wsq);
                                        }
 
-                                       mono_profiler_thread_end (thread->tid);
+                                       fire_profiler_thread_end ();
 
                                        if (tp_finish_func)
                                                tp_finish_func (tp_hooks_user_data);
index 811924b97cc46dd79d8fb9bb20ae14c4bcd3ee20..81cea4ce1d4949a0ada48859baefa11d61124ccb 100644 (file)
@@ -47,10 +47,10 @@ ves_icall_System_Threading_ThreadPool_SetMaxThreads (gint workerThreads,
                                                                gint completionPortThreads) MONO_INTERNAL;
 
 typedef void  (*MonoThreadPoolFunc) (gpointer user_data);
-void mono_install_threadpool_thread_hooks (MonoThreadPoolFunc start_func, MonoThreadPoolFunc finish_func, gpointer user_data);
+MONO_API void mono_install_threadpool_thread_hooks (MonoThreadPoolFunc start_func, MonoThreadPoolFunc finish_func, gpointer user_data);
 
 typedef void  (*MonoThreadPoolItemFunc) (gpointer user_data);
-void mono_install_threadpool_item_hooks (MonoThreadPoolItemFunc begin_func, MonoThreadPoolItemFunc end_func, gpointer user_data);
+MONO_API void mono_install_threadpool_item_hooks (MonoThreadPoolItemFunc begin_func, MonoThreadPoolItemFunc end_func, gpointer user_data);
 
 #endif
 
index 8ebc5391834d540665ca04f640816945ff855c0b..c430d62e982f69b3f423d38e815145988705b61e 100644 (file)
@@ -187,7 +187,7 @@ void mono_threads_set_shutting_down (void) MONO_INTERNAL;
 
 gunichar2* mono_thread_get_name (MonoInternalThread *this_obj, guint32 *name_len) MONO_INTERNAL;
 
-MonoException* mono_thread_get_undeniable_exception (void);
+MONO_API MonoException* mono_thread_get_undeniable_exception (void);
 
 MonoException* mono_thread_get_and_clear_pending_exception (void) MONO_INTERNAL;
 
old mode 100644 (file)
new mode 100755 (executable)
index 2f7e365..8f7f047
@@ -814,10 +814,12 @@ mono_thread_create (MonoDomain *domain, gpointer func, gpointer arg)
 static __inline__ __attribute__((always_inline))
 /* This is not defined by gcc */
 unsigned long long
-__readfsdword (unsigned long long offset)
+__readfsdword (unsigned long offset)
 {
-       unsigned long long value;
-       __asm__("movl %%fs:%a[offset], %k[value]" : [value] "=q" (value) : [offset] "irm" (offset));
+       unsigned long value;
+       //      __asm__("movl %%fs:%a[offset], %k[value]" : [value] "=q" (value) : [offset] "irm" (offset));
+   __asm__ volatile ("movl    %%fs:%1,%0"
+     : "=r" (value) ,"=m" ((*(volatile long *) offset)));
        return value;
 }
 #endif
index 2678789b6e6c2cc7d4c1d873b1f3b85eb7efe779..ab3f6cba7ddaa36859279b8bb04c410388a35809 100644 (file)
@@ -20,33 +20,33 @@ MONO_BEGIN_DECLS
 /* This callback should return TRUE if the runtime must wait for the thread, FALSE otherwise */
 typedef mono_bool (*MonoThreadManageCallback) (MonoThread* thread);
 
-extern void mono_thread_init (MonoThreadStartCB start_cb,
+extern MONO_API void mono_thread_init (MonoThreadStartCB start_cb,
                              MonoThreadAttachCB attach_cb);
-extern void mono_thread_cleanup (void);
-extern void mono_thread_manage(void);
+extern MONO_API void mono_thread_cleanup (void);
+extern MONO_API void mono_thread_manage(void);
 
-extern MonoThread *mono_thread_current (void);
+extern MONO_API MonoThread *mono_thread_current (void);
 
-extern void        mono_thread_set_main (MonoThread *thread);
-extern MonoThread *mono_thread_get_main (void);
+extern MONO_API void        mono_thread_set_main (MonoThread *thread);
+extern MONO_API MonoThread *mono_thread_get_main (void);
 
-extern void mono_thread_stop (MonoThread *thread);
+extern MONO_API void mono_thread_stop (MonoThread *thread);
 
-extern void mono_thread_new_init (intptr_t tid, void* stack_start,
+extern MONO_API void mono_thread_new_init (intptr_t tid, void* stack_start,
                                  void* func);
-extern void mono_thread_create (MonoDomain *domain, void* func, void* arg);
-extern MonoThread *mono_thread_attach (MonoDomain *domain);
-extern void mono_thread_detach (MonoThread *thread);
-extern void mono_thread_exit (void);
+extern MONO_API void mono_thread_create (MonoDomain *domain, void* func, void* arg);
+extern MONO_API MonoThread *mono_thread_attach (MonoDomain *domain);
+extern MONO_API void mono_thread_detach (MonoThread *thread);
+extern MONO_API void mono_thread_exit (void);
 
-void     mono_thread_set_manage_callback (MonoThread *thread, MonoThreadManageCallback func);
+MONO_API void     mono_thread_set_manage_callback (MonoThread *thread, MonoThreadManageCallback func);
 
-extern void mono_threads_set_default_stacksize (uint32_t stacksize);
-extern uint32_t mono_threads_get_default_stacksize (void);
+extern MONO_API void mono_threads_set_default_stacksize (uint32_t stacksize);
+extern MONO_API uint32_t mono_threads_get_default_stacksize (void);
 
-void mono_threads_request_thread_dump (void);
+MONO_API void mono_threads_request_thread_dump (void);
 
-mono_bool mono_thread_is_foreign (MonoThread *thread);
+MONO_API mono_bool mono_thread_is_foreign (MonoThread *thread);
 
 MONO_END_DECLS
 
index a82afefadf1521df3f9763cb665dd299681d8fd9..876a82bc07bff45490a716f78bce24876feff78f 100644 (file)
@@ -15,7 +15,7 @@ struct _tp_epoll_data {
 };
 
 typedef struct _tp_epoll_data tp_epoll_data;
-static void tp_epoll_modify (gpointer event_data, int fd, int operation, int events, gboolean is_new);
+static void tp_epoll_modify (gpointer p, int fd, int operation, int events, gboolean is_new);
 static void tp_epoll_shutdown (gpointer event_data);
 static void tp_epoll_wait (gpointer event_data);
 
@@ -51,12 +51,16 @@ tp_epoll_init (SocketIOData *data)
 }
 
 static void
-tp_epoll_modify (gpointer event_data, int fd, int operation, int events, gboolean is_new)
+tp_epoll_modify (gpointer p, int fd, int operation, int events, gboolean is_new)
 {
-       tp_epoll_data *data = event_data;
+       SocketIOData *socket_io_data;
+       tp_epoll_data *data;
        struct epoll_event evt;
        int epoll_op;
 
+       socket_io_data = p;
+       data = socket_io_data->event_data;
+
        memset (&evt, 0, sizeof (evt));
        evt.data.fd = fd;
        if ((events & MONO_POLLIN) != 0)
@@ -74,6 +78,7 @@ tp_epoll_modify (gpointer event_data, int fd, int operation, int events, gboolea
                        }
                }
        }
+       LeaveCriticalSection (&socket_io_data->io_lock);
 }
 
 static void
@@ -92,7 +97,6 @@ tp_epoll_wait (gpointer p)
 {
        SocketIOData *socket_io_data;
        int epollfd;
-       MonoInternalThread *thread;
        struct epoll_event *events, *evt;
        int ready = 0, i;
        gpointer async_results [EPOLL_NEVENTS * 2]; // * 2 because each loop can add up to 2 results here
@@ -102,7 +106,6 @@ tp_epoll_wait (gpointer p)
        socket_io_data = p;
        data = socket_io_data->event_data;
        epollfd = data->epollfd;
-       thread = mono_thread_internal_current ();
        events = g_new0 (struct epoll_event, EPOLL_NEVENTS);
 
        while (1) {
@@ -110,8 +113,7 @@ tp_epoll_wait (gpointer p)
 
                do {
                        if (ready == -1) {
-                               if (THREAD_WANTS_A_BREAK (thread))
-                                       mono_thread_interruption_checkpoint ();
+                               check_for_interruption_critical ();
                        }
                        ready = epoll_wait (epollfd, events, EPOLL_NEVENTS, -1);
                } while (ready == -1 && errno == EINTR);
index 22d21a37a7bdebb59340cb1f967d1f16b9043d67..75f12f266c8cccfe607bbb65bd0c09b82dc22a35 100644 (file)
@@ -12,7 +12,7 @@ struct _tp_kqueue_data {
 };
 
 typedef struct _tp_kqueue_data tp_kqueue_data;
-static void tp_kqueue_modify (gpointer event_data, int fd, int operation, int events, gboolean is_new);
+static void tp_kqueue_modify (gpointer p, int fd, int operation, int events, gboolean is_new);
 static void tp_kqueue_shutdown (gpointer event_data);
 static void tp_kqueue_wait (gpointer event_data);
 
@@ -42,9 +42,11 @@ kevent_change (int kfd, struct kevent *evt, const char *error_str)
 }
 
 static void
-tp_kqueue_modify (gpointer event_data, int fd, int operation, int events, gboolean is_new)
+tp_kqueue_modify (gpointer p, int fd, int operation, int events, gboolean is_new)
 {
-       tp_kqueue_data *data = event_data;
+       SocketIOData *socket_io_data;
+       socket_io_data = p;
+       tp_kqueue_data *data = socket_io_data->event_data;
        struct kevent evt;
 
        memset (&evt, 0, sizeof (evt));
@@ -57,6 +59,7 @@ tp_kqueue_modify (gpointer event_data, int fd, int operation, int events, gboole
                EV_SET (&evt, fd, EVFILT_WRITE, EV_ADD | EV_ENABLE | EV_ONESHOT, 0, 0, 0);
                kevent_change (data->fd, &evt, "ADD write");
        }
+       LeaveCriticalSection (&socket_io_data->io_lock);
 }
 
 static void
@@ -74,7 +77,6 @@ tp_kqueue_wait (gpointer p)
 {
        SocketIOData *socket_io_data;
        int kfd;
-       MonoInternalThread *thread;
        struct kevent *events, *evt;
        int ready = 0, i;
        gpointer async_results [KQUEUE_NEVENTS * 2]; // * 2 because each loop can add up to 2 results here
@@ -84,7 +86,6 @@ tp_kqueue_wait (gpointer p)
        socket_io_data = p;
        data = socket_io_data->event_data;
        kfd = data->fd;
-       thread = mono_thread_internal_current ();
        events = g_new0 (struct kevent, KQUEUE_NEVENTS);
 
        while (1) {
@@ -93,8 +94,7 @@ tp_kqueue_wait (gpointer p)
 
                do {
                        if (ready == -1) {
-                               if (THREAD_WANTS_A_BREAK (thread))
-                                       mono_thread_interruption_checkpoint ();
+                               check_for_interruption_critical ();
                        }
                        ready = kevent (kfd, NULL, 0, events, KQUEUE_NEVENTS, NULL);
                } while (ready == -1 && errno == EINTR);
index e03eca5248cc4c4a0f36bb374064bf2eebab1258..e44e338598837532e6bd5d3e80f4c54dd67efbf3 100644 (file)
@@ -19,7 +19,7 @@ struct _tp_poll_data {
 typedef struct _tp_poll_data tp_poll_data;
 
 static void tp_poll_shutdown (gpointer event_data);
-static void tp_poll_modify (gpointer event_data, int fd, int operation, int events, gboolean is_new);
+static void tp_poll_modify (gpointer p, int fd, int operation, int events, gboolean is_new);
 static void tp_poll_wait (gpointer p);
 
 static gpointer
@@ -74,12 +74,18 @@ tp_poll_init (SocketIOData *data)
 }
 
 static void
-tp_poll_modify (gpointer event_data, int fd, int operation, int events, gboolean is_new)
+tp_poll_modify (gpointer p, int fd, int operation, int events, gboolean is_new)
 {
-       tp_poll_data *data = event_data;
+       SocketIOData *socket_io_data;
+       tp_poll_data *data;
        char msg [1];
        int unused;
 
+       socket_io_data = p;
+       data = socket_io_data->event_data;
+
+       LeaveCriticalSection (&socket_io_data->io_lock);
+       
        MONO_SEM_WAIT (&data->new_sem);
        INIT_POLLFD (&data->newpfd, GPOINTER_TO_INT (fd), events);
        *msg = (char) operation;
@@ -150,14 +156,11 @@ tp_poll_wait (gpointer p)
        gint maxfd = 1;
        gint allocated;
        gint i;
-       MonoInternalThread *thread;
        tp_poll_data *data;
        SocketIOData *socket_io_data = p;
        MonoPtrArray async_results;
        gint nresults;
 
-       thread = mono_thread_internal_current ();
-
        data = socket_io_data->event_data;
        allocated = INITIAL_POLLFD_SIZE;
        pfds = g_new0 (mono_pollfd, allocated);
@@ -177,8 +180,7 @@ tp_poll_wait (gpointer p)
 
                do {
                        if (nsock == -1) {
-                               if (THREAD_WANTS_A_BREAK (thread))
-                                       mono_thread_interruption_checkpoint ();
+                               check_for_interruption_critical ();
                        }
 
                        nsock = mono_poll (pfds, maxfd, -1);
index dd81fe49a8127b6de3dd8a6106479243da58cef9..75f52c6628f35dcb0f44d9340eb1c971996b373a 100644 (file)
@@ -52,9 +52,9 @@ typedef struct {
 } MonoVerifyInfoExtended;
 
 
-GSList* mono_method_verify       (MonoMethod *method, int level);
-void    mono_free_verify_list    (GSList *list);
-char*   mono_verify_corlib       (void);
+MONO_API GSList* mono_method_verify       (MonoMethod *method, int level);
+MONO_API void    mono_free_verify_list    (GSList *list);
+MONO_API char*   mono_verify_corlib       (void);
 
 MONO_END_DECLS
 
old mode 100644 (file)
new mode 100755 (executable)
index eb34e4e..926ab52
@@ -117,6 +117,9 @@ noinst_SCRIPTS = mono
 mono: mono-$(mono_bin_suffix)
        ln -sf $< $@
 
+mono.exe: mono-$(mono_bin_suffix).exe
+       ln -sf $< $@
+
 install-exec-hook:
        (cd $(DESTDIR)$(bindir) && ln -sf mono-$(mono_bin_suffix) mono)
        (cd $(DESTDIR)$(libdir); for i in libmono$(libmono_suffix)*; do ln -sf $$i `echo $$i | sed s/$(libmono_suffix)//` ; done)
@@ -236,7 +239,7 @@ MONO_LIB=$(boehm_static_libraries)
 MONO_SGEN_LIB=$(sgen_static_libraries)
 else 
 MONO_LIB=libmonoboehm-2.0.la
-MONO_LIBLIB=libmonosgen-2.0.la
+MONO_SGEN_LIB=libmonosgen-2.0.la
 endif
 
 if LOADED_LLVM
old mode 100644 (file)
new mode 100755 (executable)
index 6d90d30..06cb08c
@@ -3703,6 +3703,8 @@ has_type_vars (MonoClass *klass)
                                        return TRUE;
                }
        }
+       if (klass->generic_container)
+               return TRUE;
        return FALSE;
 }
 
@@ -3831,6 +3833,13 @@ add_generic_class_with_depth (MonoAotCompile *acfg, MonoClass *klass, int depth,
 
        iter = NULL;
        while ((method = mono_class_get_methods (klass, &iter))) {
+               if ((acfg->opts & MONO_OPT_GSHAREDVT) && method->is_inflated && mono_method_get_context (method)->method_inst) {
+                       /*
+                        * This is partial sharing, and we can't handle it yet
+                        */
+                       continue;
+               }
+               
                if (mono_method_is_generic_sharable_full (method, FALSE, FALSE, use_gsharedvt))
                        /* Already added */
                        continue;
@@ -4441,7 +4450,7 @@ emit_and_reloc_code (MonoAotCompile *acfg, MonoMethod *method, guint8 *code, gui
        MonoDebugSourceLocation **locs = NULL;
        gboolean skip, direct_call, external_call;
        guint32 got_slot;
-       const char *direct_call_target;
+       const char *direct_call_target = 0;
        const char *direct_pinvoke;
 
        if (method) {
@@ -4484,8 +4493,8 @@ emit_and_reloc_code (MonoAotCompile *acfg, MonoMethod *method, guint8 *code, gui
                        mono_debug_symfile_free_location (loc);
                }
 
-#ifdef MONO_ARCH_AOT_SUPPORTED
                skip = FALSE;
+#ifdef MONO_ARCH_AOT_SUPPORTED
                if (patch_info && (patch_info->ip.i == i) && (pindex < patches->len)) {
                        start_index = pindex;
 
@@ -6837,7 +6846,7 @@ emit_llvm_file (MonoAotCompile *acfg)
        opts = g_strdup ("-instcombine -simplifycfg");
        opts = g_strdup ("-simplifycfg -domtree -domfrontier -scalarrepl -instcombine -simplifycfg -domtree -domfrontier -scalarrepl -simplify-libcalls -instcombine -simplifycfg -instcombine -simplifycfg -reassociate -domtree -loops -loop-simplify -domfrontier -loop-simplify -lcssa -loop-rotate -licm -lcssa -loop-unswitch -instcombine -scalar-evolution -loop-simplify -lcssa -iv-users -indvars -loop-deletion -loop-simplify -lcssa -loop-unroll -instcombine -memdep -gvn -memdep -memcpyopt -sccp -instcombine -domtree -memdep -dse -adce -simplifycfg -preverify -domtree -verify");
 #if 1
-       command = g_strdup_printf ("%sopt -f %s -o %s.opt.bc %s.bc", acfg->aot_opts.llvm_path, opts, acfg->tmpfname, acfg->tmpfname);
+       command = g_strdup_printf ("%sopt -f %s -o \"%s.opt.bc\" \"%s.bc\"", acfg->aot_opts.llvm_path, opts, acfg->tmpfname, acfg->tmpfname);
        printf ("Executing opt: %s\n", command);
        if (system (command) != 0) {
                exit (1);
@@ -6865,7 +6874,7 @@ emit_llvm_file (MonoAotCompile *acfg)
 #endif
        unlink (acfg->tmpfname);
 
-       command = g_strdup_printf ("%sllc %s -disable-gnu-eh-frame -enable-mono-eh-frame -o %s %s.opt.bc", acfg->aot_opts.llvm_path, acfg->llc_args->str, acfg->tmpfname, acfg->tmpfname);
+       command = g_strdup_printf ("%sllc %s -disable-gnu-eh-frame -enable-mono-eh-frame -o \"%s\" \"%s.opt.bc\"", acfg->aot_opts.llvm_path, acfg->llc_args->str, acfg->tmpfname, acfg->tmpfname);
 
        printf ("Executing llc: %s\n", command);
 
@@ -8048,6 +8057,7 @@ emit_file_info (MonoAotCompile *acfg)
                }
                acfg->static_linking_symbol = g_strdup (symbol);
                emit_global_inner (acfg, symbol, FALSE);
+               emit_alignment (acfg, sizeof (gpointer));
                emit_label (acfg, symbol);
                emit_pointer_2 (acfg, acfg->user_symbol_prefix, "mono_aot_file_info");
        }
@@ -8472,8 +8482,11 @@ mono_compile_assembly (MonoAssembly *ass, guint32 opts, const char *aot_options)
        TV_DECLARE (atv);
        TV_DECLARE (btv);
 
-#ifndef MONO_ARCH_GSHAREDVT_SUPPORTED
-       opts &= ~MONO_OPT_GSHAREDVT;
+#if !defined(MONO_ARCH_GSHAREDVT_SUPPORTED) || (!defined(MONO_EXTENSIONS) && !defined(MONOTOUCH))
+       if (opts & MONO_OPT_GSHAREDVT) {
+               fprintf (stderr, "-O=gsharedvt not supported on this platform.\n");
+               exit (1);
+       }
 #endif
 
        printf ("Mono Ahead of Time compiler - compiling assembly %s\n", image->name);
index b46d75ba4ff4c41134d24df8c375627a76ea1af0..649c30c0fb27da51f9bb041ac6020deb245d6127 100644 (file)
@@ -9,28 +9,28 @@
 typedef struct _MonoDebuggerThreadInfo MonoDebuggerThreadInfo;
 extern MonoDebuggerThreadInfo *mono_debugger_thread_table;
 
-void
+MONO_API void
 mono_debugger_thread_created (gsize tid, MonoThread *thread, MonoJitTlsData *jit_tls, gpointer func);
 
-void
+MONO_API void
 mono_debugger_thread_cleanup (MonoJitTlsData *jit_tls);
 
-void
+MONO_API void
 mono_debugger_extended_notification (MonoDebuggerEvent event, guint64 data, guint64 arg);
 
-void
+MONO_API void
 mono_debugger_trampoline_compiled (const guint8 *trampoline, MonoMethod *method, const guint8 *code);
 
-void
+MONO_API void
 mono_debugger_call_exception_handler (gpointer addr, gpointer stack, MonoObject *exc);
 
-gboolean
+MONO_API gboolean
 mono_debugger_handle_exception (MonoContext *ctx, MonoObject *obj);
 
-MonoObject *
+MONO_API MonoObject *
 mono_debugger_runtime_invoke (MonoMethod *method, void *obj, void **params, MonoObject **exc);
 
-gboolean
+MONO_API gboolean
 mono_debugger_abort_runtime_invoke (void);
 
 /*
old mode 100644 (file)
new mode 100755 (executable)
index ebf7735..18c6ea5
@@ -2235,7 +2235,17 @@ decode_moduleid (guint8 *buf, guint8 **endbuf, guint8 *limit, MonoDomain **domai
 static inline MonoMethod*
 decode_methodid (guint8 *buf, guint8 **endbuf, guint8 *limit, MonoDomain **domain, int *err)
 {
-       return decode_ptr_id (buf, endbuf, limit, ID_METHOD, domain, err);
+       MonoMethod *m;
+
+       m = decode_ptr_id (buf, endbuf, limit, ID_METHOD, domain, err);
+       if (G_UNLIKELY (log_level >= 2) && m) {
+               char *s;
+
+               s = mono_method_full_name (m, TRUE);
+               DEBUG(2, fprintf (log_file, "[dbg]   recv method [%s]\n", s));
+               g_free (s);
+       }
+       return m;
 }
 
 static inline MonoClassField*
@@ -3484,6 +3494,7 @@ event_to_string (EventKind event)
        case EVENT_KIND_USER_LOG: return "USER_LOG";
        default:
                g_assert_not_reached ();
+               return "";
        }
 }
 
@@ -4433,7 +4444,10 @@ ss_update (SingleStepReq *req, MonoJitInfo *ji, SeqPoint *sp)
 
        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 ()));
+               if (!loc)
+                       DEBUG(1, fprintf (log_file, "[%p] No line number info for il offset %x, continuing single stepping.\n", (gpointer)GetCurrentThreadId (), sp->il_offset));
+               else
+                       DEBUG(1, fprintf (log_file, "[%p] Same source line (%d), continuing single stepping.\n", (gpointer)GetCurrentThreadId (), loc->row));
                hit = FALSE;
        }
                                
@@ -8985,7 +8999,7 @@ cmd_to_string (CommandSet set, int command)
                cmds_len = G_N_ELEMENTS (event_cmds_str);
                break;
        default:
-               break;
+               return NULL;
        }
        if (command > 0 && command <= cmds_len)
                return cmds [command - 1];
index 2beeb9e59d57475fa500935d05262777fd834b91..1bbdedb4307d9a26c657231173b7417f68be828c 100644 (file)
@@ -17,7 +17,7 @@
 #ifndef DISABLE_JIT
 
 /* FIXME: This conflicts with the definition in mini.c, so it cannot be moved to mini.h */
-MonoInst* mono_emit_native_call (MonoCompile *cfg, gconstpointer func, MonoMethodSignature *sig, MonoInst **args);
+MONO_API MonoInst* mono_emit_native_call (MonoCompile *cfg, gconstpointer func, MonoMethodSignature *sig, MonoInst **args);
 void mini_emit_stobj (MonoCompile *cfg, MonoInst *dest, MonoInst *src, MonoClass *klass, gboolean native);
 void mini_emit_initobj (MonoCompile *cfg, MonoInst *dest, const guchar *ip, MonoClass *klass);
 
index 2e686747ada0abecb95f34205288fdf0180727aa..a3eff47ea7ec8139b7caaf83a560c8a3e36b4eec 100644 (file)
@@ -9,6 +9,13 @@
  */
 
 #include <config.h>
+
+#if _WIN32_WINNT < 0x0501
+/* Required for Vectored Exception Handling. */
+#undef _WIN32_WINNT
+#define _WIN32_WINNT 0x0501
+#endif /* _WIN32_WINNT < 0x0501 */
+
 #include <glib.h>
 #include <signal.h>
 #include <string.h>
@@ -40,24 +47,37 @@ static MonoW32ExceptionHandler ill_handler;
 static MonoW32ExceptionHandler segv_handler;
 
 LPTOP_LEVEL_EXCEPTION_FILTER mono_old_win_toplevel_exception_filter;
-guint64 mono_win_chained_exception_filter_result;
-gboolean mono_win_chained_exception_filter_didrun;
+guint64 mono_win_vectored_exception_handle;
+extern gboolean mono_win_chained_exception_needs_run;
 
 #define W32_SEH_HANDLE_EX(_ex) \
        if (_ex##_handler) _ex##_handler(0, ep, sctx)
 
+LONG CALLBACK seh_unhandled_exception_filter(EXCEPTION_POINTERS* ep)
+{
+#ifndef MONO_CROSS_COMPILE
+       if (mono_old_win_toplevel_exception_filter) {
+               return (*mono_old_win_toplevel_exception_filter)(ep);
+       }
+#endif
+
+       mono_handle_native_sigsegv (SIGSEGV, NULL);
+
+       return EXCEPTION_CONTINUE_SEARCH;
+}
+
 /*
  * Unhandled Exception Filter
  * Top-level per-process exception handler.
  */
-LONG CALLBACK seh_handler(EXCEPTION_POINTERS* ep)
+LONG CALLBACK seh_vectored_exception_handler(EXCEPTION_POINTERS* ep)
 {
        EXCEPTION_RECORD* er;
        CONTEXT* ctx;
        MonoContext* sctx;
        LONG res;
 
-       mono_win_chained_exception_filter_didrun = FALSE;
+       mono_win_chained_exception_needs_run = FALSE;
        res = EXCEPTION_CONTINUE_EXECUTION;
 
        er = ep->ExceptionRecord;
@@ -98,40 +118,57 @@ LONG CALLBACK seh_handler(EXCEPTION_POINTERS* ep)
                break;
        }
 
-       /* Copy context back */
-       /* Nonvolatile */
-       ctx->Rsp = sctx->rsp; 
-       ctx->Rdi = sctx->rdi; 
-       ctx->Rsi = sctx->rsi; 
-       ctx->Rbx = sctx->rbx; 
-       ctx->Rbp = sctx->rbp;
-       ctx->R12 = sctx->r12; 
-       ctx->R13 = sctx->r13; 
-       ctx->R14 = sctx->r14;
-       ctx->R15 = sctx->r15;
-       ctx->Rip = sctx->rip; 
-
-       /* Volatile But should not matter?*/
-       ctx->Rax = sctx->rax; 
-       ctx->Rcx = sctx->rcx; 
-       ctx->Rdx = sctx->rdx;
-
-       g_free (sctx);
-
-       if (mono_win_chained_exception_filter_didrun)
-               res = mono_win_chained_exception_filter_result;
+       if (win32_chained_exception_needs_run) {
+               /* Don't copy context back if we chained exception
+               * as the handler may have modfied the EXCEPTION_POINTERS
+               * directly. We don't pass sigcontext to chained handlers.
+               * Return continue search so the UnhandledExceptionFilter
+               * can correctly chain the exception.
+               */
+               res = EXCEPTION_CONTINUE_SEARCH;
+       } else {
+               /* Copy context back */
+               /* Nonvolatile */
+               ctx->Rsp = sctx->rsp;
+               ctx->Rdi = sctx->rdi;
+               ctx->Rsi = sctx->rsi;
+               ctx->Rbx = sctx->rbx;
+               ctx->Rbp = sctx->rbp;
+               ctx->R12 = sctx->r12;
+               ctx->R13 = sctx->r13;
+               ctx->R14 = sctx->r14;
+               ctx->R15 = sctx->r15;
+               ctx->Rip = sctx->rip;
+
+               /* Volatile But should not matter?*/
+               ctx->Rax = sctx->rax;
+               ctx->Rcx = sctx->rcx;
+               ctx->Rdx = sctx->rdx;
+       }
+
+       /* TODO: Find right place to free this in stack overflow case */
+       if (er->ExceptionCode != EXCEPTION_STACK_OVERFLOW)
+               g_free (sctx);
 
        return res;
 }
 
 void win32_seh_init()
 {
-       mono_old_win_toplevel_exception_filter = SetUnhandledExceptionFilter(seh_handler);
+       mono_old_win_toplevel_exception_filter = SetUnhandledExceptionFilter(seh_unhandled_exception_filter);
+       mono_win_vectored_exception_handle = AddVectoredExceptionHandler (1, seh_vectored_exception_handler);
 }
 
 void win32_seh_cleanup()
 {
        if (mono_old_win_toplevel_exception_filter) SetUnhandledExceptionFilter(mono_old_win_toplevel_exception_filter);
+
+       guint32 ret = 0;
+       if (old_win32_toplevel_exception_filter)
+               SetUnhandledExceptionFilter(mono_old_win_toplevel_exception_filter);
+
+       ret = RemoveVectoredExceptionHandler (mono_win_vectored_exception_handle);
+       g_assert (ret);
 }
 
 void win32_seh_set_handler(int type, MonoW32ExceptionHandler handler)
index c97f28f39f49a7e2ea7fc0f23d6a5601855fa399..2247b91a2abe39a3351df201a4a0ef77a815ee5c 100644 (file)
@@ -8,6 +8,13 @@
  */
 
 #include <config.h>
+
+#if _WIN32_WINNT < 0x0501
+/* Required for Vectored Exception Handling. */
+#undef _WIN32_WINNT
+#define _WIN32_WINNT 0x0501
+#endif /* _WIN32_WINNT < 0x0501 */
+
 #include <glib.h>
 #include <signal.h>
 #include <string.h>
@@ -40,8 +47,9 @@ static MonoW32ExceptionHandler ill_handler;
 static MonoW32ExceptionHandler segv_handler;
 
 LPTOP_LEVEL_EXCEPTION_FILTER mono_old_win_toplevel_exception_filter;
-guint64 mono_win_chained_exception_filter_result;
-gboolean mono_win_chained_exception_filter_didrun;
+gpointer mono_win_vectored_exception_handle;
+extern gboolean mono_win_chained_exception_needs_run;
+extern int (*gUnhandledExceptionHandler)(EXCEPTION_POINTERS*);
 
 #ifndef PROCESS_CALLBACK_FILTER_ENABLED
 #      define PROCESS_CALLBACK_FILTER_ENABLED 1
@@ -50,6 +58,19 @@ gboolean mono_win_chained_exception_filter_didrun;
 #define W32_SEH_HANDLE_EX(_ex) \
        if (_ex##_handler) _ex##_handler(0, ep, sctx)
 
+LONG CALLBACK seh_unhandled_exception_filter(EXCEPTION_POINTERS* ep)
+{
+#ifndef MONO_CROSS_COMPILE
+       if (mono_old_win_toplevel_exception_filter) {
+               return (*mono_old_win_toplevel_exception_filter)(ep);
+       }
+#endif
+
+       mono_handle_native_sigsegv (SIGSEGV, NULL);
+
+       return EXCEPTION_CONTINUE_SEARCH;
+}
+
 /*
  * mono_win32_get_handle_stackoverflow (void):
  *
@@ -170,14 +191,14 @@ win32_handle_stack_overflow (EXCEPTION_POINTERS* ep, struct sigcontext *sctx)
  * Unhandled Exception Filter
  * Top-level per-process exception handler.
  */
-LONG CALLBACK seh_handler(EXCEPTION_POINTERS* ep)
+LONG CALLBACK seh_vectored_exception_handler(EXCEPTION_POINTERS* ep)
 {
        EXCEPTION_RECORD* er;
        CONTEXT* ctx;
        struct sigcontext* sctx;
        LONG res;
 
-       mono_win_chained_exception_filter_didrun = FALSE;
+       mono_win_chained_exception_needs_run = FALSE;
        res = EXCEPTION_CONTINUE_EXECUTION;
 
        er = ep->ExceptionRecord;
@@ -217,21 +238,30 @@ LONG CALLBACK seh_handler(EXCEPTION_POINTERS* ep)
                break;
        }
 
-       /* Copy context back */
-       ctx->Eax = sctx->eax;
-       ctx->Ebx = sctx->ebx;
-       ctx->Ecx = sctx->ecx;
-       ctx->Edx = sctx->edx;
-       ctx->Ebp = sctx->ebp;
-       ctx->Esp = sctx->esp;
-       ctx->Esi = sctx->esi;
-       ctx->Edi = sctx->edi;
-       ctx->Eip = sctx->eip;
-
-       g_free (sctx);
+       if (mono_win_chained_exception_needs_run) {
+               /* Don't copy context back if we chained exception
+               * as the handler may have modfied the EXCEPTION_POINTERS
+               * directly. We don't pass sigcontext to chained handlers.
+               * Return continue search so the UnhandledExceptionFilter
+               * can correctly chain the exception.
+               */
+               res = EXCEPTION_CONTINUE_SEARCH;
+       } else {
+               /* Copy context back */
+               ctx->Eax = sctx->eax;
+               ctx->Ebx = sctx->ebx;
+               ctx->Ecx = sctx->ecx;
+               ctx->Edx = sctx->edx;
+               ctx->Ebp = sctx->ebp;
+               ctx->Esp = sctx->esp;
+               ctx->Esi = sctx->esi;
+               ctx->Edi = sctx->edi;
+               ctx->Eip = sctx->eip;
+       }
 
-       if (mono_win_chained_exception_filter_didrun)
-               res = mono_win_chained_exception_filter_result;
+       /* TODO: Find right place to free this in stack overflow case */
+       if (er->ExceptionCode != EXCEPTION_STACK_OVERFLOW)
+               g_free (sctx);
 
        return res;
 }
@@ -242,12 +272,14 @@ void win32_seh_init()
        if (!restore_stack)
                restore_stack = mono_win32_get_handle_stackoverflow ();
 
-       mono_old_win_toplevel_exception_filter = SetUnhandledExceptionFilter(seh_handler);
+       mono_old_win_toplevel_exception_filter = SetUnhandledExceptionFilter(seh_unhandled_exception_filter);
+       mono_win_vectored_exception_handle = AddVectoredExceptionHandler (1, seh_vectored_exception_handler);
 }
 
 void win32_seh_cleanup()
 {
        if (mono_old_win_toplevel_exception_filter) SetUnhandledExceptionFilter(mono_old_win_toplevel_exception_filter);
+       RemoveVectoredExceptionHandler (seh_unhandled_exception_filter);
 }
 
 void win32_seh_set_handler(int type, MonoW32ExceptionHandler handler)
index f545160ec42d6aee9d6eee5ec2314b5ff9e2f3bb..4dd155a60e4f3febd2a3ac8b96fe24ca8e6efa52 100644 (file)
@@ -212,6 +212,12 @@ public class Tests
                return 0;
        }
 
+       public static int test_0_unbox_any_enum () {
+               IFaceUnbox iface = new ClassUnbox ();
+               AnEnum res = iface.Unbox<AnEnum, int> (AnEnum.One, 0, 1);
+               return res == AnEnum.Two ? 0 : 1;
+       }
+
        [MethodImplAttribute (MethodImplOptions.NoInlining)]
        static void ldfld_nongeneric<T> (GFoo<T>[] foo, int[] arr) {
                arr [0] = foo [0].i;
@@ -914,7 +920,8 @@ public class Tests
        }
 
        enum AnEnum {
-               One
+               One,
+               Two
        };
 
        public static int test_0_constrained_tostring () {
@@ -1218,6 +1225,10 @@ public class Tests
                void foo_ref_arg (string s);
        }
 
+       interface IConstrained<T3> {
+               void foo_gsharedvt_arg (T3 s);
+       }
+
        static object constrained_res;
 
        struct ConsStruct : IConstrained {
@@ -1244,9 +1255,16 @@ public class Tests
                }
        }
 
+       struct ConsStruct<T> : IConstrained<T> {
+               public void foo_gsharedvt_arg (T s) {
+                       constrained_res = s;
+               }
+       }
+
        interface IFaceConstrained {
                void constrained_void_iface_call<T, T2>(T t, T2 t2) where T2 : IConstrained;
                void constrained_void_iface_call_ref_arg<T, T2>(T t, T2 t2) where T2 : IConstrained;
+               void constrained_void_iface_call_gsharedvt_arg<T, T2, T3>(T t, T2 t2, T3 t3) where T2 : IConstrained<T>;
        }
 
        class ClassConstrained : IFaceConstrained {
@@ -1259,6 +1277,11 @@ public class Tests
                public void constrained_void_iface_call_ref_arg<T, T2>(T t, T2 t2) where T2 : IConstrained {
                        t2.foo_ref_arg ("A");
                }
+
+               [MethodImplAttribute (MethodImplOptions.NoInlining)]
+               public void constrained_void_iface_call_gsharedvt_arg<T, T2, T3>(T t, T2 t2, T3 t3) where T2 : IConstrained<T> {
+                       t2.foo_gsharedvt_arg (t);
+               }
        }
 
        public static int test_0_constrained_void_iface_call () {
@@ -1284,6 +1307,25 @@ public class Tests
                return 0;
        }
 
+       public static int test_0_constraine_void_iface_call_gsharedvt_arg () {
+               // This tests constrained calls through interfaces with one gsharedvt arg, like IComparable<T>.CompareTo ()
+               IFaceConstrained c = new ClassConstrained ();
+
+               var s = new ConsStruct<int> ();
+               constrained_res = null;
+               c.constrained_void_iface_call_gsharedvt_arg<int, ConsStruct<int>, int> (42, s, 55);
+               if (!(constrained_res is int) || ((int)constrained_res) != 42)
+                       return 1;
+
+               var s2 = new ConsStruct<string> ();
+               constrained_res = null;
+               c.constrained_void_iface_call_gsharedvt_arg<string, ConsStruct<string>, int> ("A", s2, 55);
+               if (!(constrained_res is string) || ((string)constrained_res) != "A")
+                       return 2;
+
+               return 0;
+       }
+
        public static async Task<T> FooAsync<T> (int i, int j) {
                Task<int> t = new Task<int> (delegate () { return 42; });
                var response = await t;
@@ -1303,6 +1345,21 @@ public class Tests
        }
 }
 
+// #13191
+public class MobileServiceCollection<TTable, TCol>
+{
+       public async Task<int> LoadMoreItemsAsync(int count = 0) {
+               await Task.Delay (1000);
+               int results = await ProcessQueryAsync ();
+               return results;
+       }
+
+       protected async virtual Task<int> ProcessQueryAsync() {
+               await Task.Delay (1000);
+               throw new Exception ();
+       }
+}
+
 #if !MOBILE
 public class GSharedTests : Tests {
 }
index 449b2ce3600881998edc8157d84d7893e732104d..85165aaf71cd145c1d9a8e96e1d45486029d21ac 100644 (file)
@@ -1052,7 +1052,7 @@ mono_create_corlib_exception_2 (guint32 token, MonoString *arg1, MonoString *arg
 }
 
 MonoObject*
-mono_object_castclass (MonoObject *obj, MonoClass *klass)
+mono_object_castclass_unbox (MonoObject *obj, MonoClass *klass)
 {
        MonoJitTlsData *jit_tls = NULL;
 
@@ -1064,8 +1064,12 @@ mono_object_castclass (MonoObject *obj, MonoClass *klass)
        if (!obj)
                return NULL;
 
-       if (mono_object_isinst (obj, klass))
+       if (klass->enumtype) {
+               if (obj->vtable->klass == klass->element_class)
+                       return obj;
+       } else if (mono_object_isinst (obj, klass)) {
                return obj;
+       }
 
        if (mini_get_debug_options ()->better_cast_details) {
                jit_tls->class_cast_from = obj->vtable->klass;
@@ -1160,6 +1164,9 @@ constrained_gsharedvt_call_setup (gpointer mp, MonoMethod *cmethod, MonoClass *k
        MonoMethod *m;
        int vt_slot;
 
+       if (klass->flags & TYPE_ATTRIBUTE_INTERFACE)
+               mono_raise_exception (mono_get_exception_execution_engine ("Not yet supported."));
+
        /* Lookup the virtual method */
        mono_class_setup_vtable (klass);
        g_assert (klass->vtable);
@@ -1197,12 +1204,17 @@ constrained_gsharedvt_call_setup (gpointer mp, MonoMethod *cmethod, MonoClass *k
  * the arguments to the method in the format used by mono_runtime_invoke ().
  */
 MonoObject*
-mono_gsharedvt_constrained_call (gpointer mp, MonoMethod *cmethod, MonoClass *klass, gpointer *args)
+mono_gsharedvt_constrained_call (gpointer mp, MonoMethod *cmethod, MonoClass *klass, gboolean deref_arg, gpointer *args)
 {
        MonoMethod *m;
        gpointer this_arg;
+       gpointer new_args [16];
 
        m = constrained_gsharedvt_call_setup (mp, cmethod, klass, &this_arg);
+       if (args && deref_arg) {
+               new_args [0] = *(gpointer*)args [0];
+               args = new_args;
+       }
        return mono_runtime_invoke (m, this_arg, args, NULL);
 }
 
index 54455c96e8002f9d7bd4c108d4904a25e862c031..dd99e7c763559c3834f0076a69fc2090930fcccf 100644 (file)
@@ -165,7 +165,7 @@ MonoException *mono_create_corlib_exception_1 (guint32 token, MonoString *arg) M
 
 MonoException *mono_create_corlib_exception_2 (guint32 token, MonoString *arg1, MonoString *arg2) MONO_INTERNAL;
 
-MonoObject* mono_object_castclass (MonoObject *obj, MonoClass *klass) MONO_INTERNAL;
+MonoObject* mono_object_castclass_unbox (MonoObject *obj, MonoClass *klass) MONO_INTERNAL;
 
 gpointer mono_get_native_calli_wrapper (MonoImage *image, MonoMethodSignature *sig, gpointer func) MONO_INTERNAL;
 
@@ -176,7 +176,7 @@ MonoObject*
 mono_object_castclass_with_cache (MonoObject *obj, MonoClass *klass, gpointer *cache);
 
 MonoObject*
-mono_gsharedvt_constrained_call (gpointer mp, MonoMethod *cmethod, MonoClass *klass, gpointer *args) MONO_INTERNAL;
+mono_gsharedvt_constrained_call (gpointer mp, MonoMethod *cmethod, MonoClass *klass, gboolean deref_arg, gpointer *args) MONO_INTERNAL;
 
 void mono_gsharedvt_value_copy (gpointer dest, gpointer src, MonoClass *klass) MONO_INTERNAL;
 
index 080531b607606fb3cff37f9b19f1366bf77e3efb..95e690159ee2cfaa87e4032ea8f9e8aeb2164678 100644 (file)
 
 MONO_BEGIN_DECLS
 
-MonoDomain * 
+MONO_API MonoDomain * 
 mono_jit_init              (const char *file);
 
-MonoDomain * 
+MONO_API MonoDomain * 
 mono_jit_init_version      (const char *root_domain_name, const char *runtime_version);
 
-int
+MONO_API int
 mono_jit_exec              (MonoDomain *domain, MonoAssembly *assembly, 
                            int argc, char *argv[]);
-void        
+MONO_API void        
 mono_jit_cleanup           (MonoDomain *domain);
 
-mono_bool
+MONO_API mono_bool
 mono_jit_set_trace_options (const char* options);
 
-void
+MONO_API void
 mono_set_signal_chaining   (mono_bool chain_signals);
 
-void
+MONO_API void
 mono_jit_set_aot_only      (mono_bool aot_only);
 
 /* Allow embedders to decide wherther to actually obey breakpoint instructions
@@ -50,12 +50,12 @@ typedef enum {
 } MonoBreakPolicy;
 
 typedef MonoBreakPolicy (*MonoBreakPolicyFunc) (MonoMethod *method);
-void mono_set_break_policy (MonoBreakPolicyFunc policy_callback);
+MONO_API void mono_set_break_policy (MonoBreakPolicyFunc policy_callback);
 
-void
+MONO_API void
 mono_jit_parse_options     (int argc, char * argv[]);
 
-char*       mono_get_runtime_build_info    (void);
+MONO_API char*       mono_get_runtime_build_info    (void);
 
 MONO_END_DECLS
 
old mode 100644 (file)
new mode 100755 (executable)
index dc7c826..f5a8487
@@ -94,7 +94,7 @@ mono_main_with_options (int argc, char *argv [])
 #ifdef HOST_WIN32
 
 int
-main ()
+main (void)
 {
        int argc;
        gunichar2** argvw;
index 4f6ac6d5ff7fb8ae70759d12ffeb65ad62656d90..167aa974dc2d1b6eceb432190e9f9a522d04e397 100644 (file)
@@ -130,7 +130,7 @@ static int stind_to_store_membase (int opcode);
 int mono_op_to_op_imm (int opcode);
 int mono_op_to_op_imm_noemul (int opcode);
 
-MonoInst* mono_emit_native_call (MonoCompile *cfg, gconstpointer func, MonoMethodSignature *sig, MonoInst **args);
+MONO_API MonoInst* mono_emit_native_call (MonoCompile *cfg, gconstpointer func, MonoMethodSignature *sig, MonoInst **args);
 
 /* helper methods signatures */
 static MonoMethodSignature *helper_sig_class_init_trampoline = NULL;
@@ -3533,7 +3533,7 @@ handle_unbox_gsharedvt (MonoCompile *cfg, int context_used, MonoClass *klass, Mo
        args [1] = klass_inst;
 
        /* CASTCLASS */
-       obj = mono_emit_jit_icall (cfg, mono_object_castclass, args);
+       obj = mono_emit_jit_icall (cfg, mono_object_castclass_unbox, args);
 
        NEW_BBLOCK (cfg, is_ref_bb);
        NEW_BBLOCK (cfg, is_nullable_bb);
@@ -7602,16 +7602,22 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
                                                /* The 'Own method' case below */
                                        } else if (((cmethod->klass == mono_defaults.object_class) || (cmethod->klass->flags & TYPE_ATTRIBUTE_INTERFACE)) &&
                                                           (MONO_TYPE_IS_VOID (fsig->ret) || fsig->ret->type == MONO_TYPE_I4 || fsig->ret->type == MONO_TYPE_BOOLEAN || fsig->ret->type == MONO_TYPE_STRING) &&
-                                                          (fsig->param_count == 0 || (fsig->param_count == 1 && MONO_TYPE_IS_REFERENCE (fsig->params [0])))) {
+                                                          (fsig->param_count == 0 || (fsig->param_count == 1 && (MONO_TYPE_IS_REFERENCE (fsig->params [0]) || mini_is_gsharedvt_type (cfg, fsig->params [0]))))) {
                                                MonoInst *args [16];
 
                                                /*
-                                                * This case handles calls to object:ToString()/Equals()/GetHashCode(), plus some simple interface calls enough to support
-                                                * AsyncTaskMethodBuilder.
+                                                * This case handles calls to
+                                                * - object:ToString()/Equals()/GetHashCode(),
+                                                * - System.IComparable<T>:CompareTo()
+                                                * - System.IEquatable<T>:Equals ()
+                                                * plus some simple interface calls enough to support AsyncTaskMethodBuilder.
                                                 */
 
                                                args [0] = sp [0];
-                                               EMIT_NEW_METHODCONST (cfg, args [1], cmethod);
+                                               if (mono_method_check_context_used (cmethod))
+                                                       args [1] = emit_get_rgctx_method (cfg, mono_method_check_context_used (cmethod), cmethod, MONO_RGCTX_INFO_METHOD);
+                                               else
+                                                       EMIT_NEW_METHODCONST (cfg, args [1], cmethod);
                                                args [2] = emit_get_rgctx_klass (cfg, mono_class_check_context_used (constrained_call), constrained_call, MONO_RGCTX_INFO_KLASS);
 
                                                if (fsig->param_count) {
@@ -7620,11 +7626,23 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
                                                        ins->dreg = alloc_preg (cfg);
                                                        ins->inst_imm = fsig->param_count * sizeof (mgreg_t);
                                                        MONO_ADD_INS (cfg->cbb, ins);
-                                                       args [3] = ins;
+                                                       args [4] = ins;
+
+                                                       if (mini_is_gsharedvt_type (cfg, fsig->params [0])) {
+                                                               int addr_reg;
+
+                                                               args [3] = emit_get_gsharedvt_info_klass (cfg, mono_class_from_mono_type (fsig->params [0]), MONO_RGCTX_INFO_CLASS_BOX_TYPE);
 
-                                                       EMIT_NEW_STORE_MEMBASE (cfg, ins, OP_STORE_MEMBASE_REG, args [3]->dreg, 0, sp [1]->dreg);
+                                                               EMIT_NEW_VARLOADA_VREG (cfg, ins, sp [1]->dreg, fsig->params [0]);
+                                                               addr_reg = ins->dreg;
+                                                               EMIT_NEW_STORE_MEMBASE (cfg, ins, OP_STORE_MEMBASE_REG, args [4]->dreg, 0, addr_reg);
+                                                       } else {
+                                                               EMIT_NEW_ICONST (cfg, args [3], 0);
+                                                               EMIT_NEW_STORE_MEMBASE (cfg, ins, OP_STORE_MEMBASE_REG, args [4]->dreg, 0, sp [1]->dreg);
+                                                       }
                                                } else {
                                                        EMIT_NEW_ICONST (cfg, args [3], 0);
+                                                       EMIT_NEW_ICONST (cfg, args [4], 0);
                                                }
                                                ins = mono_emit_jit_icall (cfg, mono_gsharedvt_constrained_call, args);
                                                emit_widen = FALSE;
@@ -9295,7 +9313,9 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
                                        EMIT_NEW_PCONST (cfg, args [2], mono_domain_alloc0 (cfg->domain, sizeof (gpointer)));
 
                                /*The wrapper doesn't inline well so the bloat of inlining doesn't pay off.*/
+                               save_cast_details (cfg, klass, sp [0]->dreg);
                                *sp++ = mono_emit_method_call (cfg, mono_castclass, args, NULL);
+                               reset_cast_details (cfg);
                                ip += 5;
                                inline_costs += 2;
                        } else if (!context_used && (mono_class_is_marshalbyref (klass) || klass->flags & TYPE_ATTRIBUTE_INTERFACE)) {
@@ -9306,8 +9326,10 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
                                mono_castclass = mono_marshal_get_castclass (klass); 
                                iargs [0] = sp [0];
                                
+                               save_cast_details (cfg, klass, sp [0]->dreg);
                                costs = inline_method (cfg, mono_castclass, mono_method_signature (mono_castclass), 
                                                           iargs, ip, cfg->real_offset, dont_inline, TRUE);
+                               reset_cast_details (cfg);
                                CHECK_CFG_EXCEPTION;
                                g_assert (costs > 0);
                                
index 73ca5168a3af7aa5f9bf3c453059c314669e4b58..081186e22c2fc59d4e59f16d6a1e4a0f3449d801 100644 (file)
@@ -5713,7 +5713,7 @@ mono_arch_output_basic_block (MonoCompile *cfg, MonoBasicBlock *bb)
                case OP_CARD_TABLE_WBARRIER: {
                        int ptr = ins->sreg1;
                        int value = ins->sreg2;
-                       guchar *br;
+                       guchar *br = 0;
                        int nursery_shift, card_table_shift;
                        gpointer card_table_mask;
                        size_t nursery_size;
@@ -5778,6 +5778,7 @@ mono_arch_output_basic_block (MonoCompile *cfg, MonoBasicBlock *bb)
                        amd64_alu_reg_membase (code, X86_ADD, AMD64_RDX, AMD64_RIP, 0);
 
                        amd64_mov_membase_imm (code, AMD64_RDX, 0, 1, 1);
+
                        if (mono_gc_card_table_nursery_check ())
                                x86_patch (br, code);
                        break;
old mode 100644 (file)
new mode 100755 (executable)
index 9088322..ca38406
@@ -598,7 +598,11 @@ thread_suspend_func (gpointer user_data, void *sigctx, MonoContext *ctx)
                gboolean res;
 
                g_assert (tls->info);
+#ifdef TARGET_WIN32
+               return;
+#else
                res = mono_thread_state_init_from_handle (&tls->unwind_state, (MonoNativeThreadId)tls->tid, tls->info->native_handle);
+#endif
        } else {
                tls->unwind_state.unwind_data [MONO_UNWIND_DATA_LMF] = mono_get_lmf ();
                if (sigctx) {
index 3474e0d7bbc0c7a4950b1d438da9b59021d215bd..b5b8fb550ac411ad65153614fd823f7e837e5d0e 100644 (file)
@@ -1865,6 +1865,10 @@ process_call (EmitContext *ctx, MonoBasicBlock *bb, LLVMBuilderRef *builder_ref,
                                LLVMAddGlobalMapping (ee, callee, target);
                        }
                }
+
+               if (call->method && strstr (call->method->klass->name, "AsyncVoidMethodBuilder"))
+                       /* LLVM miscompiles async methods */
+                       LLVM_FAILURE (ctx, "#13734");
        } else if (calli) {
        } else {
                MonoJitICallInfo *info = mono_find_jit_icall_by_addr (call->fptr);
@@ -4334,19 +4338,6 @@ mono_llvm_emit_method (MonoCompile *cfg)
        }
        g_free (names);
 
-       if (cfg->compile_aot) {
-               LLVMValueRef md_args [16];
-               LLVMValueRef md_node;
-               int method_index;
-
-               method_index = mono_aot_get_method_index (cfg->orig_method);
-               md_args [0] = LLVMMDString (method_name, strlen (method_name));
-               md_args [1] = LLVMConstInt (LLVMInt32Type (), method_index, FALSE);
-               md_node = LLVMMDNode (md_args, 2);
-               LLVMAddNamedMetadataOperand (module, "mono.function_indexes", md_node);
-               //LLVMSetMetadata (method, md_kind, LLVMMDNode (&md_arg, 1));
-       }
-
        max_block_num = 0;
        for (bb = cfg->bb_entry; bb; bb = bb->next_bb)
                max_block_num = MAX (max_block_num, bb->block_num);
@@ -4520,6 +4511,19 @@ mono_llvm_emit_method (MonoCompile *cfg)
 
        mark_as_used (module, method);
 
+       if (cfg->compile_aot) {
+               LLVMValueRef md_args [16];
+               LLVMValueRef md_node;
+               int method_index;
+
+               method_index = mono_aot_get_method_index (cfg->orig_method);
+               md_args [0] = LLVMMDString (method_name, strlen (method_name));
+               md_args [1] = LLVMConstInt (LLVMInt32Type (), method_index, FALSE);
+               md_node = LLVMMDNode (md_args, 2);
+               LLVMAddNamedMetadataOperand (module, "mono.function_indexes", md_node);
+               //LLVMSetMetadata (method, md_kind, LLVMMDNode (&md_arg, 1));
+       }
+
        if (cfg->compile_aot) {
                /* Don't generate native code, keep the LLVM IR */
                if (cfg->compile_aot && cfg->verbose_level)
index 764db673bf5dc792c311074bd0bdc1a58509bf2a..a5be8f01087162cbde7ed649cf1cb945bc0464aa 100644 (file)
@@ -15,7 +15,7 @@
 /*-------------------------------------------*/
 
 #define S390_LONG(loc, opy, op, r, ix, br, off)                                        \
-       if (has_ld) {                                                           \
+       if (mono_hwcap_s390x_has_ld) {                                          \
                if (s390_is_imm20(off)) {                                       \
                        s390_##opy (loc, r, ix, br, off);                       \
                } else {                                                        \
index 80a9c9bf148f26143bf069470aae984825a3fb5c..46a317c4fc460009c139ed1a4101ec62f986910b 100644 (file)
@@ -50,9 +50,7 @@
 
 #include "jit-icalls.h"
 
-extern LPTOP_LEVEL_EXCEPTION_FILTER mono_old_win_toplevel_exception_filter;
-extern guint64 mono_win_chained_exception_filter_result;
-extern gboolean mono_win_chained_exception_filter_didrun;
+gboolean mono_win_chained_exception_needs_run;
 
 void
 mono_runtime_install_handlers (void)
@@ -85,15 +83,8 @@ mono_runtime_cleanup_handlers (void)
 gboolean
 SIG_HANDLER_SIGNATURE (mono_chain_signal)
 {
-       int signal = _dummy;
-       GET_CONTEXT;
-
-       if (mono_old_win_toplevel_exception_filter) {
-               mono_win_chained_exception_filter_didrun = TRUE;
-               mono_win_chained_exception_filter_result = (*mono_old_win_toplevel_exception_filter)(info);
-               return TRUE;
-       }
-       return FALSE;
+       mono_win_chained_exception_needs_run = TRUE;
+       return TRUE;
 }
 
 static HANDLE win32_main_thread;
old mode 100644 (file)
new mode 100755 (executable)
index c16b103..44d5e20
 
 /* On windows, these hold the key returned by TlsAlloc () */
 static gint lmf_tls_offset = -1;
+static gint jit_tls_offset = -1;
+#ifndef TARGET_WIN32
 static gint lmf_addr_tls_offset = -1;
+#endif
 static gint appdomain_tls_offset = -1;
 
 #ifdef MONO_XEN_OPT
@@ -5127,16 +5130,21 @@ mono_arch_emit_prolog (MonoCompile *cfg)
                         * This is performance critical so we try to use some tricks to make
                         * it fast.
                         */                                                                        
+                       gboolean have_fastpath = FALSE;
 
-                       if (lmf_addr_tls_offset != -1) {
-                               /* Load lmf quicky using the GS register */
-                               code = mono_x86_emit_tls_get (code, X86_EAX, lmf_addr_tls_offset);
 #ifdef TARGET_WIN32
-                               /* The TLS key actually contains a pointer to the MonoJitTlsData structure */
-                               /* FIXME: Add a separate key for LMF to avoid this */
+                       if (jit_tls_offset != -1) {
+                               code = mono_x86_emit_tls_get (code, X86_EAX, jit_tls_offset);                           
                                x86_alu_reg_imm (code, X86_ADD, X86_EAX, G_STRUCT_OFFSET (MonoJitTlsData, lmf));
+                               have_fastpath = TRUE;
+                       }
+#else
+                       if (lmf_addr_tls_offset != -1) {
+                               code = mono_x86_emit_tls_get (code, X86_EAX, lmf_addr_tls_offset);
+                               have_fastpath = TRUE;
+                       }
 #endif
-                       } else {
+                       if (!have_fastpath) {
                                if (cfg->compile_aot)
                                        code = mono_arch_emit_load_got_addr (cfg->native_code, code, cfg, NULL);
                                code = emit_call (cfg, code, MONO_PATCH_INFO_INTERNAL_METHOD, (gpointer)"mono_get_lmf_addr");
@@ -5634,13 +5642,13 @@ mono_arch_finish_init (void)
                 * be initialized yet.
                 */
                appdomain_tls_offset = mono_domain_get_tls_key ();
-               lmf_tls_offset = mono_get_jit_tls_key ();
+               jit_tls_offset = mono_get_jit_tls_key ();
 
                /* Only 64 tls entries can be accessed using inline code */
                if (appdomain_tls_offset >= 64)
                        appdomain_tls_offset = -1;
-               if (lmf_tls_offset >= 64)
-                       lmf_tls_offset = -1;
+               if (jit_tls_offset >= 64)
+                       jit_tls_offset = -1;
 #else
 #if MONO_XEN_OPT
                optimize_for_xen = access ("/proc/xen", F_OK) == 0;
@@ -6610,7 +6618,7 @@ mono_arch_is_single_step_event (void *info, void *sigctx)
 #ifdef TARGET_WIN32
        EXCEPTION_RECORD* einfo = ((EXCEPTION_POINTERS*)info)->ExceptionRecord; /* Sometimes the address is off by 4 */
 
-       if ((einfo->ExceptionInformation[1] >= ss_trigger_page && (guint8*)einfo->ExceptionInformation[1] <= (guint8*)ss_trigger_page + 128))
+       if (((gpointer)einfo->ExceptionInformation[1] >= ss_trigger_page && (guint8*)einfo->ExceptionInformation[1] <= (guint8*)ss_trigger_page + 128))
                return TRUE;
        else
                return FALSE;
@@ -6629,7 +6637,7 @@ mono_arch_is_breakpoint_event (void *info, void *sigctx)
 {
 #ifdef TARGET_WIN32
        EXCEPTION_RECORD* einfo = ((EXCEPTION_POINTERS*)info)->ExceptionRecord; /* Sometimes the address is off by 4 */
-       if ((einfo->ExceptionInformation[1] >= bp_trigger_page && (guint8*)einfo->ExceptionInformation[1] <= (guint8*)bp_trigger_page + 128))
+       if (((gpointer)einfo->ExceptionInformation[1] >= bp_trigger_page && (guint8*)einfo->ExceptionInformation[1] <= (guint8*)bp_trigger_page + 128))
                return TRUE;
        else
                return FALSE;
index cfe9d520ecf20d0228b6947de75573fcd738d230..e6e14311c2765296dd2cb278bacf32ee7489d3ac 100644 (file)
@@ -7255,7 +7255,7 @@ mini_init (const char *filename, const char *runtime_version)
        register_icall (mono_helper_ldstr_mscorlib, "mono_helper_ldstr_mscorlib", "object int", FALSE);
        register_icall (mono_helper_newobj_mscorlib, "mono_helper_newobj_mscorlib", "object int", FALSE);
        register_icall (mono_value_copy, "mono_value_copy", "void ptr ptr ptr", FALSE);
-       register_icall (mono_object_castclass, "mono_object_castclass", "object object ptr", FALSE);
+       register_icall (mono_object_castclass_unbox, "mono_object_castclass_unbox", "object object ptr", FALSE);
        register_icall (mono_break, "mono_break", NULL, TRUE);
        register_icall (mono_create_corlib_exception_0, "mono_create_corlib_exception_0", "object int", TRUE);
        register_icall (mono_create_corlib_exception_1, "mono_create_corlib_exception_1", "object int object", TRUE);
@@ -7266,7 +7266,7 @@ mini_init (const char *filename, const char *runtime_version)
        register_icall (mono_array_new_4, "mono_array_new_4", "object ptr int int int int", FALSE);
        register_icall (mono_get_native_calli_wrapper, "mono_get_native_calli_wrapper", "ptr ptr ptr ptr", FALSE);
        register_icall (mono_resume_unwind, "mono_resume_unwind", "void", TRUE);
-       register_icall (mono_gsharedvt_constrained_call, "mono_gsharedvt_constrained_call", "object ptr ptr ptr ptr", TRUE);
+       register_icall (mono_gsharedvt_constrained_call, "mono_gsharedvt_constrained_call", "object ptr ptr ptr ptr ptr", TRUE);
        register_icall (mono_gsharedvt_value_copy, "mono_gsharedvt_value_copy", "void ptr ptr ptr", TRUE);
 
        register_icall (mono_gc_wbarrier_value_copy_bitmap, "mono_gc_wbarrier_value_copy_bitmap", "void ptr ptr int int", FALSE);
index a0867f06baf5d163082324031f52f36dea76e350..7102b276fb90e5e8bdae9c63a1d246ddabd455fb 100644 (file)
@@ -1871,8 +1871,8 @@ enum {
 typedef void (*MonoInstFunc) (MonoInst *tree, gpointer data);
 
 /* main function */
-int         mono_main                      (int argc, char* argv[]);
-void        mono_set_defaults              (int verbose_level, guint32 opts);
+MONO_API int         mono_main                      (int argc, char* argv[]);
+MONO_API void        mono_set_defaults              (int verbose_level, guint32 opts);
 MonoDomain* mini_init                      (const char *filename, const char *runtime_version) MONO_INTERNAL;
 void        mini_cleanup                   (MonoDomain *domain) MONO_INTERNAL;
 MonoDebugOptions *mini_get_debug_options   (void) MONO_INTERNAL;
@@ -1888,7 +1888,7 @@ MonoInst* mono_find_exvar_for_offset        (MonoCompile *cfg, int offset) MONO_
 int       mono_get_block_region_notry       (MonoCompile *cfg, int region) MONO_LLVM_INTERNAL;
 
 void      mono_precompile_assemblies        (void) MONO_INTERNAL;
-int       mono_parse_default_optimizations  (const char* p);
+MONO_API int       mono_parse_default_optimizations  (const char* p);
 void      mono_bblock_add_inst              (MonoBasicBlock *bb, MonoInst *inst) MONO_LLVM_INTERNAL;
 void      mono_bblock_insert_after_ins      (MonoBasicBlock *bb, MonoInst *ins, MonoInst *ins_to_insert) MONO_INTERNAL;
 void      mono_bblock_insert_before_ins     (MonoBasicBlock *bb, MonoInst *ins, MonoInst *ins_to_insert) MONO_INTERNAL;
@@ -1929,10 +1929,10 @@ void      mono_print_ins_index              (int i, MonoInst *ins) MONO_INTERNAL
 void      mono_print_ins                    (MonoInst *ins) MONO_INTERNAL;
 void      mono_print_bb                     (MonoBasicBlock *bb, const char *msg) MONO_INTERNAL;
 void      mono_print_code                   (MonoCompile *cfg, const char *msg) MONO_INTERNAL;
-void      mono_print_method_from_ip         (void *ip);
-char     *mono_pmip                         (void *ip);
+MONO_API void      mono_print_method_from_ip         (void *ip);
+MONO_API char     *mono_pmip                         (void *ip);
 gboolean  mono_debug_count                  (void) MONO_INTERNAL;
-const char* mono_inst_name                  (int op);
+MONO_API const char* mono_inst_name                  (int op);
 void      mono_inst_set_src_registers       (MonoInst *ins, int *regs) MONO_INTERNAL;
 int       mono_op_to_op_imm                 (int opcode) MONO_INTERNAL;
 int       mono_op_imm_to_op                 (int opcode) MONO_INTERNAL;
@@ -1955,8 +1955,8 @@ gpointer  mono_jit_compile_method           (MonoMethod *method) MONO_INTERNAL;
 MonoLMF * mono_get_lmf                      (void) MONO_INTERNAL;
 MonoLMF** mono_get_lmf_addr                 (void) MONO_INTERNAL;
 void      mono_set_lmf                      (MonoLMF *lmf) MONO_INTERNAL;
-MonoDomain *mono_jit_thread_attach          (MonoDomain *domain);
-void      mono_jit_set_domain               (MonoDomain *domain);
+MONO_API MonoDomain *mono_jit_thread_attach          (MonoDomain *domain);
+MONO_API void      mono_jit_set_domain               (MonoDomain *domain);
 MonoNativeTlsKey mono_get_jit_tls_key       (void) MONO_INTERNAL;
 gint32    mono_get_jit_tls_offset           (void) MONO_INTERNAL;
 gint32    mono_get_lmf_tls_offset           (void) MONO_INTERNAL;
@@ -2077,9 +2077,9 @@ void     mono_aot_register_jit_icall        (const char *name, gpointer addr) MO
 void*    mono_aot_readonly_field_override   (MonoClassField *field) MONO_INTERNAL;
 
 /* This is an exported function */
-void     mono_aot_register_globals          (gpointer *globals);
+MONO_API void     mono_aot_register_globals          (gpointer *globals);
 /* This too */
-void     mono_aot_register_module           (gpointer *aot_info);
+MONO_API void     mono_aot_register_module           (gpointer *aot_info);
 
 void     mono_xdebug_init                   (char *xdebug_opts) MONO_INTERNAL;
 void     mono_save_xdebug_info              (MonoCompile *cfg) MONO_INTERNAL;
@@ -2104,7 +2104,7 @@ void      mono_draw_graph                   (MonoCompile *cfg, MonoGraphOptions
 void      mono_add_ins_to_end               (MonoBasicBlock *bb, MonoInst *inst) MONO_INTERNAL;
 gpointer  mono_create_ftnptr                (MonoDomain *domain, gpointer addr) MONO_INTERNAL;
 
-void      mono_replace_ins                  (MonoCompile *cfg, MonoBasicBlock *bb, MonoInst *ins, MonoInst **prev, MonoBasicBlock *first_bb, MonoBasicBlock *last_bb);
+MONO_API void      mono_replace_ins                  (MonoCompile *cfg, MonoBasicBlock *bb, MonoInst *ins, MonoInst **prev, MonoBasicBlock *first_bb, MonoBasicBlock *last_bb);
 
 int               mono_find_method_opcode      (MonoMethod *method) MONO_INTERNAL;
 MonoJitICallInfo *mono_register_jit_icall      (gconstpointer func, const char *name, MonoMethodSignature *sig, gboolean is_save) MONO_INTERNAL;
@@ -2373,8 +2373,8 @@ typedef gboolean (*MonoJitStackWalk)            (StackFrameInfo *frame, MonoCont
 void     mono_exceptions_init                   (void) MONO_INTERNAL;
 gboolean mono_handle_exception                  (MonoContext *ctx, gpointer obj) MONO_INTERNAL;
 void     mono_handle_native_sigsegv             (int signal, void *sigctx) MONO_INTERNAL;
-void     mono_print_thread_dump                 (void *sigctx);
-void     mono_print_thread_dump_from_ctx        (MonoContext *ctx);
+MONO_API void     mono_print_thread_dump                 (void *sigctx);
+MONO_API void     mono_print_thread_dump_from_ctx        (MonoContext *ctx);
 void     mono_walk_stack_with_ctx               (MonoJitStackWalk func, MonoContext *start_ctx, MonoUnwindOptions unwind_options, void *user_data) MONO_INTERNAL;
 void     mono_walk_stack_with_state             (MonoJitStackWalk func, MonoThreadUnwindState *state, MonoUnwindOptions unwind_options, void *user_data) MONO_INTERNAL;
 void     mono_walk_stack                        (MonoJitStackWalk func, MonoUnwindOptions options, void *user_data) MONO_INTERNAL;
@@ -2452,12 +2452,12 @@ void      mono_debug_add_aot_method             (MonoDomain *domain,
                                                 MonoMethod *method, guint8 *code_start, 
                                                 guint8 *debug_info, guint32 debug_info_len) MONO_INTERNAL;
 void      mono_debug_add_icall_wrapper          (MonoMethod *method, MonoJitICallInfo* info) MONO_INTERNAL;
-void      mono_debug_print_vars                 (gpointer ip, gboolean only_arguments);
-void      mono_debugger_run_finally             (MonoContext *start_ctx);
+MONO_API void      mono_debug_print_vars                 (gpointer ip, gboolean only_arguments);
+MONO_API void      mono_debugger_run_finally             (MonoContext *start_ctx);
 
 extern gssize mono_breakpoint_info_index [MONO_BREAKPOINT_ARRAY_SIZE];
 
-gboolean mono_breakpoint_clean_code (guint8 *method_start, guint8 *code, int offset, guint8 *buf, int size);
+MONO_API gboolean mono_breakpoint_clean_code (guint8 *method_start, guint8 *code, int offset, guint8 *buf, int size);
 
 #ifdef MONO_DEBUGGER_SUPPORTED
 
index 95c281f5982499569357091b6940238b53a87b67..c19e95b279f49cd7fbbe417d699975e4be3d331e 100644 (file)
@@ -875,6 +875,11 @@ test-type-load: TestDriver.dll
        @echo "Testing load-exception.exe..."
        @$(RUNTIME) load-exceptions.exe > load-exceptions.exe.stdout 2> load-exceptions.exe.stderr
 
+EXTRA_DIST += debug-casts.cs
+# This depends on TLS, so its not ran by default
+debug-casts:
+       @$(MCS) -r:TestDriver.dll $(srcdir)/debug-casts.cs
+       @$(RUNTIME) --debug=casts debug-casts.exe
 
 EXTRA_DIST += sgen-bridge.cs sgen-descriptors.cs sgen-gshared-vtype.cs sgen-bridge-major-fragmentation.cs sgen-domain-unload.cs sgen-weakref-stress.cs sgen-cementing-stress.cs sgen-case-23400.cs     finalizer-wait.cs critical-finalizers.cs sgen-domain-unload-2.cs sgen-suspend.cs
 
old mode 100644 (file)
new mode 100755 (executable)
old mode 100644 (file)
new mode 100755 (executable)
index baee70a..0f79342
@@ -28,7 +28,7 @@ class Program
         // ThreadPool has been shutdown, thus `a.BeginInvoke()` has no effect.
         Action a = () => {
             int i = 0;
-            while (true)
+                       while (i < 1024)
                 Console.WriteLine ("Ha! {0}", i++);
         };
         a.BeginInvoke (null, null);
diff --git a/mono/tests/debug-casts.cs b/mono/tests/debug-casts.cs
new file mode 100644 (file)
index 0000000..fafa7ef
--- /dev/null
@@ -0,0 +1,33 @@
+using System;
+using System.Collections.Generic;
+
+public class Tests
+{
+       public static int Main (string[] args) {
+               return TestDriver.RunTests (typeof (Tests), args);
+       }
+
+       public static int test_0_simple () {
+               object o = new object ();
+               try {
+                       string s = (string)o;
+                       return 1;
+               } catch (InvalidCastException ex) {
+                       if (!ex.Message.Contains ("System.Object") || !ex.Message.Contains ("System.String"))
+                               return 2;
+               }
+               return 0;
+       }
+
+       public static int test_0_complex_1 () {
+               object o = new object ();
+               try {
+                       IEnumerable<object> ie = (IEnumerable<object>)o;
+                       return 1;
+               } catch (InvalidCastException ex) {
+                       if (!ex.Message.Contains ("System.Object") || !ex.Message.Contains ("System.Collections.Generic.IEnumerable`1[System.Object]"))
+                               return 2;
+               }
+               return 0;
+       }
+}
index 1496dc54b476a8d1e9b3bfe11895500e59a79ea6..f11a1dcdeffd2ce3eb23d16d088a431977b999aa 100644 (file)
@@ -10,7 +10,9 @@ public class FinalizerException {
         * We allocate the exception object deep down the stack so
         * that it doesn't get pinned.
         */
-       public static void MakeException (int depth) {
+       public static unsafe void MakeException (int depth) {
+               // Avoid tail calls
+               int* values = stackalloc int [20];
                if (depth <= 0) {
                        new FinalizerException ();
                        return;
@@ -24,7 +26,7 @@ public class FinalizerException {
                        Environment.Exit (0);
                };
 
-               MakeException (100);
+               MakeException (1024);
 
                GC.Collect ();
                GC.WaitForPendingFinalizers ();
old mode 100644 (file)
new mode 100755 (executable)
index 869850e..4daa22b
@@ -14,3 +14,6 @@ descriptor-tests.cs : descriptor-tests-driver.cs descriptor-tests-prefix.cs gen-
        $(srcdir)/gen-descriptor-tests.py >descriptor-tests.cs
 
 EXTRA_DIST = descriptor-tests-driver.cs descriptor-tests-prefix.cs gen-descriptor-tests.py
+
+.DELETE_ON_ERROR:
+
index 6945eb9b4884a69efa251ef91a744a2db283da3f..b007040a62e95d33de04e626bec61a729dbeef22 100755 (executable)
@@ -34,6 +34,7 @@ $| = 0;
 print "Testing $test... ";
 
 foreach $disabled (split (/ /, $disabled_tests)) {
+       $disabled =~ s/^\s+|\s+$//g;
        if ($disabled eq $test) {
                print "disabled.\n";
                exit (0);
index 9ca6ed4a0fa41835cc61ab7f5674bc92e39a4549..349df1fa726350b05947e28d2cdeb66071245393 100644 (file)
@@ -2511,6 +2511,7 @@ static int init_mparams(void) {
   return 0;
 }
 
+#if 0
 /* support for mallopt */
 static int change_mparam(int param_number, int value) {
   size_t val = (size_t)value;
@@ -2533,6 +2534,7 @@ static int change_mparam(int param_number, int value) {
     return 0;
   }
 }
+#endif
 
 #if DEBUG
 /* ------------------------- Debugging Support --------------------------- */
@@ -2844,6 +2846,7 @@ static struct mallinfo internal_mallinfo(mstate m) {
 }
 #endif /* !NO_MALLINFO */
 
+#if 0
 static void internal_malloc_stats(mstate m) {
   if (!PREACTION(m)) {
     size_t maxfp = 0;
@@ -2875,6 +2878,7 @@ static void internal_malloc_stats(mstate m) {
     POSTACTION(m);
   }
 }
+#endif
 
 /* ----------------------- Operations on smallbins ----------------------- */
 
index 2c3c7e2809d795c0f00e2dcfa4f2a8cf84b78718..17d53b3b0328ab81161646b1e4fade010c367af2 100644 (file)
@@ -1,21 +1,23 @@
 #ifndef __MONO_CODEMAN_H__
 #define __MONO_CODEMAN_H__
 
+#include <mono/utils/mono-publib.h>
+
 typedef struct _MonoCodeManager MonoCodeManager;
 
-MonoCodeManager* mono_code_manager_new     (void);
-MonoCodeManager* mono_code_manager_new_dynamic (void);
-void             mono_code_manager_destroy (MonoCodeManager *cman);
-void             mono_code_manager_invalidate (MonoCodeManager *cman);
-void             mono_code_manager_set_read_only (MonoCodeManager *cman);
+MONO_API MonoCodeManager* mono_code_manager_new     (void);
+MONO_API MonoCodeManager* mono_code_manager_new_dynamic (void);
+MONO_API void             mono_code_manager_destroy (MonoCodeManager *cman);
+MONO_API void             mono_code_manager_invalidate (MonoCodeManager *cman);
+MONO_API void             mono_code_manager_set_read_only (MonoCodeManager *cman);
 
-void*            mono_code_manager_reserve_align (MonoCodeManager *cman, int size, int alignment);
+MONO_API void*            mono_code_manager_reserve_align (MonoCodeManager *cman, int size, int alignment);
 
-void*            mono_code_manager_reserve (MonoCodeManager *cman, int size);
-void             mono_code_manager_commit  (MonoCodeManager *cman, void *data, int size, int newsize);
-int              mono_code_manager_size    (MonoCodeManager *cman, int *used_size);
-void             mono_code_manager_init (void);
-void             mono_code_manager_cleanup (void);
+MONO_API void*            mono_code_manager_reserve (MonoCodeManager *cman, int size);
+MONO_API void             mono_code_manager_commit  (MonoCodeManager *cman, void *data, int size, int newsize);
+MONO_API int              mono_code_manager_size    (MonoCodeManager *cman, int *used_size);
+MONO_API void             mono_code_manager_init (void);
+MONO_API void             mono_code_manager_cleanup (void);
 
 /* find the extra block allocated to resolve branches close to code */
 typedef int    (*MonoCodeManagerFunc)      (void *data, int csize, int size, void *user_data);
old mode 100644 (file)
new mode 100755 (executable)
index 43ceb84..84409cf
@@ -105,6 +105,24 @@ typedef struct {
 #define MONO_CONTEXT_GET_SP(ctx) ((gpointer)((ctx)->esp))
 
 /*We set EAX to zero since we are clobering it anyway*/
+#ifdef _MSC_VER
+#define MONO_CONTEXT_GET_CURRENT(ctx) do { \
+       void *_ptr = &(ctx);                                                                                            \
+       __asm {                                                                                                                         \
+        __asm mov eax, _ptr                                                                                            \
+        __asm mov [eax+0x00], eax                                                                                      \
+        __asm mov [eax+0x04], ebx                                                                                      \
+        __asm mov [eax+0x08], ecx                                                                                      \
+        __asm mov [eax+0x0c], edx                                                                                      \
+        __asm mov [eax+0x10], ebp                                                                                      \
+        __asm mov [eax+0x14], esp                                                                                      \
+        __asm mov [eax+0x18], esi                                                                                      \
+        __asm mov [eax+0x1c], edi                                                                                      \
+        __asm call $+5                                                                                                         \
+        __asm pop dword ptr [eax+0x20]                                                                         \
+                }                                                                                                                              \
+       } while (0)
+#else
 #define MONO_CONTEXT_GET_CURRENT(ctx) \
        __asm__ __volatile__(   \
        "movl $0x0, 0x00(%0)\n" \
@@ -120,10 +138,9 @@ typedef struct {
        :       \
        : "a" (&(ctx))  \
        : "memory")
+#endif
 
-#if !defined(HOST_WIN32)
 #define MONO_ARCH_HAS_MONO_CONTEXT 1
-#endif
 
 #elif (defined(__x86_64__) && !defined(MONO_CROSS_COMPILE)) || (defined(TARGET_AMD64)) /* defined(__i386__) */
 
index 07aeb7902e3e9e714a5977035705f6216340f103..f18212f90bfdc535588ad8cf1ec5d455fe04f60f 100644 (file)
@@ -25,21 +25,21 @@ enum {
        MONO_COUNTER_LAST_SECTION
 };
 
-void mono_counters_enable (int section_mask);
+MONO_API void mono_counters_enable (int section_mask);
 
 /* 
  * register addr as the address of a counter of type type.
  * It may be a function pointer if MONO_COUNTER_CALLBACK is specified:
  * the function should return the value and take no arguments.
  */
-void mono_counters_register (const char* descr, int type, void *addr);
+MONO_API void mono_counters_register (const char* descr, int type, void *addr);
 
 /* 
  * Create a readable dump of the counters for section_mask sections (ORed section values)
  */
-void mono_counters_dump (int section_mask, FILE *outfile);
+MONO_API void mono_counters_dump (int section_mask, FILE *outfile);
 
-void mono_counters_cleanup (void);
+MONO_API void mono_counters_cleanup (void);
 
 typedef enum {
        MONO_RESOURCE_JIT_CODE, /* bytes */
@@ -50,9 +50,9 @@ typedef enum {
 
 typedef void (*MonoResourceCallback) (int resource_type, uintptr_t value, int is_soft);
 
-int  mono_runtime_resource_limit        (int resource_type, uintptr_t soft_limit, uintptr_t hard_limit);
-void mono_runtime_resource_set_callback (MonoResourceCallback callback);
-void mono_runtime_resource_check_limit  (int resource_type, uintptr_t value);
+MONO_API int  mono_runtime_resource_limit        (int resource_type, uintptr_t soft_limit, uintptr_t hard_limit);
+MONO_API void mono_runtime_resource_set_callback (MonoResourceCallback callback);
+MONO_API void mono_runtime_resource_check_limit  (int resource_type, uintptr_t value);
 
 #endif /* __MONO_COUNTERS_H__ */
 
index 4ef5d3e7e30288fef376dd62c2d8dd216ac9fc07..5cef8ee741b7e7cd21248da3a0de37ab2dc9cf05 100644 (file)
@@ -28,6 +28,7 @@
 
 #include <config.h>
 #include <glib.h>
+#include <mono/utils/mono-publib.h>
 
 G_BEGIN_DECLS
 
@@ -49,16 +50,16 @@ typedef struct {
 
 #endif
 
-void mono_md5_get_digest (const guchar *buffer, gint buffer_size, guchar digest[16]);
+MONO_API void mono_md5_get_digest (const guchar *buffer, gint buffer_size, guchar digest[16]);
 
 /* use this one when speed is needed */
 /* for use in provider code only */
-void mono_md5_get_digest_from_file (const gchar *filename, guchar digest[16]);
+MONO_API void mono_md5_get_digest_from_file (const gchar *filename, guchar digest[16]);
 
 /* raw routines */
-void mono_md5_init   (MonoMD5Context *ctx);
-void mono_md5_update (MonoMD5Context *ctx, const guchar *buf, guint32 len);
-void mono_md5_final  (MonoMD5Context *ctx, guchar digest[16]);
+MONO_API void mono_md5_init   (MonoMD5Context *ctx);
+MONO_API void mono_md5_update (MonoMD5Context *ctx, const guchar *buf, guint32 len);
+MONO_API void mono_md5_final  (MonoMD5Context *ctx, guchar digest[16]);
 
 #if !HAVE_COMMONCRYPTO_COMMONDIGEST_H
 
@@ -70,14 +71,14 @@ typedef struct {
 
 #endif
 
-void mono_sha1_get_digest (const guchar *buffer, gint buffer_size, guchar digest [20]);
-void mono_sha1_get_digest_from_file (const gchar *filename, guchar digest [20]);
+MONO_API void mono_sha1_get_digest (const guchar *buffer, gint buffer_size, guchar digest [20]);
+MONO_API void mono_sha1_get_digest_from_file (const gchar *filename, guchar digest [20]);
 
-void mono_sha1_init   (MonoSHA1Context* context);
-void mono_sha1_update (MonoSHA1Context* context, const guchar* data, guint32 len);
-void mono_sha1_final  (MonoSHA1Context* context, unsigned char digest[20]);
+MONO_API void mono_sha1_init   (MonoSHA1Context* context);
+MONO_API void mono_sha1_update (MonoSHA1Context* context, const guchar* data, guint32 len);
+MONO_API void mono_sha1_final  (MonoSHA1Context* context, unsigned char digest[20]);
 
-void mono_digest_get_public_token (guchar* token, const guchar *pubkey, guint32 len);
+MONO_API void mono_digest_get_public_token (guchar* token, const guchar *pubkey, guint32 len);
 
 G_END_DECLS
 #endif /* __MONO_DIGEST_H__ */
index 06945aed1b1a29158ab16a34078a8a8e9687ddb0..97b13c6c189b5d4707234e5de28797e82228b016 100644 (file)
@@ -23,10 +23,10 @@ typedef void* (*MonoDlFallbackLoad) (const char *name, int flags, char **err, vo
 typedef void* (*MonoDlFallbackSymbol) (void *handle, const char *name, char **err, void *user_data);
 typedef void* (*MonoDlFallbackClose) (void *handle, void *user_data);
 
-MonoDlFallbackHandler *mono_dl_fallback_register (MonoDlFallbackLoad load_func, MonoDlFallbackSymbol symbol_func,
+MONO_API MonoDlFallbackHandler *mono_dl_fallback_register (MonoDlFallbackLoad load_func, MonoDlFallbackSymbol symbol_func,
                                                  MonoDlFallbackClose close_func, void *user_data);
 
-void                   mono_dl_fallback_unregister (MonoDlFallbackHandler *handler);
+MONO_API void                   mono_dl_fallback_unregister (MonoDlFallbackHandler *handler);
 
 MONO_END_DECLS
 
index 2a8a697a1e7109c41c255299545d7cb3464dd642..78453e81ad0c1e12e11e325b87c9b3522146323e 100755 (executable)
@@ -13,7 +13,7 @@ typedef struct {
        void *addr;
 } MonoDlMapping;
 
-void mono_dl_register_library (const char *name, MonoDlMapping *mappings);
+MONO_API void mono_dl_register_library (const char *name, MonoDlMapping *mappings);
 
 MONO_END_DECLS
 
index b7d6029103941a5c2ebfb6201ee1c0efa9f93bbd..5652432adb15282bd0dc121df65e50604e9f81b5 100644 (file)
@@ -43,22 +43,22 @@ typedef struct {
 
 MONO_BEGIN_DECLS
 
-void
+MONO_API void
 mono_error_init (MonoError *error);
 
-void
+MONO_API void
 mono_error_init_flags (MonoError *error, unsigned short flags);
 
-void
+MONO_API void
 mono_error_cleanup (MonoError *error);
 
-mono_bool
+MONO_API mono_bool
 mono_error_ok (MonoError *error);
 
-unsigned short
+MONO_API unsigned short
 mono_error_get_error_code (MonoError *error);
 
-const char*
+MONO_API const char*
 mono_error_get_message (MonoError *error);
 
 MONO_END_DECLS
index 138ad7c2f7667d16ce7e037c62f0a471e77ef7fc..d5d5f00ecb397323b208350881f85a706e77dc80 100644 (file)
 
 #include "mono/utils/mono-hwcap-arm.h"
 
-#if defined(PLATFORM_ANDROID)
-#include <stdio.h>
-#elif defined(__linux__) && defined(HAVE_SYS_AUXV_H)
+#if defined(HAVE_SYS_AUXV_H) && !defined(PLATFORM_ANDROID)
 #include <sys/auxv.h>
 #elif defined(__APPLE__)
 #include <mach/machine.h>
 #include <sys/sysctl.h>
 #include <sys/types.h>
+#else
+#include <stdio.h>
 #endif
 
 gboolean mono_hwcap_arm_is_v5 = FALSE;
@@ -47,53 +47,7 @@ mono_hwcap_arch_init (void)
 void
 mono_hwcap_arch_init (void)
 {
-#if defined(PLATFORM_ANDROID)
-       /* We can't use the auxiliary vector on Android due to
-        * permissions, so fall back to /proc/cpuinfo.
-        */
-
-       char buf [512];
-       char *line;
-
-       FILE *file = fopen ("/proc/cpuinfo", "r");
-
-       if (file) {
-               while ((line = fgets (buf, 512, file))) {
-                       if (!strncmp (line, "Processor", 9)) {
-                               char *ver = strstr (line, "(v");
-
-                               if (ver) {
-                                       if (ver [2] >= '5')
-                                               mono_hwcap_arm_is_v5 = TRUE;
-
-                                       if (ver [2] >= '6')
-                                               mono_hwcap_arm_is_v6 = TRUE;
-
-                                       if (ver [2] >= '7')
-                                               mono_hwcap_arm_is_v7 = TRUE;
-
-                                       /* TODO: Find a way to detect v7s. */
-                               }
-
-                               continue;
-                       }
-
-                       if (!strncmp (line, "Features", 8)) {
-                               if (strstr (line, "thumb"))
-                                       mono_hwcap_arm_has_thumb = TRUE;
-
-                               /* TODO: Find a way to detect Thumb 2. */
-
-                               if (strstr (line, "vfp"))
-                                       mono_hwcap_arm_has_vfp = TRUE;
-
-                               continue;
-                       }
-               }
-
-               fclose (file);
-       }
-#elif defined(__linux__) && defined(HAVE_SYS_AUXV_H)
+#if defined(HAVE_SYS_AUXV_H) && !defined(PLATFORM_ANDROID)
        unsigned long hwcap;
        unsigned long platform;
 
@@ -141,6 +95,53 @@ mono_hwcap_arch_init (void)
        }
 
        /* TODO: Find a way to detect features like Thumb and VFP. */
+#else
+       /* We can't use the auxiliary vector on Android due to
+        * permissions, so fall back to /proc/cpuinfo. We also
+        * hit this path if the target doesn't have sys/auxv.h.
+        */
+
+       char buf [512];
+       char *line;
+
+       FILE *file = fopen ("/proc/cpuinfo", "r");
+
+       if (file) {
+               while ((line = fgets (buf, 512, file))) {
+                       if (!strncmp (line, "Processor", 9)) {
+                               char *ver = strstr (line, "(v");
+
+                               if (ver) {
+                                       if (ver [2] >= '5')
+                                               mono_hwcap_arm_is_v5 = TRUE;
+
+                                       if (ver [2] >= '6')
+                                               mono_hwcap_arm_is_v6 = TRUE;
+
+                                       if (ver [2] >= '7')
+                                               mono_hwcap_arm_is_v7 = TRUE;
+
+                                       /* TODO: Find a way to detect v7s. */
+                               }
+
+                               continue;
+                       }
+
+                       if (!strncmp (line, "Features", 8)) {
+                               if (strstr (line, "thumb"))
+                                       mono_hwcap_arm_has_thumb = TRUE;
+
+                               /* TODO: Find a way to detect Thumb 2. */
+
+                               if (strstr (line, "vfp"))
+                                       mono_hwcap_arm_has_vfp = TRUE;
+
+                               continue;
+                       }
+               }
+
+               fclose (file);
+       }
 #endif
 }
 #endif
index fc0745bec72528dce072121ee642039ca4a1c572..3f07378c769bc68b668eefdd378ca45e88dbfe7c 100644 (file)
@@ -4,10 +4,10 @@
 #include <mono/utils/mono-publib.h>
 MONO_BEGIN_DECLS
 
-void 
+MONO_API void 
 mono_trace_set_level_string (const char *value);
 
-void 
+MONO_API void 
 mono_trace_set_mask_string (const char *value);
 
 MONO_END_DECLS
index 90d14b6c611f9888839b22a5ca17db75b4bb6a99..46499c2a25a9e3a6081cab3928d040e32da2c34f 100644 (file)
@@ -3,16 +3,17 @@
 #define __MONO_SIGNBIT_H__
 
 #include <math.h>
+#include <mono/utils/mono-publib.h>
 
 #ifdef HAVE_SIGNBIT
 #define mono_signbit signbit
 #else
 #define mono_signbit(x) (sizeof (x) == sizeof (float) ? mono_signbit_float (x) : mono_signbit_double (x))
 
-int
+MONO_API int
 mono_signbit_double (double x);
 
-int
+MONO_API int
 mono_signbit_float (float x);
 
 #endif
index d454ed067e5c1fbe36a0e85eb1f3237cb1105346..c32bab8c82bcf1651be092783aee68c6a4d3f5df 100644 (file)
 #include <glib.h>
 
 #ifdef _MSC_VER
-#include <Windows.h>
+#ifndef WIN32_LEAN_AND_MEAN
+#define WIN32_LEAN_AND_MEAN
+#endif
+#include <windows.h>
 #include <intrin.h>
 
 static inline void mono_memory_barrier (void)
@@ -43,7 +46,7 @@ static inline void mono_memory_write_barrier (void)
        MemoryBarrier ();
 }
 #elif defined(__WIN32__) || defined(_WIN32)
-#include <Windows.h>
+#include <windows.h>
 
 /* Since we only support GCC 3.x in Cygwin for
    some arcane reason, we have to use inline
index 36997e074890904f61ed03cfb79fa8f2f43d7363..017bbcec5bb6aab1b023661caa5b2102b17469b7 100644 (file)
@@ -2,6 +2,7 @@
 #define __MONO_UTILS_MMAP_H__
 
 #include <glib.h>
+#include <mono/utils/mono-publib.h>
 
 enum {
        /* protection */
@@ -24,28 +25,28 @@ enum {
  */
 typedef struct _MonoFileMap MonoFileMap;
 
-MonoFileMap *mono_file_map_open  (const char* name);
-guint64      mono_file_map_size  (MonoFileMap *fmap);
-int          mono_file_map_fd    (MonoFileMap *fmap);
-int          mono_file_map_close (MonoFileMap *fmap);
-
-int   mono_pagesize   (void);
-void* mono_valloc     (void *addr, size_t length, int flags);
-void* mono_valloc_aligned (size_t length, size_t alignment, int flags);
-int   mono_vfree      (void *addr, size_t length);
-void* mono_file_map   (size_t length, int flags, int fd, guint64 offset, void **ret_handle);
-int   mono_file_unmap (void *addr, void *handle);
+MONO_API MonoFileMap *mono_file_map_open  (const char* name);
+MONO_API guint64      mono_file_map_size  (MonoFileMap *fmap);
+MONO_API int          mono_file_map_fd    (MonoFileMap *fmap);
+MONO_API int          mono_file_map_close (MonoFileMap *fmap);
+
+MONO_API int   mono_pagesize   (void);
+MONO_API void* mono_valloc     (void *addr, size_t length, int flags);
+MONO_API void* mono_valloc_aligned (size_t length, size_t alignment, int flags);
+MONO_API int   mono_vfree      (void *addr, size_t length);
+MONO_API void* mono_file_map   (size_t length, int flags, int fd, guint64 offset, void **ret_handle);
+MONO_API int   mono_file_unmap (void *addr, void *handle);
 #ifndef HOST_WIN32
-void* mono_file_map_fileio   (size_t length, int flags, int fd, guint64 offset, void **ret_handle);
-int   mono_file_unmap_fileio (void *addr, void *handle);
+MONO_API void* mono_file_map_fileio   (size_t length, int flags, int fd, guint64 offset, void **ret_handle);
+MONO_API int   mono_file_unmap_fileio (void *addr, void *handle);
 #endif
-int   mono_mprotect   (void *addr, size_t length, int flags);
+MONO_API int   mono_mprotect   (void *addr, size_t length, int flags);
 
-void* mono_shared_area         (void);
-void  mono_shared_area_remove  (void);
-void* mono_shared_area_for_pid (void *pid);
-void  mono_shared_area_unload  (void *area);
-int   mono_shared_area_instances (void **array, int count);
+MONO_API void* mono_shared_area         (void);
+MONO_API void  mono_shared_area_remove  (void);
+MONO_API void* mono_shared_area_for_pid (void *pid);
+MONO_API void  mono_shared_area_unload  (void *area);
+MONO_API int   mono_shared_area_instances (void **array, int count);
 
 /*
  * On systems where we have to load code into memory instead of mmaping
@@ -55,7 +56,7 @@ int   mono_shared_area_instances (void **array, int count);
 typedef void *(*mono_file_map_alloc_fn)   (size_t length);
 typedef void  (*mono_file_map_release_fn) (void *addr);
 
-void mono_file_map_set_allocator (mono_file_map_alloc_fn alloc, mono_file_map_release_fn release);
+MONO_API void mono_file_map_set_allocator (mono_file_map_alloc_fn alloc, mono_file_map_release_fn release);
                                  
 #endif /* __MONO_UTILS_MMAP_H__ */
 
index dcb69ef835239df447851189dfb3072dc5dce73c..1ce57b07c6fb6cc44b169896730c5850ece3f6c4 100644 (file)
@@ -2,9 +2,10 @@
 #define __MONO_PATH_H
 
 #include <glib.h>
+#include <mono/utils/mono-publib.h>
 
-gchar *mono_path_resolve_symlinks (const char *path);
-gchar *mono_path_canonicalize (const char *path);
+MONO_API gchar *mono_path_resolve_symlinks (const char *path);
+MONO_API gchar *mono_path_canonicalize (const char *path);
 
 #endif /* __MONO_PATH_H */
 
index 1d4c82afa5f8e09a1f56dd5afc3001a60b994800..835c36795a63269bb8aa022b97f236cd105d4e05 100644 (file)
@@ -1,6 +1,8 @@
 #ifndef MONO_POLL_H
 #define MONO_POLL_H
 
+#include <mono/utils/mono-publib.h>
+
 #include <config.h>
 #ifdef HAVE_SYS_TIME_H
 #include <sys/time.h>
@@ -42,7 +44,7 @@ typedef struct {
 
 #endif
 
-int mono_poll (mono_pollfd *ufds, unsigned int nfds, int timeout);
+MONO_API int mono_poll (mono_pollfd *ufds, unsigned int nfds, int timeout);
 
 #endif /* MONO_POLL_H */
 
index 8e0fe36136d153e481c9ca52ef9977200c2f0a9a..01b8c1bb50c6f8b1098c1764758f5b5aac28c48e 100644 (file)
@@ -561,7 +561,7 @@ get_cpu_times (int cpu_id, gint64 *user, gint64 *systemt, gint64 *irq, gint64 *s
        char buf [256];
        char *s;
        int hz = get_user_hz ();
-       long long unsigned int user_ticks, nice_ticks, system_ticks, idle_ticks, iowait_ticks, irq_ticks, sirq_ticks;
+       guint64 user_ticks, nice_ticks, system_ticks, idle_ticks, iowait_ticks, irq_ticks, sirq_ticks;
        FILE *f = fopen ("/proc/stat", "r");
        if (!f)
                return;
@@ -578,7 +578,14 @@ get_cpu_times (int cpu_id, gint64 *user, gint64 *systemt, gint64 *irq, gint64 *s
                } else {
                        continue;
                }
-               sscanf (data, "%Lu %Lu %Lu %Lu %Lu %Lu %Lu", &user_ticks, &nice_ticks, &system_ticks, &idle_ticks, &iowait_ticks, &irq_ticks, &sirq_ticks);
+               
+               user_ticks = strtoull (data, &data, 10);
+               nice_ticks = strtoull (data, &data, 10);
+               system_ticks = strtoull (data, &data, 10);
+               idle_ticks = strtoull (data, &data, 10);
+               iowait_ticks = strtoull (data, &data, 10);
+               irq_ticks = strtoull (data, &data, 10);
+               sirq_ticks = strtoull (data, &data, 10);
                break;
        }
        fclose (f);
index 95630cf51f3c8833d5999878a05d07a8cc0b9d3c..0b24c7fbcd973ab42a1ca276418963bf0681a293 100644 (file)
 #define _MONO_PROPERTY_HASH_H_
 
 #include <glib.h>
+#include <mono/utils/mono-publib.h>
 
 G_BEGIN_DECLS
 
 typedef struct _MonoPropertyHash MonoPropertyHash;
 
-MonoPropertyHash* mono_property_hash_new (void);
+MONO_API MonoPropertyHash* mono_property_hash_new (void);
 
-void mono_property_hash_destroy (MonoPropertyHash *hash);
+MONO_API void mono_property_hash_destroy (MonoPropertyHash *hash);
 
-void mono_property_hash_insert (MonoPropertyHash *hash, gpointer object, guint32 property,
+MONO_API void mono_property_hash_insert (MonoPropertyHash *hash, gpointer object, guint32 property,
                                                                gpointer value);
 
 /* Remove all properties of OBJECT */
-void mono_property_hash_remove_object (MonoPropertyHash *hash, gpointer object);
+MONO_API void mono_property_hash_remove_object (MonoPropertyHash *hash, gpointer object);
 
-gpointer mono_property_hash_lookup (MonoPropertyHash *hash, gpointer object, guint32 property);
+MONO_API gpointer mono_property_hash_lookup (MonoPropertyHash *hash, gpointer object, guint32 property);
 
 G_END_DECLS
 
index 5b6e0ff40ed4ebd6f48287de175dac97ec09f37a..505592a862f58f104947341bd80f386c1b589695 100644 (file)
@@ -18,7 +18,9 @@
 MONO_BEGIN_DECLS
 
 /* VS 2010 and later have stdint.h */
-#if defined(_MSC_VER) && _MSC_VER < 1600
+#if defined(_MSC_VER)
+
+#if _MSC_VER < 1600
 
 typedef __int8                 int8_t;
 typedef unsigned __int8                uint8_t;
@@ -33,8 +35,28 @@ typedef unsigned __int64     uint64_t;
 
 #include <stdint.h>
 
+#endif
+
+#define MONO_API_EXPORT __declspec(dllexport)
+#define MONO_API_IMPORT __declspec(dllimport)
+
+#else
+
+#include <stdint.h>
+
+#define MONO_API_EXPORT
+#define MONO_API_IMPORT
+
 #endif /* end of compiler-specific stuff */
 
+#if !defined(MONO_STATIC_BUILD) && defined(MONO_DLL_EXPORT)
+       #define MONO_API MONO_API_EXPORT
+#elif !defined(MONO_STATIC_BUILD)
+       #define MONO_API MONO_API_IMPORT
+#else
+       #define MONO_API
+#endif
+
 typedef int32_t                mono_bool;
 typedef uint8_t                mono_byte;
 typedef uint16_t       mono_unichar2;
@@ -42,7 +64,7 @@ typedef uint16_t      mono_unichar2;
 typedef void   (*MonoFunc)     (void* data, void* user_data);
 typedef void   (*MonoHFunc)    (void* key, void* value, void* user_data);
 
-void mono_free (void *);
+MONO_API void mono_free (void *);
 
 #define MONO_CONST_RETURN const
 
index 07e65bc1abc2c05ad54ce3ba6614698e436f47ea..17dce622dfafecd33b64760f25d632e4963749ab 100644 (file)
@@ -17,6 +17,7 @@
 #include <semaphore.h>
 #endif
 #include <mono/io-layer/io-layer.h>
+#include <mono/utils/mono-publib.h>
 
 #if (defined (HAVE_SEMAPHORE_H) || defined (USE_MACH_SEMA)) && !defined(HOST_WIN32)
 #  define MONO_HAS_SEMAPHORES
@@ -54,9 +55,9 @@ typedef HANDLE MonoSemType;
 
 G_BEGIN_DECLS
 
-int mono_sem_wait (MonoSemType *sem, gboolean alertable);
-int mono_sem_timedwait (MonoSemType *sem, guint32 timeout_ms, gboolean alertable);
-int mono_sem_post (MonoSemType *sem);
+MONO_API int mono_sem_wait (MonoSemType *sem, gboolean alertable);
+MONO_API int mono_sem_timedwait (MonoSemType *sem, guint32 timeout_ms, gboolean alertable);
+MONO_API int mono_sem_post (MonoSemType *sem);
 
 G_END_DECLS
 #endif /* _MONO_SEMAPHORE_H_ */
index 96dc9eeed085f04059f4ccf75eaecd665d10bc00..1a92a8f7ef86a3fa84b518daaf6dd21fe6925cfc 100644 (file)
@@ -1,8 +1,9 @@
 #ifndef __MONO_URI_H
 #define __MONO_URI_H
 #include <glib.h>
+#include <mono/utils/mono-publib.h>
 
-gchar * mono_escape_uri_string (const gchar *string);
+MONO_API gchar * mono_escape_uri_string (const gchar *string);
 
 #endif /* __MONO_URI_H */
 
index 7ec53f60bcf91cf53c3ea6f87f77589f7b09fe4f..5bea9278394d1e7dd1a2f033c71cb2a47517807b 100644 (file)
@@ -2,6 +2,7 @@
 #define __MONO_BITSET_H__
 
 #include <glib.h>
+#include <mono/utils/mono-publib.h>
 
 /*
  * When embedding, you have to define MONO_ZERO_LEN_ARRAY before including any
@@ -62,56 +63,56 @@ enum {
  * Interface documentation by Dennis Haney.
  */
 
-guint32     mono_bitset_alloc_size   (guint32 max_size, guint32 flags);
+MONO_API guint32     mono_bitset_alloc_size   (guint32 max_size, guint32 flags);
 
-MonoBitSet* mono_bitset_new          (guint32 max_size, guint32 flags);
+MONO_API MonoBitSet* mono_bitset_new          (guint32 max_size, guint32 flags);
 
-MonoBitSet* mono_bitset_mem_new      (gpointer mem, guint32 max_size, guint32 flags);
+MONO_API MonoBitSet* mono_bitset_mem_new      (gpointer mem, guint32 max_size, guint32 flags);
 
-void        mono_bitset_free         (MonoBitSet *set); 
+MONO_API void        mono_bitset_free         (MonoBitSet *set); 
 
-void        mono_bitset_set          (MonoBitSet *set, guint32 pos);
+MONO_API void        mono_bitset_set          (MonoBitSet *set, guint32 pos);
 
-void        mono_bitset_set_all      (MonoBitSet *set);
+MONO_API void        mono_bitset_set_all      (MonoBitSet *set);
 
-int         mono_bitset_test         (const MonoBitSet *set, guint32 pos);
+MONO_API int         mono_bitset_test         (const MonoBitSet *set, guint32 pos);
 
-gsize       mono_bitset_test_bulk    (const MonoBitSet *set, guint32 pos);
+MONO_API gsize       mono_bitset_test_bulk    (const MonoBitSet *set, guint32 pos);
 
-void        mono_bitset_clear        (MonoBitSet *set, guint32 pos);
+MONO_API void        mono_bitset_clear        (MonoBitSet *set, guint32 pos);
 
-void        mono_bitset_clear_all    (MonoBitSet *set);
+MONO_API void        mono_bitset_clear_all    (MonoBitSet *set);
 
-void        mono_bitset_invert       (MonoBitSet *set);
+MONO_API void        mono_bitset_invert       (MonoBitSet *set);
 
-guint32     mono_bitset_size         (const MonoBitSet *set);
+MONO_API guint32     mono_bitset_size         (const MonoBitSet *set);
 
-guint32     mono_bitset_count        (const MonoBitSet *set);
+MONO_API guint32     mono_bitset_count        (const MonoBitSet *set);
 
-void        mono_bitset_low_high     (const MonoBitSet *set, guint32 *low, guint32 *high);
+MONO_API void        mono_bitset_low_high     (const MonoBitSet *set, guint32 *low, guint32 *high);
 
-int         mono_bitset_find_start   (const MonoBitSet *set);
+MONO_API int         mono_bitset_find_start   (const MonoBitSet *set);
 
-int         mono_bitset_find_first   (const MonoBitSet *set, gint pos);
+MONO_API int         mono_bitset_find_first   (const MonoBitSet *set, gint pos);
 
-int         mono_bitset_find_last    (const MonoBitSet *set, gint pos);
+MONO_API int         mono_bitset_find_last    (const MonoBitSet *set, gint pos);
 
-int         mono_bitset_find_first_unset (const MonoBitSet *set, gint pos);
+MONO_API int         mono_bitset_find_first_unset (const MonoBitSet *set, gint pos);
 
-MonoBitSet* mono_bitset_clone        (const MonoBitSet *set, guint32 new_size);
+MONO_API MonoBitSet* mono_bitset_clone        (const MonoBitSet *set, guint32 new_size);
 
-void        mono_bitset_copyto       (const MonoBitSet *src, MonoBitSet *dest);
+MONO_API void        mono_bitset_copyto       (const MonoBitSet *src, MonoBitSet *dest);
 
-void        mono_bitset_union        (MonoBitSet *dest, const MonoBitSet *src);
+MONO_API void        mono_bitset_union        (MonoBitSet *dest, const MonoBitSet *src);
 
-void        mono_bitset_intersection (MonoBitSet *dest, const MonoBitSet *src);
+MONO_API void        mono_bitset_intersection (MonoBitSet *dest, const MonoBitSet *src);
 
-void        mono_bitset_sub          (MonoBitSet *dest, const MonoBitSet *src);
+MONO_API void        mono_bitset_sub          (MonoBitSet *dest, const MonoBitSet *src);
 
-gboolean    mono_bitset_equal        (const MonoBitSet *src, const MonoBitSet *src1);
+MONO_API gboolean    mono_bitset_equal        (const MonoBitSet *src, const MonoBitSet *src1);
 
-void        mono_bitset_foreach      (MonoBitSet *set, MonoBitSetFunc func, gpointer data);
+MONO_API void        mono_bitset_foreach      (MonoBitSet *set, MonoBitSetFunc func, gpointer data);
 
-void        mono_bitset_intersection_2 (MonoBitSet *dest, const MonoBitSet *src1, const MonoBitSet *src2);
+MONO_API void        mono_bitset_intersection_2 (MonoBitSet *dest, const MonoBitSet *src1, const MonoBitSet *src2);
 
 #endif /* __MONO_BITSET_H__ */
index f1b66737e3a74ced1320c0434016b9bd5586a11a..8da0155669c77663585275a84ecea1d4c753e790 100644 (file)
 #define _MONO_STRENC_H_ 1
 
 #include <glib.h>
+#include <mono/utils/mono-publib.h>
 
-extern gunichar2 *mono_unicode_from_external (const gchar *in, gsize *bytes);
-extern gchar *mono_utf8_from_external (const gchar *in);
-extern gchar *mono_unicode_to_external (const gunichar2 *uni);
-extern gboolean mono_utf8_validate_and_len (const gchar *source, glong* oLength, const gchar** oEnd);
-extern gboolean mono_utf8_validate_and_len_with_bounds (const gchar *source, glong max_bytes, glong* oLength, const gchar** oEnd);
+extern MONO_API gunichar2 *mono_unicode_from_external (const gchar *in, gsize *bytes);
+extern MONO_API gchar *mono_utf8_from_external (const gchar *in);
+extern MONO_API gchar *mono_unicode_to_external (const gunichar2 *uni);
+extern MONO_API gboolean mono_utf8_validate_and_len (const gchar *source, glong* oLength, const gchar** oEnd);
+extern MONO_API gboolean mono_utf8_validate_and_len_with_bounds (const gchar *source, glong max_bytes, glong* oLength, const gchar** oEnd);
 
 #endif /* _MONO_STRENC_H_ */
index 708e485017c1fce347a87ce877fa3937a6f76399..d7b993409991182021565d76457cd7f4dc16ddf6 100644 (file)
@@ -2444,6 +2444,7 @@ mono_strtod
        return sign ? -dval(rv) : dval(rv);
        }
 
+#if 0
  static int
 quorem
 #ifdef KR_headers
@@ -2561,11 +2562,13 @@ quorem
                }
        return q;
        }
+#endif
 
 #ifndef MULTIPLE_THREADS
  static char *dtoa_result;
 #endif
 
+#if 0
  static char *
 #ifdef KR_headers
 rv_alloc(i) int i;
@@ -2629,7 +2632,6 @@ freedtoa(char *s)
 #endif
        }
 
-#if 0
 /* dtoa for IEEE arithmetic (dmg): convert double to ASCII string.
  *
  * Inspired by "How to Print Floating-Point Numbers Accurately" by
index 38cc49ba75ed5b12456a47e03f2b666b483c2172..b7edc5e83f14ab25ef37881ab9c89b1282a8299b 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index 5ec6d8aa5b976e43733439bd7049dfc731e056f2..aa5e37085ac9208e9ee72ea9bef3007976039225 100644 (file)
     <ConfigurationType>Application</ConfigurationType>\r
     <UseOfMfc>false</UseOfMfc>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <UseOfMfc>false</UseOfMfc>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <UseOfMfc>false</UseOfMfc>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <UseOfMfc>false</UseOfMfc>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index 76a7e8202e76593289daec05fd851debd94e3aa8..1b2327d7564859b62f5dffab7d188965af9057ec 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index 97e87073491801e64428dea8df9c4a5b64ad46c8..d818b95c7db33a91da1a827fdb733703db46e174 100644 (file)
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <UseOfMfc>false</UseOfMfc>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release_SGen|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <UseOfMfc>false</UseOfMfc>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <UseOfMfc>false</UseOfMfc>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug_SGen|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <UseOfMfc>false</UseOfMfc>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <UseOfMfc>false</UseOfMfc>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release_SGen|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <UseOfMfc>false</UseOfMfc>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <UseOfMfc>false</UseOfMfc>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug_SGen|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <UseOfMfc>false</UseOfMfc>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
       <LinkLibraryDependencies>false</LinkLibraryDependencies>\r
     </ProjectReference>\r
     <Link>\r
-      <AdditionalDependencies>libgc.lib;libmonoruntimesgen.lib;libmonoutils.lib;eglib.lib;%(AdditionalDependencies)</AdditionalDependencies>\r
+      <AdditionalDependencies>libmonoruntimesgen.lib;libmonoutils.lib;eglib.lib;%(AdditionalDependencies)</AdditionalDependencies>\r
       <AdditionalLibraryDirectories>$(Platform)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
       <ModuleDefinitionFile>monosgen.def</ModuleDefinitionFile>\r
       <GenerateDebugInformation>true</GenerateDebugInformation>\r
index 1eea09750cbb4f67dd683aeb148562025bb9493b..4e72f6ad1a6b2658b75078dbbf0c040f7615e4aa 100644 (file)
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?>\r
+<?xml version="1.0" encoding="utf-8"?>\r
 <Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
   <ItemGroup Label="ProjectConfigurations">\r
     <ProjectConfiguration Include="Debug_SGen|Win32">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <UseDebugLibraries>true</UseDebugLibraries>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug_SGen|Win32'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <UseDebugLibraries>true</UseDebugLibraries>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <UseDebugLibraries>true</UseDebugLibraries>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug_SGen|x64'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <UseDebugLibraries>true</UseDebugLibraries>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <UseDebugLibraries>false</UseDebugLibraries>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release_SGen|Win32'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <UseDebugLibraries>false</UseDebugLibraries>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <UseDebugLibraries>false</UseDebugLibraries>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release_SGen|x64'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <UseDebugLibraries>false</UseDebugLibraries>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />\r
   <ImportGroup Label="ExtensionTargets">\r
   </ImportGroup>\r
-</Project>\r
+</Project>
\ No newline at end of file
index 4a98808419078f1c076815c55e53613ef62cdb2f..d4e76000a8b8a804cf1f6b645e4bf8a371ac5b22 100644 (file)
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <UseDebugLibraries>true</UseDebugLibraries>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <UseDebugLibraries>true</UseDebugLibraries>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <UseDebugLibraries>false</UseDebugLibraries>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>StaticLibrary</ConfigurationType>\r
     <UseDebugLibraries>false</UseDebugLibraries>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />\r
   <ImportGroup Label="ExtensionTargets">\r
   </ImportGroup>\r
-</Project>\r
+</Project>
\ No newline at end of file
index 0a4e772f4035b4e70d48f96c80809ec2dfbcef03..fbe0a89b0325f00445969557a883c423f52e061d 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index 4db2be0c8079abae4625d3e94dc159ef117bae4e..56eb4665d80c1f82f86af3d444836f0107de9e4b 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release_SGen|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug_SGen|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release_SGen|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug_SGen|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
     </ClCompile>\r
     <ProjectReference />\r
     <Link>\r
-      <AdditionalDependencies>monosgen-2.0.lib;libgc.lib;eglib.lib;%(AdditionalDependencies)</AdditionalDependencies>\r
+      <AdditionalDependencies>monosgen-2.0.lib;eglib.lib;%(AdditionalDependencies)</AdditionalDependencies>\r
       <AdditionalLibraryDirectories>$(Platform)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
       <GenerateDebugInformation>true</GenerateDebugInformation>\r
       <SubSystem>Console</SubSystem>\r
index b7ec16d205aac06e302b780fa18b29c5678469eb..2dd2d2631f83839133ae8a17269465685d3dddcc 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index 02c88b38e7dccf8e6b67d00638633c243efdae7d..17ff95c816e9d9c74b8c6a837b016f257a047158 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index 91caf879cd8608265162935889d5f005e153b3b7..d8e0599e91db63e0e63403959df5173350f60f4a 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index b6420a80652da74755c1b7fa19f32a368eb232e2..edb6ce136eb566eb68086e609a8f423187de3aa3 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index 2c6e2910d21e3c9e6b61ee1c1a698d57d85e5e2a..1116f3b890428b15405e4859fbc5fbb7ac100990 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index 1ce7d6bfd657e6cfc931b3158b9c77d71490824c..ee2255af874d113d6651dac8df28f69f87ae5771 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index f4f68e476abcf8054eb79a0e44e610bd4b65898c..d24d2858aa2a5c0759e5a4f87d6439c715cc3979 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index 16e248f8de5ca68c15f382b203f2beb7d25dbffc..5038b830f871e0a07f5258ba5cfd152191af2764 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index c67d32777796b03cdba40a978ba04c43dcbc2557..60faa3ffd7b84a1aa942f521cdfc55cdd9a66f15 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>DynamicLibrary</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index 475b32b1ae9165b492c2f14f8e27cdb43391cb83..161940e62f42b2816952d4128fb6820ae5d7f685 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index f28c1e351a1f47ff52c79ad650cbcf35967e4a39..51e48f432a89758fd09c8da677f5e0e150c1354a 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index a25b55e99813b0de771262f276765644d9d99f7e..f87a9c2c97617a4b120da334b365a9d5c1f147c0 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r
index 4125f7569d93ae5c9699fceca8c2fd10d2b21f73..19a6dcb76d6e8a0fe4e009831f990325f70125cf 100644 (file)
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">\r
     <ConfigurationType>Application</ConfigurationType>\r
     <CharacterSet>Unicode</CharacterSet>\r
+    <PlatformToolset>v110</PlatformToolset>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
   <ImportGroup Label="ExtensionSettings">\r