Enable several StyleCopAnalyzers (dotnet/corefx#39921)
authorStephen Toub <stoub@microsoft.com>
Wed, 31 Jul 2019 23:10:59 +0000 (19:10 -0400)
committerGitHub <noreply@github.com>
Wed, 31 Jul 2019 23:10:59 +0000 (19:10 -0400)
* Fix ordering of keywords in member signatures

* Add StyeCop.Analyzers

Most rules are disabled.  Many of them we'll want to leave disabled, however there are a handful it'll be good to enable over time.

* Use built-in type alias

* Fix straggling stylecop warnings in all configurations

* Replace tabs with spaces

Commit migrated from https://github.com/dotnet/corefx/commit/a12c557a72988070b8624cc7ecc46899629895c4

645 files changed:
eng/Analyzers.props
src/libraries/CodeAnalysis.ruleset
src/libraries/Common/src/Interop/FreeBSD/Interop.Process.cs
src/libraries/Common/src/Interop/OSX/Interop.CoreFoundation.CFDate.cs
src/libraries/Common/src/Interop/OSX/Interop.EventStream.cs
src/libraries/Common/src/Interop/OSX/System.Security.Cryptography.Native.Apple/Interop.Random.cs
src/libraries/Common/src/Interop/Unix/System.Native/Interop.GetGroupList.cs
src/libraries/Common/src/Interop/Unix/System.Native/Interop.Stat.Span.cs
src/libraries/Common/src/Interop/Unix/System.Native/Interop.UTimensat.cs
src/libraries/Common/src/Interop/Unix/System.Security.Cryptography.Native/Interop.OpenSsl.cs
src/libraries/Common/src/Interop/Unix/System.Security.Cryptography.Native/Interop.RAND.cs
src/libraries/Common/src/Interop/Unix/System.Security.Cryptography.Native/Interop.SslCtx.cs
src/libraries/Common/src/Interop/Unix/System.Security.Cryptography.Native/Interop.SslCtxOptions.cs
src/libraries/Common/src/Interop/Windows/Advapi32/Interop.AdjustTokenPrivileges.cs
src/libraries/Common/src/Interop/Windows/Advapi32/Interop.ControlService.cs
src/libraries/Common/src/Interop/Windows/Advapi32/Interop.GetTokenInformation_void.cs
src/libraries/Common/src/Interop/Windows/Advapi32/Interop.SetServiceStatus.cs
src/libraries/Common/src/Interop/Windows/Kernel32/Interop.CTL_CODE.cs
src/libraries/Common/src/Interop/Windows/Kernel32/Interop.CompareStringOrdinal.cs
src/libraries/Common/src/Interop/Windows/Kernel32/Interop.CreateFile.cs
src/libraries/Common/src/Interop/Windows/Kernel32/Interop.CreateFile2.cs
src/libraries/Common/src/Interop/Windows/Kernel32/Interop.FormatMessage_SafeLibraryHandle.cs
src/libraries/Common/src/Interop/Windows/Kernel32/Interop.GetConsoleTitle.cs
src/libraries/Common/src/Interop/Windows/Kernel32/Interop.GetNamedPipeInfo.cs
src/libraries/Common/src/Interop/Windows/Kernel32/Interop.GetVolumeInformation.cs
src/libraries/Common/src/Interop/Windows/Kernel32/Interop.ReadDirectoryChangesW.cs
src/libraries/Common/src/Interop/Windows/Kernel32/Interop.SetFileCompletionNotificationModes.cs
src/libraries/Common/src/Interop/Windows/NtDll/Interop.FILE_FULL_DIR_INFORMATION.cs
src/libraries/Common/src/Interop/Windows/NtDll/Interop.NtCreateFile.cs
src/libraries/Common/src/Interop/Windows/NtDll/Interop.NtQueryDirectoryFile.cs
src/libraries/Common/src/Interop/Windows/NtDll/Interop.NtQuerySystemInformation.cs
src/libraries/Common/src/Interop/Windows/NtDll/Interop.RtlNtStatusToDosError.cs
src/libraries/Common/src/Interop/Windows/PerfCounter/Interop.FormatFromRawValue.cs
src/libraries/Common/src/Interop/Windows/Shell32/Interop.ShellExecuteExW.cs
src/libraries/Common/src/Interop/Windows/User32/Interop.SendMessageTimeout.cs
src/libraries/Common/src/Interop/Windows/WinSock/Interop.WSAGetOverlappedResult.cs
src/libraries/Common/src/Interop/Windows/WinSock/Interop.WSARecv.cs
src/libraries/Common/src/Interop/Windows/WinSock/Interop.WSARecvFrom.cs
src/libraries/Common/src/Interop/Windows/WinSock/Interop.WSASendTo.cs
src/libraries/Common/src/System/Data/Common/DbConnectionOptions.Common.cs
src/libraries/Common/src/System/Data/ProviderBase/DbConnectionClosed.cs
src/libraries/Common/src/System/Data/ProviderBase/DbConnectionPoolGroup.cs
src/libraries/Common/src/System/Memory/FixedBufferExtensions.cs
src/libraries/Common/src/System/Net/IPv6AddressHelper.Common.cs
src/libraries/Common/src/System/Reflection/AssemblyMetadataAttribute.cs
src/libraries/Common/tests/CoreFx.Private.TestUtilities/System/AdminHelpers.cs
src/libraries/Common/tests/System/Net/TestLogging.cs
src/libraries/Common/tests/System/Xml/ModuleCore/ccommon.cs
src/libraries/Common/tests/System/Xml/ModuleCore/cerror.cs
src/libraries/Common/tests/System/Xml/ModuleCore/cltmconsole.cs
src/libraries/Common/tests/System/Xml/ModuleCore/ctestcase.cs
src/libraries/Common/tests/System/Xml/ModuleCore/ctestmodule.cs
src/libraries/Common/tests/System/Xml/ModuleCore/interop.cs
src/libraries/Common/tests/System/Xml/XPath/MiscellaneousCases/LexicalStructureTests.cs
src/libraries/Common/tests/System/Xml/XmlCoreTest/ManagedNodeWriter.cs
src/libraries/Common/tests/System/Xml/XmlCoreTest/ReaderCreateUtil.cs
src/libraries/Common/tests/System/Xml/XmlCoreTest/ReaderUtil.cs
src/libraries/Common/tests/System/Xml/XmlCoreTest/WriterFactory.cs
src/libraries/Common/tests/System/Xml/XmlDiff/XmlDiffDocument.cs
src/libraries/Common/tests/Tests/System/StringTests.cs
src/libraries/Microsoft.CSharp/src/Microsoft/CSharp/RuntimeBinder/DynamicDebuggerProxy.cs
src/libraries/Microsoft.CSharp/tests/AccessTests.cs
src/libraries/Microsoft.CSharp/tests/BindingErrors.cs
src/libraries/Microsoft.IO.Redist/src/Microsoft/IO/StringExtensions.cs
src/libraries/Microsoft.Win32.SystemEvents/src/Microsoft/Win32/SystemEvents.cs
src/libraries/System.CodeDom/src/System/CodeDom/Compiler/CompilerResults.Evidence.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeArgumentReferenceExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeArrayCreateExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeArrayIndexerExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeAssignStatementTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeAttachEventStatementTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeAttributeArgumentTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeAttributeDeclarationTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeBinaryOperatorExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeCastExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeCatchClauseTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeChecksumPragmaTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeCommentStatementTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeCommentTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeCompileUnitTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeConditionStatementTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeConstructorTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeDefaultValueExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeDelegateCreateExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeDelegateInvokeExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeDirectionExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeEventReferenceExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeExpressionStatementTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeFieldReferenceExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeGotoStatement.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeIndexerExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeIterationStatementTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeLabeledStatementTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeLinePragmaTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeMemberEventTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeMemberFieldTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeMemberMethodTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeMemberPropertyTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeMethodInvokeExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeMethodReferenceExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeMethodReturnStatementTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeNamespaceImportTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeNamespaceTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeObjectCreateExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeObjectTestBase.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeParameterDeclarationExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodePrimitiveExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodePropertyReferenceExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeRegionDirectiveTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeRemoveEventStatementTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeSnippetCompileUnitTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeSnippetExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeSnippetStatementTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeSnippetTypeMemberTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeStatementTestBase.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeThrowExceptionStatementTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeTryCatchFinallyStatementTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeTypeConstructorTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeTypeDeclarationTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeTypeDelegateTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeTypeMemberTestBase.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeTypeOfExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeTypeParameterTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeTypeReferenceExpressionTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeTypeReferenceTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeVariableDeclarationStatementTests.cs
src/libraries/System.CodeDom/tests/System/CodeDom/CodeVariableReferenceExpressionTests.cs
src/libraries/System.Collections.Concurrent/src/System/Collections/Concurrent/BlockingCollection.cs
src/libraries/System.Collections.Immutable/src/System/Collections/Immutable/ImmutableArray_1.Minimal.cs
src/libraries/System.Collections.Immutable/src/System/Collections/Immutable/ImmutableArray_1.cs
src/libraries/System.Collections.Immutable/src/System/Collections/Immutable/ImmutableDictionary_2.Builder.cs
src/libraries/System.Collections.Immutable/src/System/Collections/Immutable/ImmutableList_1.Builder.cs
src/libraries/System.Collections.Immutable/src/System/Collections/Immutable/ImmutableList_1.cs
src/libraries/System.Collections.Immutable/src/System/Collections/Immutable/ImmutableSortedDictionary_2.Builder.cs
src/libraries/System.Collections.Immutable/src/System/Collections/Immutable/ImmutableSortedSet_1.Builder.cs
src/libraries/System.Collections.Immutable/src/System/Collections/Immutable/ImmutableSortedSet_1.cs
src/libraries/System.Collections.NonGeneric/src/System/Collections/Queue.cs
src/libraries/System.Collections.NonGeneric/src/System/Collections/SortedList.cs
src/libraries/System.Collections.NonGeneric/src/System/Collections/Stack.cs
src/libraries/System.Collections.Specialized/src/System/Collections/Specialized/NameObjectCollectionBase.cs
src/libraries/System.Collections.Specialized/src/System/Collections/Specialized/NameValueCollection.cs
src/libraries/System.Collections/src/System/Collections/Generic/Queue.cs
src/libraries/System.Collections/tests/Generic/LinkedList/LinkedList.Generic.Tests.Constructor.cs
src/libraries/System.Collections/tests/Generic/LinkedList/LinkedList.Generic.Tests.RemoveNode.cs
src/libraries/System.Collections/tests/Generic/LinkedList/LinkedList.Generic.Tests.cs
src/libraries/System.ComponentModel.Annotations/src/System/ComponentModel/DataAnnotations/DisplayFormatAttribute.cs
src/libraries/System.ComponentModel.Annotations/src/System/ComponentModel/DataAnnotations/ValidationResult.cs
src/libraries/System.ComponentModel.Composition.Registration/tests/System/ComponentModel/Composition/Registration/ExportBuilderTests.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/AttributedModelServices.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/ChangeRejectedException.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/CompositionContractMismatchException.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/CompositionError.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/CompositionException.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/ExportAttribute.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/ExportMetadataAttribute.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Hosting/AggregateExportProvider.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Hosting/ApplicationCatalog.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Hosting/AssemblyCatalog.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Hosting/CatalogExportProvider.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Hosting/ComposablePartExportProvider.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Hosting/CompositionContainer.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Hosting/CompositionScopeDefinition.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Hosting/DirectoryCatalog.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Hosting/ExportProvider.GetExportOverrides.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Hosting/FilteredCatalog.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Hosting/ScopingExtensions.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Hosting/TypeCatalog.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/ImportAttribute.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/ImportCardinalityMismatchException.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/ImportManyAttribute.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/InheritedExportAttribute.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/PartMetadataAttribute.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Primitives/ComposablePartException.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Primitives/ContractBasedImportDefinition.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Primitives/Export.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Primitives/ExportDefinition.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Primitives/ICompositionElement.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Primitives/ImportDefinition.cs
src/libraries/System.ComponentModel.Composition/tests/System/ComponentModel/Composition/Primitives/ComposablePartCatalogTests.cs
src/libraries/System.ComponentModel.Primitives/src/System/ComponentModel/Component.cs
src/libraries/System.ComponentModel.TypeConverter/src/System/ComponentModel/AmbientValueAttribute.cs
src/libraries/System.ComponentModel.TypeConverter/src/System/ComponentModel/DateTimeConverter.cs
src/libraries/System.ComponentModel.TypeConverter/src/System/ComponentModel/DecimalConverter.cs
src/libraries/System.ComponentModel.TypeConverter/src/System/ComponentModel/MarshalByValueComponent.cs
src/libraries/System.ComponentModel.TypeConverter/src/System/ComponentModel/MemberDescriptor.cs
src/libraries/System.ComponentModel.TypeConverter/src/System/ComponentModel/TypeConverter.cs
src/libraries/System.ComponentModel.TypeConverter/tests/ContainerTests.cs
src/libraries/System.ComponentModel.TypeConverter/tests/ContextStackTests.cs
src/libraries/System.ComponentModel.TypeConverter/tests/Design/Serialization/InstanceDescriptorTests.cs
src/libraries/System.ComponentModel.TypeConverter/tests/LicenseManagerTests.cs
src/libraries/System.ComponentModel.TypeConverter/tests/Security/Authentication/ExtendedProtection/ExtendedProtectionPolicyTypeConverterTests.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/CallbackValidatorTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/CommaDelimitedStringCollectionConverterTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/CommaDelimitedStringCollectionTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/ConfigurationElementTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/ConfigurationErrorsExceptionTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/ConfigurationLockCollectionTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/ConfigurationManagerTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/ConfigurationPropertyTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/ConfigurationSectionGroupTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/ConfigurationSectionTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/ConnectionStringSettingsTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/DefaultValidatorTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/ExeConfigurationFileMapTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/GenericEnumConverterTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/InfiniteIntConverterTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/InfiniteTimeSpanConverterTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/IntegerValidatorTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/KeyValueConfigurationCollectionTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/KeyValueConfigurationElementTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/LongValidatorTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/PositiveTimeSpanValidatorTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/RegexStringValidatorTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/StringValidatorTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/SubclassTypeValidatorTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/TimeSpanMinutesConverterTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/TimeSpanMinutesOrInfiniteConverterTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/TimeSpanSecondsConverterTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/TimeSpanSecondsOrInfiniteConverterTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/TimeSpanValidatorTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/TypeNameConverterTest.cs
src/libraries/System.Configuration.ConfigurationManager/tests/Mono/WhiteSpaceTrimStringConverterTest.cs
src/libraries/System.Console/src/System/ConsolePal.Windows.cs
src/libraries/System.Data.Common/src/System/Data/Common/DbConnectionOptions.Mono.cs
src/libraries/System.Data.Common/src/System/Data/EnumerableRowCollection.cs
src/libraries/System.Data.Common/src/System/Data/Filter/Operators.cs
src/libraries/System.Data.Common/src/System/Data/LinqDataView.cs
src/libraries/System.Data.Common/src/System/Data/SQLTypes/SQLBytes.cs
src/libraries/System.Data.Common/src/System/Data/SQLTypes/SQLChars.cs
src/libraries/System.Data.Common/src/System/Data/SQLTypes/SqlXml.cs
src/libraries/System.Data.Common/tests/System/Data/Common/DataColumnMappingCollectionTest.cs
src/libraries/System.Data.Common/tests/System/Data/Common/DataTableMappingCollectionTest.cs
src/libraries/System.Data.Common/tests/System/Data/ConstraintCollectionTest2.cs
src/libraries/System.Data.Common/tests/System/Data/DataColumnCollectionTest.cs
src/libraries/System.Data.Common/tests/System/Data/DataColumnTest.cs
src/libraries/System.Data.Common/tests/System/Data/DataColumnTest2.cs
src/libraries/System.Data.Common/tests/System/Data/DataRowCollectionTest.cs
src/libraries/System.Data.Common/tests/System/Data/DataRowCollectionTest2.cs
src/libraries/System.Data.Common/tests/System/Data/DataRowTest2.cs
src/libraries/System.Data.Common/tests/System/Data/DataSetInferXmlSchemaTest.cs
src/libraries/System.Data.Common/tests/System/Data/DataSetReadXmlSchemaTest.cs
src/libraries/System.Data.Common/tests/System/Data/DataSetReadXmlTest.cs
src/libraries/System.Data.Common/tests/System/Data/DataSetTest.cs
src/libraries/System.Data.Common/tests/System/Data/DataSetTest2.cs
src/libraries/System.Data.Common/tests/System/Data/DataSetTypedDataSetTest.cs
src/libraries/System.Data.Common/tests/System/Data/DataTableReadXmlSchemaTest.cs
src/libraries/System.Data.Common/tests/System/Data/DataTableReaderTest.cs
src/libraries/System.Data.Common/tests/System/Data/DataTableTest.cs
src/libraries/System.Data.Common/tests/System/Data/DataTableTest2.cs
src/libraries/System.Data.Common/tests/System/Data/DataTableTest4.cs
src/libraries/System.Data.Common/tests/System/Data/DataViewManagerTest.cs
src/libraries/System.Data.Common/tests/System/Data/DataViewTest2.cs
src/libraries/System.Data.Common/tests/System/Data/ForeignKeyConstraintTest.cs
src/libraries/System.Data.Common/tests/System/Data/ForeignKeyConstraintTest2.cs
src/libraries/System.Data.Common/tests/System/Data/SqlTypes/SqlDateTimeTest.cs
src/libraries/System.Data.Common/tests/System/Data/SqlTypes/SqlDecimalTest.cs
src/libraries/System.Data.DataSetExtensions/tests/Mono/EnumerableRowCollectionTest.cs
src/libraries/System.Data.Odbc/src/System/Data/Odbc/OdbcParameter.cs
src/libraries/System.Data.Odbc/src/System/Data/Odbc/OdbcParameterHelper.cs
src/libraries/System.Data.OleDb/src/ColumnBinding.cs
src/libraries/System.Data.OleDb/src/DBBindings.cs
src/libraries/System.Data.OleDb/src/DbConnectionOptions.cs
src/libraries/System.Data.OleDb/src/DbConnectionStringCommon.cs
src/libraries/System.Data.OleDb/src/DbParameterHelper.cs
src/libraries/System.Data.OleDb/src/DbPropSet.cs
src/libraries/System.Data.OleDb/src/NativeMethods.cs
src/libraries/System.Data.OleDb/src/OleDbCommand.cs
src/libraries/System.Data.OleDb/src/OleDbCommandBuilder.cs
src/libraries/System.Data.OleDb/src/OleDbConnection.cs
src/libraries/System.Data.OleDb/src/OleDbConnectionFactory.cs
src/libraries/System.Data.OleDb/src/OleDbConnectionInternal.cs
src/libraries/System.Data.OleDb/src/OleDbConnectionString.cs
src/libraries/System.Data.OleDb/src/OleDbConnectionStringBuilder.cs
src/libraries/System.Data.OleDb/src/OleDbDataAdapter.cs
src/libraries/System.Data.OleDb/src/OleDbDataReader.cs
src/libraries/System.Data.OleDb/src/OleDbException.cs
src/libraries/System.Data.OleDb/src/OleDbMetaDataFactory.cs
src/libraries/System.Data.OleDb/src/OleDbParameter.cs
src/libraries/System.Data.OleDb/src/OleDbPropertySetGuid.cs
src/libraries/System.Data.OleDb/src/OleDbReferenceCollection.cs
src/libraries/System.Data.OleDb/src/OleDbStruct.cs
src/libraries/System.Data.OleDb/src/OleDbWrapper.cs
src/libraries/System.Data.OleDb/src/OleDb_Enum.cs
src/libraries/System.Data.OleDb/src/OleDb_Util.cs
src/libraries/System.Data.OleDb/src/PropertyInfoSet.cs
src/libraries/System.Data.OleDb/src/RowBinding.cs
src/libraries/System.Data.OleDb/src/SafeHandles.cs
src/libraries/System.Data.OleDb/src/SafeNativeMethods.cs
src/libraries/System.Data.OleDb/src/System/Data/Common/AdapterUtil.cs
src/libraries/System.Data.OleDb/src/System/Data/ProviderBase/DbBuffer.cs
src/libraries/System.Data.OleDb/src/System/Data/ProviderBase/DbConnectionClosed.cs
src/libraries/System.Data.OleDb/src/System/Data/ProviderBase/DbConnectionInternal.Shared.cs
src/libraries/System.Data.OleDb/src/System/Data/ProviderBase/DbConnectionPool.cs
src/libraries/System.Data.OleDb/src/System/Data/ProviderBase/DbConnectionPoolCounters.cs
src/libraries/System.Data.OleDb/src/System/Data/ProviderBase/DbConnectionPoolGroup.cs
src/libraries/System.Data.OleDb/src/System/Data/ProviderBase/DbConnectionPoolIdentity.cs
src/libraries/System.Data.OleDb/src/System/Data/ProviderBase/DbMetaDataFactory.cs
src/libraries/System.Data.OleDb/src/UnsafeNativeMethods.cs
src/libraries/System.Data.SqlClient/src/Microsoft/SqlServer/Server/ValueUtilsSmi.cs
src/libraries/System.Data.SqlClient/src/System/Data/ProviderBase/DbConnectionPool.NetCoreApp.cs
src/libraries/System.Data.SqlClient/src/System/Data/ProviderBase/DbConnectionPool.cs
src/libraries/System.Data.SqlClient/src/System/Data/ProviderBase/DbConnectionPoolIdentity.cs
src/libraries/System.Data.SqlClient/src/System/Data/Sql/SqlMetaData.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/PacketHandle.Unix.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SNI/SNIPacket.NetStandard.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SessionHandle.Unix.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlCachedBuffer.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlConnectionFactory.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlConnectionPoolGroupProviderInfo.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlConnectionPoolKey.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlDataReader.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlDelegatedTransaction.NetCoreApp.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlDelegatedTransaction.NetStandard.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlDelegatedTransaction.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlFileStream.Unsupported.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlInternalConnectionTds.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlInternalTransaction.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlParameterHelper.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlReferenceCollection.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlSequentialStream.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlSequentialTextReader.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlStream.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/SqlUtil.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/TdsEnums.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/TdsParser.NetStandard.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/TdsParser.Unix.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/TdsParser.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/TdsParserStateObject.cs
src/libraries/System.Data.SqlClient/tests/ManualTests/SQL/DataStreamTest/DataStreamTest.cs
src/libraries/System.Data.SqlClient/tests/StressTests/System.Data.StressFramework/DataTestGroup.cs
src/libraries/System.Data.SqlClient/tests/Tools/TDS/TDS.EndPoint/ITDSClient.cs
src/libraries/System.Data.SqlClient/tests/Tools/TDS/TDS.EndPoint/TDSClientParser.cs
src/libraries/System.Data.SqlClient/tests/Tools/TDS/TDS/Login7/TDSLogin7FedAuthOptionToken.cs
src/libraries/System.Data.SqlClient/tests/Tools/TDS/TDS/Login7/TDSLogin7GenericOptionToken.cs
src/libraries/System.Data.SqlClient/tests/Tools/TDS/TDS/Login7/TDSLogin7SessionRecoveryOptionToken.cs
src/libraries/System.Data.SqlClient/tests/Tools/TDS/TDS/Login7/TDSLogin7TokenOffsetProperty.cs
src/libraries/System.Data.SqlClient/tests/Tools/TDS/TDS/PreLogin/TDSPreLoginToken.cs
src/libraries/System.Diagnostics.DiagnosticSource/src/System/Diagnostics/Activity.cs
src/libraries/System.Diagnostics.DiagnosticSource/src/System/Diagnostics/DiagnosticSourceEventSource.cs
src/libraries/System.Diagnostics.EventLog/src/System/Diagnostics/EventLogInternal.cs
src/libraries/System.Diagnostics.EventLog/src/System/Diagnostics/Reader/NativeWrapper.cs
src/libraries/System.Diagnostics.EventLog/src/System/Diagnostics/Reader/ProviderMetadata.cs
src/libraries/System.Diagnostics.EventLog/src/System/Diagnostics/Reader/UnsafeNativeMethods.cs
src/libraries/System.Diagnostics.PerformanceCounter/src/System/Diagnostics/SharedPerformanceCounter.cs
src/libraries/System.Diagnostics.Process/src/System/Diagnostics/PerformanceCounterLib.cs
src/libraries/System.Diagnostics.Process/src/System/Diagnostics/Process.Unix.cs
src/libraries/System.Diagnostics.Process/tests/ProcessStartInfoTests.cs
src/libraries/System.Diagnostics.Process/tests/ProcessTests.Unix.cs
src/libraries/System.Diagnostics.TraceSource/src/System/Diagnostics/Switch.cs
src/libraries/System.DirectoryServices.AccountManagement/src/System/DirectoryServices/AccountManagement/AdvancedFilters.cs
src/libraries/System.DirectoryServices.AccountManagement/src/System/DirectoryServices/AccountManagement/AuthZSet.cs
src/libraries/System.DirectoryServices.AccountManagement/src/System/DirectoryServices/AccountManagement/AuthenticablePrincipal.cs
src/libraries/System.DirectoryServices.AccountManagement/src/System/DirectoryServices/AccountManagement/Principal.cs
src/libraries/System.DirectoryServices.AccountManagement/src/System/DirectoryServices/AccountManagement/Utils.cs
src/libraries/System.DirectoryServices.AccountManagement/src/System/DirectoryServices/AccountManagement/interopt.cs
src/libraries/System.DirectoryServices/src/System/DirectoryServices/ActiveDirectory/ActiveDirectoryPartition.cs
src/libraries/System.DirectoryServices/src/System/DirectoryServices/ActiveDirectory/ActiveDirectorySchemaProperty.cs
src/libraries/System.DirectoryServices/src/System/DirectoryServices/ActiveDirectory/DirectoryServer.cs
src/libraries/System.DirectoryServices/src/System/DirectoryServices/ActiveDirectory/Forest.cs
src/libraries/System.DirectoryServices/src/System/DirectoryServices/ActiveDirectory/NativeMethods.cs
src/libraries/System.DirectoryServices/src/System/DirectoryServices/ActiveDirectory/Utils.cs
src/libraries/System.DirectoryServices/src/System/DirectoryServices/DerefAlias.cs
src/libraries/System.DirectoryServices/src/System/DirectoryServices/DirectoryVirtualListViewContext.cs
src/libraries/System.DirectoryServices/src/System/DirectoryServices/ExtendedDn.cs
src/libraries/System.DirectoryServices/tests/System/DirectoryServices/ActiveDirectoryComInterop.cs
src/libraries/System.DirectoryServices/tests/System/DirectoryServices/DirectoryServicesTests.cs
src/libraries/System.Drawing.Common/src/System/Drawing/Font.Windows.cs
src/libraries/System.Drawing.Common/src/System/Drawing/Gdiplus.cs
src/libraries/System.Drawing.Common/src/System/Drawing/GdiplusNative.Windows.cs
src/libraries/System.Drawing.Common/src/System/Drawing/Icon.Windows.cs
src/libraries/System.Drawing.Common/src/System/Drawing/Image.cs
src/libraries/System.Drawing.Common/src/System/Drawing/SystemFonts.Windows.cs
src/libraries/System.Drawing.Common/src/System/Drawing/UnsafeNativeMethods.cs
src/libraries/System.Drawing.Common/tests/Imaging/ImageCodecInfoTests.cs
src/libraries/System.Drawing.Common/tests/Printing/MarginsTests.cs
src/libraries/System.Drawing.Common/tests/Printing/PageSettingsTests.cs
src/libraries/System.Drawing.Common/tests/Printing/PaperSizeTests.cs
src/libraries/System.Drawing.Common/tests/Printing/PaperSourceTests.cs
src/libraries/System.Drawing.Common/tests/Printing/PrinterSettingsTests.cs
src/libraries/System.Drawing.Common/tests/Printing/PrinterUnitConvertTests.cs
src/libraries/System.Drawing.Common/tests/mono/System.Drawing.Imaging/BmpCodecTests.cs
src/libraries/System.Drawing.Common/tests/mono/System.Drawing.Imaging/GifCodecTests.cs
src/libraries/System.Drawing.Common/tests/mono/System.Drawing.Imaging/IconCodecTests.cs
src/libraries/System.Drawing.Common/tests/mono/System.Drawing.Imaging/JpegCodecTests.cs
src/libraries/System.Drawing.Common/tests/mono/System.Drawing.Imaging/PngCodecTesst.cs
src/libraries/System.Drawing.Common/tests/mono/System.Drawing.Imaging/TiffCodecTests.cs
src/libraries/System.Drawing.Common/tests/mono/System.Drawing/BitmapTests.cs
src/libraries/System.Drawing.Common/tests/mono/System.Drawing/GraphicsTests.cs
src/libraries/System.Drawing.Common/tests/mono/System.Imaging/MetafileTest.cs
src/libraries/System.Drawing.Primitives/src/System/Drawing/Point.cs
src/libraries/System.Globalization.Extensions/tests/IdnMapping/IdnMappingUseStd3AsciiRulesTests.cs
src/libraries/System.Globalization/tests/CultureInfo/CultureInfoCtor.cs
src/libraries/System.Globalization/tests/DateTimeFormatInfo/DateTimeFormatInfoReadOnly.cs
src/libraries/System.IO.Compression/tests/Utilities/StripHeaderAndFooter.cs
src/libraries/System.IO.FileSystem.Watcher/src/System/IO/FileSystemWatcher.OSX.cs
src/libraries/System.IO.FileSystem.Watcher/tests/FileSystemWatcher.MultipleWatchers.cs
src/libraries/System.IO.FileSystem/src/System/IO/Enumeration/FileSystemEnumerableFactory.cs
src/libraries/System.IO.FileSystem/tests/Directory/Delete_MountVolume.cs
src/libraries/System.IO.FileSystem/tests/Enumeration/ErrorHandlingTests.netcoreapp.cs
src/libraries/System.IO.FileSystem/tests/PortedCommon/ReparsePointUtilities.cs
src/libraries/System.IO.Packaging/src/System/IO/Packaging/PackUriHelper.PackUriScheme.cs
src/libraries/System.IO.Ports/src/System/IO/Ports/SerialPort.cs
src/libraries/System.IO.Ports/src/System/IO/Ports/SerialStream.Windows.cs
src/libraries/System.IO.Ports/tests/SerialPort/Encoding.cs
src/libraries/System.IO.Ports/tests/SerialPort/ReadBufferSize.cs
src/libraries/System.IO.Ports/tests/SerialPort/ReadByte_Generic.cs
src/libraries/System.IO.Ports/tests/SerialPort/ReadChar_Generic.cs
src/libraries/System.IO.Ports/tests/SerialPort/ReadLine.cs
src/libraries/System.IO.Ports/tests/SerialPort/ReadLine_Generic.cs
src/libraries/System.IO.Ports/tests/SerialPort/ReadTo.cs
src/libraries/System.IO.Ports/tests/SerialPort/ReadTo_Generic.cs
src/libraries/System.IO.Ports/tests/SerialPort/Read_byte_int_int_Generic.cs
src/libraries/System.IO.Ports/tests/SerialPort/Read_char_int_int.cs
src/libraries/System.IO.Ports/tests/SerialPort/Read_char_int_int_Generic.cs
src/libraries/System.IO.Ports/tests/SerialPort/Stress01.cs
src/libraries/System.IO.Ports/tests/SerialPort/Write_char_int_int_Generic.cs
src/libraries/System.IO.Ports/tests/SerialPort/Write_str_Generic.cs
src/libraries/System.IO.Ports/tests/SerialStream/BeginRead_Generic.cs
src/libraries/System.IO.Ports/tests/SerialStream/WriteByte_Generic.cs
src/libraries/System.IO.Ports/tests/SerialStream/Write_byte_int_int_Generic.cs
src/libraries/System.IO/tests/Stream/Stream.CopyToTests.cs
src/libraries/System.Linq.Expressions/src/System/Linq/Expressions/CatchBlock.cs
src/libraries/System.Linq.Expressions/src/System/Linq/Expressions/ConstantExpression.cs
src/libraries/System.Linq.Expressions/src/System/Linq/Expressions/ElementInit.cs
src/libraries/System.Linq.Expressions/src/System/Linq/Expressions/Expression.cs
src/libraries/System.Linq.Expressions/src/System/Linq/Expressions/LabelTarget.cs
src/libraries/System.Linq.Expressions/src/System/Linq/Expressions/MemberBinding.cs
src/libraries/System.Linq.Expressions/src/System/Linq/Expressions/MethodCallExpression.cs
src/libraries/System.Linq.Expressions/src/System/Linq/Expressions/SwitchCase.cs
src/libraries/System.Linq.Expressions/src/System/Linq/Expressions/SymbolDocumentInfo.cs
src/libraries/System.Linq.Expressions/src/System/Runtime/CompilerServices/DynamicAttribute.cs
src/libraries/System.Linq.Parallel/src/System/Linq/ParallelEnumerable.cs
src/libraries/System.Management/src/System/Management/ManagementBaseObject.cs
src/libraries/System.Management/src/System/Management/ManagementClass.cs
src/libraries/System.Management/src/System/Management/ManagementDateTime.cs
src/libraries/System.Management/src/System/Management/ManagementEventArgs.cs
src/libraries/System.Management/src/System/Management/ManagementException.cs
src/libraries/System.Management/src/System/Management/ManagementNamedValueCollection.cs
src/libraries/System.Management/src/System/Management/ManagementObject.cs
src/libraries/System.Management/src/System/Management/ManagementOptions.cs
src/libraries/System.Management/src/System/Management/ManagementQuery.cs
src/libraries/System.Management/src/System/Management/Property.cs
src/libraries/System.Management/src/System/Management/PropertySet.cs
src/libraries/System.Management/src/System/Management/Qualifier.cs
src/libraries/System.Management/src/System/Management/QualifierSet.cs
src/libraries/System.Management/src/System/Management/WMIGenerator.cs
src/libraries/System.Memory/src/System/Buffers/SequenceReaderExtensions.Binary.cs
src/libraries/System.Memory/tests/ReadOnlyBuffer/ReadOnlySequenceTests.byte.cs
src/libraries/System.Memory/tests/ReadOnlyBuffer/ReadOnlySequenceTests.char.cs
src/libraries/System.Memory/tests/ReadOnlySpan/BinarySearch.cs
src/libraries/System.Memory/tests/Span/Clear.cs
src/libraries/System.Net.Http/src/System/Net/Http/Headers/KnownHeaders.cs
src/libraries/System.Net.HttpListener/src/System/Net/Managed/ChunkStream.cs
src/libraries/System.Net.HttpListener/src/System/Net/Managed/ChunkedInputStream.cs
src/libraries/System.Net.HttpListener/src/System/Net/Managed/HttpConnection.cs
src/libraries/System.Net.HttpListener/src/System/Net/Managed/HttpEndPointListener.cs
src/libraries/System.Net.HttpListener/src/System/Net/Managed/HttpEndPointManager.cs
src/libraries/System.Net.HttpListener/src/System/Net/Managed/HttpListenerRequest.Managed.cs
src/libraries/System.Net.HttpListener/src/System/Net/Managed/HttpListenerResponse.Managed.cs
src/libraries/System.Net.HttpListener/src/System/Net/Managed/HttpRequestStream.Managed.cs
src/libraries/System.Net.HttpListener/src/System/Net/Managed/HttpResponseStream.Managed.cs
src/libraries/System.Net.HttpListener/src/System/Net/Managed/HttpStreamAsyncResult.cs
src/libraries/System.Net.HttpListener/src/System/Net/Managed/ListenerAsyncResult.Managed.cs
src/libraries/System.Net.HttpListener/src/System/Net/Managed/ListenerPrefix.cs
src/libraries/System.Net.HttpListener/src/System/Net/ServiceNameStore.cs
src/libraries/System.Net.Mail/tests/Functional/SmtpExceptionTest.cs
src/libraries/System.Net.Primitives/tests/UnitTests/Fakes/IPv6AddressHelper.cs
src/libraries/System.Net.Security/src/System/Net/Security/SniHelper.cs
src/libraries/System.Net.Sockets/src/System/Net/Sockets/AcceptOverlappedAsyncResult.Unix.cs
src/libraries/System.Net.Sockets/tests/FunctionalTests/SocketOptionNameTest.Unix.cs
src/libraries/System.Net.Sockets/tests/FunctionalTests/SocketOptionNameTest.Windows.cs
src/libraries/System.Private.Uri/tests/ExtendedFunctionalTests/UriTests.cs
src/libraries/System.Private.Xml.Linq/src/System/Xml/Linq/XNodeEqualityComparer.cs
src/libraries/System.Private.Xml.Linq/tests/TreeManipulation/SimpleObjectsCreation.cs
src/libraries/System.Private.Xml.Linq/tests/XDocument.Common/CXmlCache.cs
src/libraries/System.Private.Xml.Linq/tests/XDocument.Common/ManagedNodeWriter.cs
src/libraries/System.Private.Xml.Linq/tests/XDocument.Test.ModuleCore/interop.cs
src/libraries/System.Private.Xml.Linq/tests/XDocument.Test.ModuleCore/testcase.cs
src/libraries/System.Private.Xml.Linq/tests/XDocument.Test.ModuleCore/testlog.cs
src/libraries/System.Private.Xml.Linq/tests/XDocument.Test.ModuleCore/testproperties.cs
src/libraries/System.Private.Xml.Linq/tests/XDocument.Test.ModuleCore/testspec.cs
src/libraries/System.Private.Xml/src/System/Xml/Cache/XPathNodeInfoAtom.cs
src/libraries/System.Private.Xml/src/System/Xml/Core/NewLineHandling.cs
src/libraries/System.Private.Xml/src/System/Xml/Resolvers/XmlPreloadedResolverAsync.cs
src/libraries/System.Private.Xml/src/System/Xml/Schema/BaseProcessor.cs
src/libraries/System.Private.Xml/src/System/Xml/Schema/XmlSchemaCollection.cs
src/libraries/System.Private.Xml/src/System/Xml/Schema/XmlSchemaSet.cs
src/libraries/System.Private.Xml/src/System/Xml/Schema/XmlUntypedStringConverter.cs
src/libraries/System.Private.Xml/src/System/Xml/Serialization/CodeGenerator.cs
src/libraries/System.Private.Xml/src/System/Xml/Serialization/CodeIdentifier.cs
src/libraries/System.Private.Xml/src/System/Xml/Serialization/XmlSerializationReaderILGen.cs
src/libraries/System.Private.Xml/src/System/Xml/Serialization/XmlSerializationWriter.cs
src/libraries/System.Private.Xml/src/System/Xml/Serialization/XmlSerializationWriterILGen.cs
src/libraries/System.Private.Xml/src/System/Xml/XmlConvert.cs
src/libraries/System.Private.Xml/src/System/Xml/Xsl/QIL/QilPatternVisitor.cs
src/libraries/System.Private.Xml/src/System/Xml/Xsl/Runtime/XmlRawWriterWrapper.cs
src/libraries/System.Private.Xml/src/System/Xml/Xsl/XPathConvert.cs
src/libraries/System.Private.Xml/tests/Readers/NameTable/XmlNameTable.cs
src/libraries/System.Private.Xml/tests/Writers/RwFactory/CRWFactory.cs
src/libraries/System.Private.Xml/tests/Writers/RwFactory/ReaderFactory.cs
src/libraries/System.Private.Xml/tests/Writers/XmlWriterApi/TCCheckChars.cs
src/libraries/System.Private.Xml/tests/XmlSchema/XmlSchemaSet/TC_SchemaSet_AllowXmlAttributes.cs
src/libraries/System.Private.Xml/tests/XmlSchema/XmlSchemaSet/TC_SchemaSet_Imports.cs
src/libraries/System.Private.Xml/tests/XmlSchema/XmlSchemaValidatorApi/XmlTestSettings.cs
src/libraries/System.Private.Xml/tests/Xslt/XslCompiledTransformApi/OutputSettings.cs
src/libraries/System.Private.Xml/tests/Xslt/XslCompiledTransformApi/XslTransformMultith.cs
src/libraries/System.Private.Xml/tests/Xslt/XslCompiledTransformApi/XsltArgumentListMultith.cs
src/libraries/System.Private.Xml/tests/Xslt/XslTransformApi/CXmlCache.cs
src/libraries/System.Private.Xml/tests/Xslt/XslTransformApi/CXslTransformMultith.cs
src/libraries/System.Private.Xml/tests/Xslt/XslTransformApi/CXsltArgumentListMultith.cs
src/libraries/System.Private.Xml/tests/Xslt/XslTransformApi/cthread.cs
src/libraries/System.Reflection.Context/src/System/Reflection/Context/Delegation/DelegatingParameterInfo.cs
src/libraries/System.Reflection.Context/src/System/Reflection/Context/Projection/ProjectingManifestResourceInfo.cs
src/libraries/System.Reflection.Context/src/System/Reflection/Context/Virtual/VirtualParameter.cs
src/libraries/System.Reflection.Context/src/System/Reflection/Context/Virtual/VirtualPropertyInfo.PropertySetter.cs
src/libraries/System.Reflection.Emit.ILGeneration/tests/CustomAttributeBuilderTests.cs
src/libraries/System.Reflection.Emit/tests/TypeBuilder/TypeBuilderDefineProperty.cs
src/libraries/System.Reflection.Extensions/tests/Definitions/EventDefinitions.cs
src/libraries/System.Reflection.Metadata/ref/System.Reflection.Metadata.cs
src/libraries/System.Reflection.Metadata/src/System/Reflection/Internal/Utilities/EncodingHelper.cs
src/libraries/System.Reflection.Metadata/src/System/Reflection/Internal/Utilities/FileStreamReadLightUp.cs
src/libraries/System.Reflection.Metadata/src/System/Reflection/Internal/Utilities/FileStreamReadLightUp.netstandard1.1.cs
src/libraries/System.Reflection.Metadata/src/System/Reflection/Metadata/PortablePdb/SequencePointCollection.cs
src/libraries/System.Reflection.Metadata/src/System/Reflection/Metadata/Signatures/SignatureTypeCode.cs
src/libraries/System.Reflection.Metadata/tests/Resources/Misc/Members.cs
src/libraries/System.Reflection.MetadataLoadContext/src/System/Reflection/Runtime/BindingFlagSupport/MemberPolicies.cs
src/libraries/System.Reflection.MetadataLoadContext/src/System/Reflection/Runtime/General/ListBuilder.cs
src/libraries/System.Reflection.MetadataLoadContext/src/System/Reflection/TypeLoading/Modules/Ecma/EcmaModule.ManifestResources.cs
src/libraries/System.Reflection.MetadataLoadContext/tests/src/Tests/Constructor/ConstructorTests.cs
src/libraries/System.Reflection.MetadataLoadContext/tests/src/Tests/Field/FieldTests.cs
src/libraries/System.Reflection.MetadataLoadContext/tests/src/Tests/Method/MethodTests.cs
src/libraries/System.Reflection.MetadataLoadContext/tests/src/Tests/Property/PropertyTests.cs
src/libraries/System.Reflection.MetadataLoadContext/tests/src/Tests/Type/TypeTests.cs
src/libraries/System.Reflection.MetadataLoadContext/tests/src/Tests/TypeInfoFromProjectN/TypeInfo_DeclaredEventTests.cs
src/libraries/System.Reflection.MetadataLoadContext/tests/src/Tests/TypeInfoFromProjectN/TypeInfo_DeclaredNestedTypeTests.cs
src/libraries/System.Reflection.MetadataLoadContext/tests/src/Tests/TypeInfoFromProjectN/TypeInfo_DeclaredPropertiesTests.cs
src/libraries/System.Reflection.MetadataLoadContext/tests/src/Tests/TypeInfoFromProjectN/TypeInfo_GenericTypeArgumentsTests.cs
src/libraries/System.Reflection.MetadataLoadContext/tests/src/Tests/TypeInfoFromProjectN/TypeInfo_ImplementedInterfacesTests.cs
src/libraries/System.Reflection.MetadataLoadContext/tests/src/Tests/TypeInfoFromProjectN/TypeInfo_IsAssignableFromTests.cs
src/libraries/System.Reflection.MetadataLoadContext/tests/src/Tests/TypeInfoFromProjectN/TypeInfo_MethodTests.cs
src/libraries/System.Reflection/tests/TypeInfoTests.cs
src/libraries/System.Runtime.Caching/src/System/Runtime/Caching/ChangeMonitor.cs
src/libraries/System.Runtime.Caching/src/System/Runtime/Caching/Configuration/MemoryCacheSection.cs
src/libraries/System.Runtime.Caching/tests/System.Runtime.Caching/MemoryCacheTest.cs
src/libraries/System.Runtime.CompilerServices.Unsafe/ref/System.Runtime.CompilerServices.Unsafe.cs
src/libraries/System.Runtime.Extensions/tests/System/Math.cs
src/libraries/System.Runtime.Extensions/tests/System/MathF.netcoreapp.cs
src/libraries/System.Runtime.Intrinsics/ref/System.Runtime.Intrinsics.cs
src/libraries/System.Runtime.Loader/ref/System.Runtime.Loader.cs
src/libraries/System.Runtime.Loader/tests/System.Runtime.Loader.Noop.Assembly/TestClass.cs
src/libraries/System.Runtime.Numerics/tests/BigInteger/divide.cs
src/libraries/System.Runtime.Numerics/tests/BigInteger/gcd.cs
src/libraries/System.Runtime.Numerics/tests/BigInteger/multiply.cs
src/libraries/System.Runtime.Numerics/tests/BigInteger/op_divide.cs
src/libraries/System.Runtime.Numerics/tests/BigInteger/parse.cs
src/libraries/System.Runtime.Numerics/tests/BigInteger/pow.cs
src/libraries/System.Runtime.Numerics/tests/BigInteger/sign.cs
src/libraries/System.Runtime.Serialization.Xml/tests/DataContractSerializer.cs
src/libraries/System.Runtime.Serialization.Xml/tests/SerializationTestTypes/DataContractResolverLibrary.cs
src/libraries/System.Runtime.WindowsRuntime/src/System/IO/StreamOperationsImplementation.cs
src/libraries/System.Runtime.WindowsRuntime/src/System/IO/WinRtToNetFxStreamAdapter.cs
src/libraries/System.Runtime.WindowsRuntime/src/System/IO/WindowsRuntimeStreamExtensions.cs
src/libraries/System.Runtime.WindowsRuntime/src/System/Resources/WindowsRuntimeResourceManager.cs
src/libraries/System.Runtime.WindowsRuntime/src/System/Runtime/InteropServices/WindowsRuntime/WindowsRuntimeBufferExtensions.cs
src/libraries/System.Runtime/ref/System.Runtime.cs
src/libraries/System.Runtime/tests/System/ArgIteratorTests.netcoreapp.cs
src/libraries/System.Runtime/tests/System/StringTests.netcoreapp.cs
src/libraries/System.Runtime/tests/System/Text/ASCIIUtilityTests.netcoreapp.cs
src/libraries/System.Security.AccessControl/tests/DiscretionaryAcl/DiscretionaryAcl_Constructor3.cs
src/libraries/System.Security.AccessControl/tests/DiscretionaryAcl/DiscretionaryAcl_Index.cs
src/libraries/System.Security.AccessControl/tests/DiscretionaryAcl/DiscretionaryAcl_Purge.cs
src/libraries/System.Security.AccessControl/tests/DiscretionaryAcl/DiscretionaryAcl_RemoveAccess.cs
src/libraries/System.Security.AccessControl/tests/DiscretionaryAcl/DiscretionaryAcl_RemoveAccessSpecific.cs
src/libraries/System.Security.AccessControl/tests/DiscretionaryAcl/DiscretionaryAcl_RemoveInheritedAces.cs
src/libraries/System.Security.Cryptography.Csp/src/Internal/Cryptography/BasicSymmetricCipherCsp.cs
src/libraries/System.Security.Cryptography.Csp/src/System/Security/Cryptography/PasswordDeriveBytes.cs
src/libraries/System.Security.Cryptography.Xml/src/System/Security/Cryptography/Xml/EncryptedReference.cs
src/libraries/System.Security.Cryptography.Xml/src/System/Security/Cryptography/Xml/SymmetricKeyWrap.cs
src/libraries/System.Security.Cryptography.Xml/tests/AssertCrypto.cs
src/libraries/System.Security.Cryptography.Xml/tests/DSAKeyValueTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/DataObjectTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/DataReferenceTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/EncryptedXmlTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/KeyInfoNameTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/KeyInfoNodeTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/KeyInfoRetrievalMethodTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/KeyInfoTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/KeyInfoX509DataTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/RSAKeyValueTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/ReferenceTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/SignatureTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/SignedInfoTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/SignedXmlTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/TransformChainTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/TransformTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/XmlDecryptionTransformTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/XmlDsigBase64TransformTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/XmlDsigC14NTransformTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/XmlDsigC14NWithCommentsTransformTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/XmlDsigEnvelopedSignatureTransformTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/XmlDsigExcC14NTransformTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/XmlDsigExcC14NWithCommentsTransformTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/XmlDsigXPathTransformTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/XmlDsigXsltTransformTest.cs
src/libraries/System.Security.Cryptography.Xml/tests/XmlLicenseTransformTest.cs
src/libraries/System.Security.Permissions/src/System/Configuration/ConfigurationPermissionAttribute.cs
src/libraries/System.Security.Permissions/src/System/Security/Permissions/IsolatedStorageFilePermissionAttribute.cs
src/libraries/System.Security.Permissions/src/System/Security/Permissions/MediaPermission.cs
src/libraries/System.Security.Permissions/src/System/Security/Permissions/WebBrowserPermission.cs
src/libraries/System.Security.Permissions/src/System/Web/AspNetHostingPermissionAttribute.cs
src/libraries/System.Security.Permissions/tests/PrincipalPermissionTests.cs
src/libraries/System.Security.Permissions/tests/SecurityElementTests.cs
src/libraries/System.ServiceModel.Syndication/src/System/ServiceModel/Syndication/InlineCategoriesDocument.cs
src/libraries/System.ServiceModel.Syndication/src/System/ServiceModel/Syndication/SyndicationFeedFormatter.cs
src/libraries/System.ServiceModel.Syndication/src/System/ServiceModel/Syndication/SyndicationItemFormatter.cs
src/libraries/System.ServiceModel.Syndication/tests/Utils/XmlDiffDocument.cs
src/libraries/System.ServiceProcess.ServiceController/src/System/ServiceProcess/ServiceController.cs
src/libraries/System.Text.Encoding.CodePages/src/System/Text/DBCSCodePageEncoding.cs
src/libraries/System.Text.Encoding.CodePages/src/System/Text/DecoderBestFitFallback.cs
src/libraries/System.Text.Encoding.CodePages/src/System/Text/EncoderBestFitFallback.cs
src/libraries/System.Text.Encoding.CodePages/src/System/Text/SBCSCodePageEncoding.cs
src/libraries/System.Text.Encoding/tests/Decoder/Decoder.cs
src/libraries/System.Text.Encoding/tests/Encoder/Encoder.cs
src/libraries/System.Text.Encodings.Web/src/System/Text/Unicode/UnicodeHelpers.cs
src/libraries/System.Text.Encodings.Web/tests/UrlEncoderTests.cs
src/libraries/System.Text.Json/src/System/Text/Json/Serialization/JsonSerializer.Read.String.cs
src/libraries/System.Text.Json/src/System/Text/Json/Serialization/JsonSerializer.Write.ByteArray.cs
src/libraries/System.Text.Json/src/System/Text/Json/Serialization/JsonSerializer.Write.String.cs
src/libraries/System.Text.Json/src/System/Text/Json/Writer/JsonWriterHelper.Transcoding.cs
src/libraries/System.Text.RegularExpressions/src/System/Text/RegularExpressions/Regex.Replace.cs
src/libraries/System.Threading.Overlapped/ref/System.Threading.Overlapped.cs
src/libraries/System.Threading.Overlapped/tests/AsyncResult.cs
src/libraries/System.Threading.Overlapped/tests/DllImport.cs
src/libraries/System.Threading.Tasks.Dataflow/src/Base/DataflowBlock.cs
src/libraries/System.Threading.Tasks.Dataflow/src/Internal/Common.cs
src/libraries/System.Threading.Tasks.Parallel/tests/ParallelStateTest.cs
src/libraries/System.Threading.Tasks/tests/CESchedulerPairTests.cs
src/libraries/System.Threading.ThreadPool/ref/System.Threading.ThreadPool.cs
src/libraries/System.Threading/src/System/Threading/Barrier.cs
src/libraries/System.Threading/src/System/Threading/CountdownEvent.cs
src/libraries/System.Transactions.Local/tests/EnlistTest.cs
src/libraries/System.Transactions.Local/tests/TransactionScopeTest.cs
src/libraries/System.Utf8String.Experimental/tests/System/MemoryTests.cs
src/libraries/System.Utf8String.Experimental/tests/System/Utf8TestUtilities.cs
src/libraries/System.Web.HttpUtility/tests/HttpUtility/HttpUtilityTest.cs

index 2f4c8c0..b7310b1 100644 (file)
@@ -3,5 +3,6 @@
     <PackageReference Include="Microsoft.DotNet.CodeAnalysis" Version="$(MicrosoftDotNetCodeAnalysisPackageVersion)" />
     <PackageReference Include="Microsoft.CodeAnalysis.Common" Version="3.3.0-beta1-final" />
     <PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="2.9.4" />
+    <PackageReference Include="StyleCop.Analyzers" Version="1.1.118" />
   </ItemGroup>
 </Project>
index da3caf1..1fa5aaa 100644 (file)
     <Rule Id="CA5371" Action="None" /> <!-- Use XmlReader For Schema Read -->
     <Rule Id="CA5372" Action="None" /> <!-- Use XmlReader For XPathDocument -->
   </Rules>
+  <Rules AnalyzerId="StyleCop.Analyzers" RuleNamespace="StyleCop.Analyzers">
+    <Rule Id="AD0001" Action="None" /> <!-- Analyzer threw an exception -->
+    <Rule Id="SA0001" Action="None" /> <!-- XML comments -->
+    <Rule Id="SA1000" Action="None" /> <!-- The keyword 'if' should be followed by a space -->
+    <Rule Id="SA1001" Action="None" /> <!-- Commas should be followed by whitespace -->
+    <Rule Id="SA1002" Action="None" /> <!-- Semicolons should not be preceded by a space -->
+    <Rule Id="SA1003" Action="None" /> <!-- Operator should not appear at the end of a line -->
+    <Rule Id="SA1004" Action="None" /> <!-- Documentation line should begin with a space -->
+    <Rule Id="SA1005" Action="None" /> <!-- Single line comment should begin with a space -->
+    <Rule Id="SA1008" Action="None" /> <!-- Opening parenthesis should not be preceded by a space -->
+    <Rule Id="SA1009" Action="None" /> <!-- Closing parenthesis should not be followed by a space -->
+    <Rule Id="SA1010" Action="None" /> <!-- Opening square brackets should not be preceded by a space -->
+    <Rule Id="SA1011" Action="None" /> <!-- Closing square bracket should be followed by a space -->
+    <Rule Id="SA1012" Action="None" /> <!-- Opening brace should be followed by a space -->
+    <Rule Id="SA1013" Action="None" /> <!-- Closing brace should be preceded by a space -->
+    <Rule Id="SA1015" Action="None" /> <!-- Closing generic bracket should not be followed by a space -->
+    <Rule Id="SA1019" Action="None" /> <!-- Member access symbol '.' should not be preceded by a space -->
+    <Rule Id="SA1020" Action="None" /> <!-- Increment symbol '++' should not be preceded by a space -->
+    <Rule Id="SA1021" Action="None" /> <!-- Negative sign should be preceded by a space -->
+    <Rule Id="SA1023" Action="None" /> <!-- Dereference symbol '*' should not be preceded by a space." -->
+    <Rule Id="SA1024" Action="None" /> <!-- Colon should be followed by a space -->
+    <Rule Id="SA1025" Action="None" /> <!-- Code should not contain multiple whitespace characters in a row -->
+    <Rule Id="SA1026" Action="None" /> <!-- The keyword 'new' should not be followed by a space or a blank line -->
+    <Rule Id="SA1028" Action="None" /> <!-- Code should not contain trailing whitespace -->
+    <Rule Id="SA1100" Action="None" /> <!-- Do not prefix calls with base unless local implementation exists -->
+    <Rule Id="SA1101" Action="None" /> <!-- Prefix local calls with this -->
+    <Rule Id="SA1106" Action="None" /> <!-- Code should not contain empty statements -->
+    <Rule Id="SA1107" Action="None" /> <!-- Code should not contain multiple statements on one line -->
+    <Rule Id="SA1108" Action="None" /> <!-- Block statements should not contain embedded comments -->
+    <Rule Id="SA1110" Action="None" /> <!-- Opening parenthesis or bracket should be on declaration line -->
+    <Rule Id="SA1111" Action="None" /> <!-- Closing parenthesis should be on line of last parameter -->
+    <Rule Id="SA1112" Action="None" /> <!-- Closing parenthesis should be on line of opening parenthesis -->
+    <Rule Id="SA1113" Action="None" /> <!-- Comma should be on the same line as previous parameter -->
+    <Rule Id="SA1114" Action="None" /> <!-- Parameter list should follow declaration -->
+    <Rule Id="SA1115" Action="None" /> <!-- The parameter should begin on the line after the previous parameter -->
+    <Rule Id="SA1116" Action="None" /> <!-- Split parameters should start on line after declaration -->
+    <Rule Id="SA1117" Action="None" /> <!-- Parameters should be on same line or separate lines -->
+    <Rule Id="SA1118" Action="None" /> <!-- Parameter should not span multiple lines -->
+    <Rule Id="SA1119" Action="None" /> <!-- Statement should not use unnecessary parenthesis -->
+    <Rule Id="SA1120" Action="None" /> <!-- Comments should contain text -->
+    <Rule Id="SA1122" Action="None" /> <!-- Use string.Empty for empty strings -->
+    <Rule Id="SA1123" Action="None" /> <!-- Region should not be located within a code element -->
+    <Rule Id="SA1124" Action="None" /> <!-- Do not use regions -->
+    <Rule Id="SA1125" Action="None" /> <!-- Use shorthand for nullable types -->
+    <Rule Id="SA1127" Action="None" /> <!-- Generic type constraints should be on their own line -->
+    <Rule Id="SA1128" Action="None" /> <!-- Put constructor initializers on their own line -->
+    <Rule Id="SA1129" Action="None" /> <!-- Do not use default value type constructor -->
+    <Rule Id="SA1130" Action="None" /> <!-- Use lambda syntax -->
+    <Rule Id="SA1131" Action="None" /> <!-- Constant values should appear on the right-hand side of comparisons -->
+    <Rule Id="SA1132" Action="None" /> <!-- Do not combine fields -->
+    <Rule Id="SA1133" Action="None" /> <!-- Do not combine attributes -->
+    <Rule Id="SA1134" Action="None" /> <!-- Each attribute should be placed on its own line of code -->
+    <Rule Id="SA1135" Action="None" /> <!-- Using directive should be qualified -->
+    <Rule Id="SA1136" Action="None" /> <!-- Enum values should be on separate lines -->
+    <Rule Id="SA1137" Action="None" /> <!-- Elements should have the same indentation -->
+    <Rule Id="SA1139" Action="None" /> <!-- Use literal suffix notation instead of casting -->
+    <Rule Id="SA1200" Action="None" /> <!-- Using directive should appear within a namespace declaration -->
+    <Rule Id="SA1201" Action="None" /> <!-- Elements should appear in the correct order -->
+    <Rule Id="SA1202" Action="None" /> <!-- Elements should be ordered by access -->
+    <Rule Id="SA1203" Action="None" /> <!-- Constants should appear before fields -->
+    <Rule Id="SA1204" Action="None" /> <!-- Static elements should appear before instance elements -->
+    <Rule Id="SA1205" Action="None" /> <!-- Partial elements should declare an access modifier -->
+    <Rule Id="SA1206" Action="None" /> <!-- Modifer ordering -->
+    <Rule Id="SA1208" Action="None" /> <!-- Using directive ordering -->
+    <Rule Id="SA1209" Action="None" /> <!-- Using alias directives should be placed after all using namespace directives -->
+    <Rule Id="SA1210" Action="None" /> <!-- Using directives should be ordered alphabetically by the namespaces -->
+    <Rule Id="SA1211" Action="None" /> <!-- Using alias directive ordering -->
+    <Rule Id="SA1212" Action="None" /> <!-- A get accessor appears after a set accessor within a property or indexer -->
+    <Rule Id="SA1214" Action="None" /> <!-- Readonly fields should appear before non-readonly fields -->
+    <Rule Id="SA1216" Action="None" /> <!-- Using static directives should be placed at the correct location -->
+    <Rule Id="SA1300" Action="None" /> <!-- Element should begin with an uppercase letter -->
+    <Rule Id="SA1302" Action="None" /> <!-- Interface names should begin with I -->
+    <Rule Id="SA1303" Action="None" /> <!-- Const field names should begin with upper-case letter -->
+    <Rule Id="SA1304" Action="None" /> <!-- Non-private readonly fields should begin with upper-case letter -->
+    <Rule Id="SA1306" Action="None" /> <!-- Field should begin with lower-case letter -->
+    <Rule Id="SA1307" Action="None" /> <!-- Field should begin with upper-case letter -->
+    <Rule Id="SA1308" Action="None" /> <!-- Field should not begin with the prefix 's_' -->
+    <Rule Id="SA1309" Action="None" /> <!-- Field names should not begin with underscore -->
+    <Rule Id="SA1310" Action="None" /> <!-- Field should not contain an underscore -->
+    <Rule Id="SA1311" Action="None" /> <!-- Static readonly fields should begin with upper-case letter -->
+    <Rule Id="SA1312" Action="None" /> <!-- Variable should begin with lower-case letter -->
+    <Rule Id="SA1313" Action="None" /> <!-- Parameter should begin with lower-case letter -->
+    <Rule Id="SA1314" Action="None" /> <!-- Type parameter names should begin with T -->
+    <Rule Id="SA1400" Action="None" /> <!-- Element should declare an access modifier -->
+    <Rule Id="SA1401" Action="None" /> <!-- Fields should be private -->
+    <Rule Id="SA1402" Action="None" /> <!-- File may only contain a single type -->
+    <Rule Id="SA1403" Action="None" /> <!-- File may only contain a single namespace -->
+    <Rule Id="SA1404" Action="None" /> <!-- Code analysis suppression should have justification -->
+    <Rule Id="SA1405" Action="None" /> <!-- Debug.Assert should provide message text -->
+    <Rule Id="SA1407" Action="None" /> <!-- Arithmetic expressions should declare precedence -->
+    <Rule Id="SA1408" Action="None" /> <!-- Conditional expressions should declare precedence -->
+    <Rule Id="SA1411" Action="None" /> <!-- Attribute constructor should not use unnecessary parenthesis -->
+    <Rule Id="SA1413" Action="None" /> <!-- Use trailing comma in multi-line initializers -->
+    <Rule Id="SA1500" Action="None" /> <!-- Braces for multi-line statements should not share line -->
+    <Rule Id="SA1501" Action="None" /> <!-- Statement should not be on a single line -->
+    <Rule Id="SA1502" Action="None" /> <!-- Element should not be on a single line -->
+    <Rule Id="SA1503" Action="None" /> <!-- Braces should not be omitted -->
+    <Rule Id="SA1504" Action="None" /> <!-- All accessors should be single-line or multi-line -->
+    <Rule Id="SA1505" Action="None" /> <!-- An opening brace should not be followed by a blank line -->
+    <Rule Id="SA1506" Action="None" /> <!-- Element documentation headers should not be followed by blank line -->
+    <Rule Id="SA1507" Action="None" /> <!-- Code should not contain multiple blank lines in a row -->
+    <Rule Id="SA1508" Action="None" /> <!-- A closing brace should not be preceded by a blank line -->
+    <Rule Id="SA1509" Action="None" /> <!-- Opening braces should not be preceded by blank line -->
+    <Rule Id="SA1510" Action="None" /> <!-- 'else' statement should not be preceded by a blank line -->
+    <Rule Id="SA1512" Action="None" /> <!-- Single-line comments should not be followed by blank line -->
+    <Rule Id="SA1513" Action="None" /> <!-- Closing brace should be followed by blank line -->
+    <Rule Id="SA1514" Action="None" /> <!-- Element documentation header should be preceded by blank line -->
+    <Rule Id="SA1515" Action="None" /> <!-- Single-line comment should be preceded by blank line -->
+    <Rule Id="SA1516" Action="None" /> <!-- Elements should be separated by blank line -->
+    <Rule Id="SA1517" Action="None" /> <!-- Code should not contain blank lines at start of file -->
+    <Rule Id="SA1518" Action="None" /> <!-- Code should not contain blank lines at the end of the file -->
+    <Rule Id="SA1519" Action="None" /> <!-- Braces should not be omitted from multi-line child statement -->
+    <Rule Id="SA1520" Action="None" /> <!-- Use braces consistently -->
+    <Rule Id="SA1600" Action="None" /> <!-- Elements should be documented -->
+    <Rule Id="SA1601" Action="None" /> <!-- Partial elements should be documented -->
+    <Rule Id="SA1602" Action="None" /> <!-- Enumeration items should be documented -->
+    <Rule Id="SA1604" Action="None" /> <!-- Element documentation should have summary -->
+    <Rule Id="SA1605" Action="None" /> <!-- Partial element documentation should have summary -->
+    <Rule Id="SA1606" Action="None" /> <!-- Element documentation should have summary text -->
+    <Rule Id="SA1608" Action="None" /> <!-- Element documentation should not have default summary -->
+    <Rule Id="SA1610" Action="None" /> <!-- Property documentation should have value text -->
+    <Rule Id="SA1611" Action="None" /> <!-- The documentation for parameter 'message' is missing -->
+    <Rule Id="SA1612" Action="None" /> <!-- The parameter documentation is at incorrect position -->
+    <Rule Id="SA1614" Action="None" /> <!-- Element parameter documentation should have text -->
+    <Rule Id="SA1615" Action="None" /> <!-- Element return value should be documented -->
+    <Rule Id="SA1616" Action="None" /> <!-- Element return value documentation should have text -->
+    <Rule Id="SA1617" Action="None" /> <!-- Void return value should not be documented -->
+    <Rule Id="SA1618" Action="None" /> <!-- The documentation for type parameter is missing -->
+    <Rule Id="SA1619" Action="None" /> <!-- The documentation for type parameter is missing -->
+    <Rule Id="SA1622" Action="None" /> <!-- Generic type parameter documentation should have text -->
+    <Rule Id="SA1623" Action="None" /> <!-- Property documentation text -->
+    <Rule Id="SA1624" Action="None" /> <!-- Because the property only contains a visible get accessor, the documentation summary text should begin with 'Gets' -->
+    <Rule Id="SA1625" Action="None" /> <!-- Element documentation should not be copied and pasted -->
+    <Rule Id="SA1626" Action="None" /> <!-- Single-line comments should not use documentation style slashes -->
+    <Rule Id="SA1627" Action="None" /> <!-- The documentation text within the \'exception\' tag should not be empty -->
+    <Rule Id="SA1629" Action="None" /> <!-- Documentation text should end with a period -->
+    <Rule Id="SA1633" Action="None" /> <!-- File should have header -->
+    <Rule Id="SA1642" Action="None" /> <!-- Constructor summary documentation should begin with standard text -->
+    <Rule Id="SA1643" Action="None" /> <!-- Destructor summary documentation should begin with standard text -->
+    <Rule Id="SA1649" Action="None" /> <!-- File name should match first type name -->
+  </Rules>
   <Rules AnalyzerId="xunit.analyzers" RuleNamespace="xunit.analyzers">
     <Rule Id="xUnit1019" Action="None" /> <!-- MemberData must reference a member providing a valid data type -->
     <Rule Id="xUnit1024" Action="None" /> <!-- Test methods cannot have overloads -->
index 8978e49..7c6d02b 100644 (file)
@@ -398,7 +398,7 @@ internal static partial class Interop
         /// Returns basic info about thread. If tis is 0, it will return
         /// info for process e.g. main thread.
         /// </returns>
-        public unsafe static proc_stats GetThreadInfo(int pid, int tid)
+        public static unsafe proc_stats GetThreadInfo(int pid, int tid)
         {
             proc_stats ret = new proc_stats();
             kinfo_proc* info = null;
index c3c6784..5b2dfdc 100644 (file)
@@ -8,7 +8,8 @@ using System.Runtime.InteropServices;
 
 using Microsoft.Win32.SafeHandles;
 
-using CFAbsoluteTime=System.Double;
+#pragma warning disable SA1121 // we don't want to simplify built-ins here as we're using aliasing
+using CFAbsoluteTime = System.Double;
 
 internal static partial class Interop
 {
index fb1ae4e..5b95ae5 100644 (file)
@@ -7,6 +7,7 @@ using System.Runtime.InteropServices;
 
 using Microsoft.Win32.SafeHandles;
 
+#pragma warning disable SA1121 // we don't want to simplify built-ins here as we're using aliasing
 using CFStringRef = System.IntPtr;
 using CFArrayRef = System.IntPtr;
 using FSEventStreamRef = System.IntPtr;
index 1ecb203..d35e529 100644 (file)
@@ -10,7 +10,7 @@ internal static partial class Interop
 {
     internal static partial class AppleCrypto
     {
-        internal unsafe static void GetRandomBytes(byte* pbBuffer, int count)
+        internal static unsafe void GetRandomBytes(byte* pbBuffer, int count)
         {
             Debug.Assert(count >= 0);
 
@@ -29,6 +29,6 @@ internal static partial class Interop
         }
 
         [DllImport(Libraries.AppleCryptoNative)]
-        private unsafe static extern int AppleCryptoNative_GetRandomBytes(byte* buf, int num, out int errorCode);
+        private static extern unsafe int AppleCryptoNative_GetRandomBytes(byte* buf, int num, out int errorCode);
     }
 }
index 0484691..adf74ce 100644 (file)
@@ -9,7 +9,7 @@ internal static partial class Interop
 {
     internal static partial class Sys
     {
-        internal unsafe static uint[] GetGroupList(string userName, uint primaryGroupId)
+        internal static unsafe uint[] GetGroupList(string userName, uint primaryGroupId)
         {
             const int InitialGroupsLength =
 #if DEBUG
index 3ff0cba..d3efec1 100644 (file)
@@ -15,9 +15,9 @@ internal static partial class Interop
         private const int StackBufferSize = 256;
 
         [DllImport(Libraries.SystemNative, EntryPoint = "SystemNative_Stat", SetLastError = true)]
-        internal unsafe static extern int Stat(ref byte path, out FileStatus output);
+        internal static extern unsafe int Stat(ref byte path, out FileStatus output);
 
-        internal unsafe static int Stat(ReadOnlySpan<char> path, out FileStatus output)
+        internal static unsafe int Stat(ReadOnlySpan<char> path, out FileStatus output)
         {
             byte* buffer = stackalloc byte[StackBufferSize];
             var converter = new ValueUtf8Converter(new Span<byte>(buffer, StackBufferSize));
@@ -29,7 +29,7 @@ internal static partial class Interop
         [DllImport(Libraries.SystemNative, EntryPoint = "SystemNative_LStat", SetLastError = true)]
         internal static extern int LStat(ref byte path, out FileStatus output);
 
-        internal unsafe static int LStat(ReadOnlySpan<char> path, out FileStatus output)
+        internal static unsafe int LStat(ReadOnlySpan<char> path, out FileStatus output)
         {
             byte* buffer = stackalloc byte[StackBufferSize];
             var converter = new ValueUtf8Converter(new Span<byte>(buffer, StackBufferSize));
index 18afd9f..f3b7ab7 100644 (file)
@@ -24,6 +24,6 @@ internal static partial class Interop
         /// Returns 0 on success; otherwise, returns -1 
         /// </returns>
         [DllImport(Libraries.SystemNative, EntryPoint = "SystemNative_UTimensat", SetLastError = true)]
-        internal static unsafe extern int UTimensat(string path, TimeSpec* times);
+        internal static extern unsafe int UTimensat(string path, TimeSpec* times);
     }
 }
index 4d82a7d..793f7bb 100644 (file)
@@ -23,7 +23,7 @@ internal static partial class Interop
     internal static partial class OpenSsl
     {
         private static readonly Ssl.SslCtxSetVerifyCallback s_verifyClientCertificate = VerifyClientCertificate;
-        private unsafe static readonly Ssl.SslCtxSetAlpnCallback s_alpnServerCallback = AlpnServerSelectCallback;
+        private static unsafe readonly Ssl.SslCtxSetAlpnCallback s_alpnServerCallback = AlpnServerSelectCallback;
         private static readonly IdnMapping s_idnMapping = new IdnMapping();
 
         #region internal methods
index 2643abe..eecdac8 100644 (file)
@@ -9,7 +9,7 @@ internal static partial class Interop
 {
     internal static partial class Crypto
     {
-        internal unsafe static bool GetRandomBytes(byte* pbBuffer, int count)
+        internal static unsafe bool GetRandomBytes(byte* pbBuffer, int count)
         {
             Debug.Assert(count >= 0);
 
@@ -18,6 +18,6 @@ internal static partial class Interop
 
         [DllImport(Libraries.CryptoNative)]
         [return: MarshalAs(UnmanagedType.Bool)]
-        private unsafe static extern bool CryptoNative_GetRandomBytes(byte* buf, int num);
+        private static extern unsafe bool CryptoNative_GetRandomBytes(byte* buf, int num);
     }
 }
index 8381f03..ddaf44a 100644 (file)
@@ -33,7 +33,7 @@ internal static partial class Interop
         internal static extern int SslCtxSetAlpnProtos(SafeSslContextHandle ctx, IntPtr protos, int len);
 
         [DllImport(Libraries.CryptoNative, EntryPoint = "CryptoNative_SslCtxSetAlpnSelectCb")]
-        internal static unsafe extern void SslCtxSetAlpnSelectCb(SafeSslContextHandle ctx, SslCtxSetAlpnCallback callback, IntPtr arg);
+        internal static extern unsafe void SslCtxSetAlpnSelectCb(SafeSslContextHandle ctx, SslCtxSetAlpnCallback callback, IntPtr arg);
 
         internal static unsafe int SslCtxSetAlpnProtos(SafeSslContextHandle ctx, List<SslApplicationProtocol> protocols)
         {
index 91dbad7..712a776 100644 (file)
@@ -27,7 +27,7 @@ internal static partial class Interop
         internal static extern void SslCtxSetVerify(SafeSslContextHandle ctx, SslCtxSetVerifyCallback callback);
 
         [DllImport(Libraries.CryptoNative, EntryPoint = "CryptoNative_SetCiphers")]
-        internal static unsafe extern bool SetCiphers(SafeSslContextHandle ctx, byte* cipherList, byte* cipherSuites);
+        internal static extern unsafe bool SetCiphers(SafeSslContextHandle ctx, byte* cipherList, byte* cipherSuites);
 
         [DllImport(Libraries.CryptoNative, EntryPoint = "CryptoNative_SetEncryptionPolicy")]
         internal static extern bool SetEncryptionPolicy(SafeSslContextHandle ctx, EncryptionPolicy policy);
index 5299c95..44a24db 100644 (file)
@@ -11,7 +11,7 @@ internal partial class Interop
     internal partial class Advapi32
     {
         [DllImport(Libraries.Advapi32, SetLastError = true)]
-        internal unsafe static extern bool AdjustTokenPrivileges(
+        internal static extern unsafe bool AdjustTokenPrivileges(
             SafeTokenHandle TokenHandle,
             bool DisableAllPrivileges,
             TOKEN_PRIVILEGE* NewState,
index a4c345b..a90f9e2 100644 (file)
@@ -11,7 +11,7 @@ internal partial class Interop
     internal partial class Advapi32
     {
         [DllImport(Libraries.Advapi32, CharSet = CharSet.Unicode, SetLastError = true)]
-        internal extern unsafe static bool ControlService(SafeServiceHandle serviceHandle, int control, SERVICE_STATUS* pStatus);
+        internal extern static unsafe bool ControlService(SafeServiceHandle serviceHandle, int control, SERVICE_STATUS* pStatus);
 
     }
 }
index 3430c2d..4261dff 100644 (file)
@@ -11,7 +11,7 @@ internal static partial class Interop
     internal static partial class Advapi32
     {
         [DllImport(Interop.Libraries.Advapi32, SetLastError = true)]
-        internal unsafe static extern bool GetTokenInformation(
+        internal static extern unsafe bool GetTokenInformation(
             SafeAccessTokenHandle TokenHandle,
             TOKEN_INFORMATION_CLASS TokenInformationClass,
             void* TokenInformation,
index e20f220..5eda5da 100644 (file)
@@ -10,6 +10,6 @@ internal partial class Interop
     internal partial class Advapi32
     {
         [DllImport(Libraries.Advapi32, CharSet = CharSet.Unicode, SetLastError = true)]
-        public unsafe extern static bool SetServiceStatus(IntPtr serviceStatusHandle, SERVICE_STATUS* status);
+        public extern static unsafe bool SetServiceStatus(IntPtr serviceStatusHandle, SERVICE_STATUS* status);
     }
 }
index 670f01d..2c43c82 100644 (file)
@@ -15,7 +15,7 @@ internal partial class Interop
         /// <param name="function">Identifies the function to be performed by the driver. Values of less than 0x800 are reserved for Microsoft. Values of 0x800 and higher can be used by vendors.</param>
         /// <param name="method">Indicates how the system will pass data between the caller of DeviceIoControl (or IoBuildDeviceIoControlRequest) and the driver that handles the IRP.</param>
         /// <param name="access">Indicates the type of access that a caller must request when opening the file object that represents the device (see IRP_MJ_CREATE).</param>
-        internal unsafe static uint CTL_CODE(
+        internal static unsafe uint CTL_CODE(
             ushort deviceType,
             ushort function,
             byte method,
index b0cef5d..6c06deb 100644 (file)
@@ -10,7 +10,7 @@ internal partial class Interop
     {
         // https://msdn.microsoft.com/en-us/library/windows/desktop/dd317762.aspx
         [DllImport(Libraries.Kernel32, CharSet = CharSet.Unicode, SetLastError = true, ExactSpelling = true)]
-        public unsafe static extern int CompareStringOrdinal(
+        public static extern unsafe int CompareStringOrdinal(
             ref char lpString1,
             int cchCount1,
             ref char lpString2,
index 3fe8360..eb07f8c 100644 (file)
@@ -16,7 +16,7 @@ internal partial class Interop
         /// WARNING: The private methods do not implicitly handle long paths. Use CreateFile.
         /// </summary>
         [DllImport(Libraries.Kernel32, EntryPoint = "CreateFileW", SetLastError = true, CharSet = CharSet.Unicode, BestFitMapping = false, ExactSpelling = true)]
-        private unsafe static extern IntPtr CreateFilePrivate(
+        private static extern unsafe IntPtr CreateFilePrivate(
             string lpFileName,
             int dwDesiredAccess,
             FileShare dwShareMode,
@@ -25,7 +25,7 @@ internal partial class Interop
             int dwFlagsAndAttributes,
             IntPtr hTemplateFile);
 
-        internal unsafe static SafeFileHandle CreateFile(
+        internal static unsafe SafeFileHandle CreateFile(
             string lpFileName,
             int dwDesiredAccess,
             FileShare dwShareMode,
@@ -50,7 +50,7 @@ internal partial class Interop
             }
         }
 
-        internal unsafe static SafeFileHandle CreateFile(
+        internal static unsafe SafeFileHandle CreateFile(
             string lpFileName,
             int dwDesiredAccess,
             FileShare dwShareMode,
@@ -69,7 +69,7 @@ internal partial class Interop
             }
         }
 
-        internal unsafe static IntPtr CreateFile_IntPtr(
+        internal static unsafe IntPtr CreateFile_IntPtr(
             string lpFileName,
             int dwDesiredAccess,
             FileShare dwShareMode,
index 8480332..5613e4c 100644 (file)
@@ -13,7 +13,7 @@ internal partial class Interop
     {
         // https://msdn.microsoft.com/en-us/library/windows/desktop/hh449422.aspx
         [DllImport(Libraries.Kernel32, EntryPoint = "CreateFile2", SetLastError = true, CharSet = CharSet.Unicode, BestFitMapping = false)]
-        internal unsafe static extern IntPtr CreateFile2(
+        internal static extern unsafe IntPtr CreateFile2(
             string lpFileName,
             int dwDesiredAccess,
             FileShare dwShareMode,
@@ -85,7 +85,7 @@ internal partial class Interop
             }
         }
 
-        internal unsafe static IntPtr CreateFile_IntPtr(
+        internal static unsafe IntPtr CreateFile_IntPtr(
             string lpFileName,
             int dwDesiredAccess,
             FileShare dwShareMode,
index 91db99d..13abc6f 100644 (file)
@@ -15,7 +15,7 @@ internal partial class Interop
         public const int FORMAT_MESSAGE_ARGUMENT_ARRAY = 0x00002000;
 
         [DllImport(Libraries.Kernel32, CharSet = CharSet.Unicode, SetLastError = true, BestFitMapping = true)]
-        public static unsafe extern int FormatMessage(
+        public static extern unsafe int FormatMessage(
             int dwFlags,
             SafeLibraryHandle lpSource,
             uint dwMessageId,
index 6126a92..dbdb548 100644 (file)
@@ -10,6 +10,6 @@ internal partial class Interop
     internal partial class Kernel32
     {
         [DllImport(Libraries.Kernel32, CharSet = CharSet.Unicode, SetLastError = true, ExactSpelling = true)]
-        internal unsafe static extern uint GetConsoleTitleW(char* title, uint nSize);
+        internal static extern unsafe uint GetConsoleTitleW(char* title, uint nSize);
     }
 }
index 0f26e48..cb7c1c8 100644 (file)
@@ -10,7 +10,7 @@ internal partial class Interop
     internal partial class Kernel32
     {
         [DllImport(Libraries.Kernel32, SetLastError = true)]
-        internal unsafe static extern bool GetNamedPipeInfo(
+        internal static extern unsafe bool GetNamedPipeInfo(
             SafePipeHandle hNamedPipe,
             uint* lpFlags,
             uint* lpOutBufferSize,
index 70d83e6..9d1e0be 100644 (file)
@@ -10,7 +10,7 @@ internal partial class Interop
     internal partial class Kernel32
     {
         [DllImport(Libraries.Kernel32, EntryPoint = "GetVolumeInformationW", CharSet = CharSet.Unicode, SetLastError = true, BestFitMapping = false)]
-        internal static unsafe extern bool GetVolumeInformation(string drive, char* volumeName, int volumeNameBufLen, int* volSerialNumber, int* maxFileNameLen, out int fileSystemFlags, char* fileSystemName, int fileSystemNameBufLen);
+        internal static extern unsafe bool GetVolumeInformation(string drive, char* volumeName, int volumeNameBufLen, int* volSerialNumber, int* maxFileNameLen, out int fileSystemFlags, char* fileSystemName, int fileSystemNameBufLen);
 
         internal const uint FILE_SUPPORTS_ENCRYPTION = 0x00020000;
     }
index 86a608f..9cb3111 100644 (file)
@@ -12,7 +12,7 @@ internal partial class Interop
     internal partial class Kernel32
     {
         [DllImport(Libraries.Kernel32, EntryPoint = "ReadDirectoryChangesW", CharSet = CharSet.Unicode, SetLastError = true)]
-        internal static unsafe extern bool ReadDirectoryChangesW(
+        internal static extern unsafe bool ReadDirectoryChangesW(
             SafeFileHandle hDirectory,
             byte[] lpBuffer,
             uint nBufferLength,
index 671800b..ea05865 100644 (file)
@@ -18,6 +18,6 @@ internal static partial class Interop
         }
 
         [DllImport(Libraries.Kernel32, SetLastError = true)]
-        internal static unsafe extern bool SetFileCompletionNotificationModes(SafeHandle handle, FileCompletionNotificationModes flags);
+        internal static extern unsafe bool SetFileCompletionNotificationModes(SafeHandle handle, FileCompletionNotificationModes flags);
     }
 }
index 5b3123b..bf03297 100644 (file)
@@ -60,7 +60,7 @@ internal partial class Interop
             /// <summary>
             /// Gets the next info pointer or null if there are no more.
             /// </summary>
-            public unsafe static FILE_FULL_DIR_INFORMATION* GetNextInfo(FILE_FULL_DIR_INFORMATION* info)
+            public static unsafe FILE_FULL_DIR_INFORMATION* GetNextInfo(FILE_FULL_DIR_INFORMATION* info)
             {
                 if (info == null)
                     return null;
index 1fa7b72..32df952 100644 (file)
@@ -12,7 +12,7 @@ internal partial class Interop
         // https://msdn.microsoft.com/en-us/library/bb432380.aspx
         // https://msdn.microsoft.com/en-us/library/windows/hardware/ff566424.aspx
         [DllImport(Libraries.NtDll, CharSet = CharSet.Unicode, ExactSpelling = true)]
-        private unsafe static extern int NtCreateFile(
+        private static extern unsafe int NtCreateFile(
             out IntPtr FileHandle,
             DesiredAccess DesiredAccess,
             ref OBJECT_ATTRIBUTES ObjectAttributes,
@@ -25,7 +25,7 @@ internal partial class Interop
             void* EaBuffer,
             uint EaLength);
 
-        internal unsafe static (int status, IntPtr handle) CreateFile(
+        internal static unsafe (int status, IntPtr handle) CreateFile(
             ReadOnlySpan<char> path,
             IntPtr rootDirectory,
             CreateDisposition createDisposition,
index ed7843f..d854e26 100644 (file)
@@ -12,7 +12,7 @@ internal partial class Interop
         // https://msdn.microsoft.com/en-us/library/windows/hardware/ff556633.aspx
         // https://msdn.microsoft.com/en-us/library/windows/hardware/ff567047.aspx
         [DllImport(Libraries.NtDll, CharSet = CharSet.Unicode, ExactSpelling = true)]
-        public unsafe static extern int NtQueryDirectoryFile(
+        public static extern unsafe int NtQueryDirectoryFile(
             IntPtr FileHandle,
             IntPtr Event,
             IntPtr ApcRoutine,
index 4226795..e34c4e1 100644 (file)
@@ -10,7 +10,7 @@ internal partial class Interop
     internal partial class NtDll
     {
         [DllImport(Libraries.NtDll, CharSet = CharSet.Unicode)]
-        internal static unsafe extern int NtQuerySystemInformation(int query, void* dataPtr, int size, out int returnedSize);
+        internal static extern unsafe int NtQuerySystemInformation(int query, void* dataPtr, int size, out int returnedSize);
 
         internal const int NtQuerySystemProcessInformation = 5;
         internal const uint STATUS_INFO_LENGTH_MISMATCH = 0xC0000004;
index 05e8ce4..b6904e4 100644 (file)
@@ -11,7 +11,7 @@ internal partial class Interop
     {
         // https://msdn.microsoft.com/en-us/library/windows/desktop/ms680600(v=vs.85).aspx
         [DllImport(Libraries.NtDll, ExactSpelling = true)]
-        public unsafe static extern uint RtlNtStatusToDosError(
+        public static extern unsafe uint RtlNtStatusToDosError(
             int Status);
     }
 }
index 46031d9..dcac3a7 100644 (file)
@@ -9,7 +9,7 @@ internal partial class Interop
     internal partial class PerfCounter
     {
         [DllImport(Libraries.PerfCounter, CharSet = CharSet.Unicode)]
-        public static unsafe extern int FormatFromRawValue(
+        public static extern unsafe int FormatFromRawValue(
             uint dwCounterType,
             uint dwFormat,
             ref long pTimeBase,
index 03bd645..0a32a1c 100644 (file)
@@ -52,7 +52,7 @@ internal partial class Interop
         internal const uint SEE_MASK_FLAG_NO_UI = 0x00000400;
 
         [DllImport(Libraries.Shell32, ExactSpelling = true, CharSet = CharSet.Unicode, SetLastError = true)]
-        internal unsafe static extern bool ShellExecuteExW(
+        internal static extern unsafe bool ShellExecuteExW(
             SHELLEXECUTEINFO* pExecInfo);
     }
-}
\ No newline at end of file
+}
index 1858ffd..35879f9 100644 (file)
@@ -9,7 +9,7 @@ internal partial class Interop
 {
     internal partial class User32
     {
-           [DllImport(Libraries.User32, EntryPoint = "SendMessageTimeoutW")]
+        [DllImport(Libraries.User32, EntryPoint = "SendMessageTimeoutW")]
         public static extern IntPtr SendMessageTimeout(IntPtr hWnd, int msg, IntPtr wParam, IntPtr lParam, int flags, int timeout, out IntPtr pdwResult);
     }
 }
index ed8ffa4..4c2432e 100644 (file)
@@ -11,7 +11,7 @@ internal static partial class Interop
     internal static partial class Winsock
     {
         [DllImport(Interop.Libraries.Ws2_32, SetLastError = true)]
-        internal static unsafe extern bool WSAGetOverlappedResult(
+        internal static extern unsafe bool WSAGetOverlappedResult(
             [In] SafeSocketHandle socketHandle,
             [In] NativeOverlapped* overlapped,
             [Out] out uint bytesTransferred,
index 5464bfe..a11948f 100644 (file)
@@ -13,7 +13,7 @@ internal static partial class Interop
     internal static partial class Winsock
     {
         [DllImport(Interop.Libraries.Ws2_32, SetLastError = true)]
-        internal static unsafe extern SocketError WSARecv(
+        internal static extern unsafe SocketError WSARecv(
             SafeHandle socketHandle,
             WSABuffer* buffer,
             int bufferCount,
index d880e8e..56c2007 100644 (file)
@@ -13,7 +13,7 @@ internal static partial class Interop
     internal static partial class Winsock
     {
         [DllImport(Interop.Libraries.Ws2_32, SetLastError = true)]
-        private static unsafe extern SocketError WSARecvFrom(
+        private static extern unsafe SocketError WSARecvFrom(
             SafeHandle socketHandle,
             WSABuffer* buffers,
             int bufferCount,
index 66f7b22..c748baf 100644 (file)
@@ -13,7 +13,7 @@ internal static partial class Interop
     internal static partial class Winsock
     {
         [DllImport(Interop.Libraries.Ws2_32, SetLastError = true)]
-        private static unsafe extern SocketError WSASendTo(
+        private static extern unsafe SocketError WSASendTo(
             SafeHandle socketHandle,
             WSABuffer* buffers,
             int bufferCount,
index 9cca4cc..e5e8cd2 100644 (file)
@@ -417,7 +417,7 @@ namespace System.Data.Common
             {
 #if DEBUG
                 bool compValue = s_connectionStringValidKeyRegex.IsMatch(keyname);
-                Debug.Assert(((0 < keyname.Length) && (';' != keyname[0]) && !Char.IsWhiteSpace(keyname[0]) && (-1 == keyname.IndexOf('\u0000'))) == compValue, "IsValueValid mismatch with regex");
+                Debug.Assert(((0 < keyname.Length) && (';' != keyname[0]) && !char.IsWhiteSpace(keyname[0]) && (-1 == keyname.IndexOf('\u0000'))) == compValue, "IsValueValid mismatch with regex");
 #endif
                 // string.Contains(char) is .NetCore2.1+ specific
                 return ((0 < keyname.Length) && (';' != keyname[0]) && !char.IsWhiteSpace(keyname[0]) && (-1 == keyname.IndexOf('\u0000')));
index 113557a..6f66629 100644 (file)
@@ -47,7 +47,7 @@ namespace System.Data.ProviderBase
             => throw ADP.ConnectionAlreadyOpen(State);
     }
 
-    sealed internal class DbConnectionClosedBusy : DbConnectionBusy
+    internal sealed class DbConnectionClosedBusy : DbConnectionBusy
     {
         // Closed Connection, Currently Busy - changing connection string
         internal static readonly DbConnectionInternal SingletonInstance = new DbConnectionClosedBusy();   // singleton object
@@ -57,7 +57,7 @@ namespace System.Data.ProviderBase
         }
     }
 
-    sealed internal class DbConnectionOpenBusy : DbConnectionBusy
+    internal sealed class DbConnectionOpenBusy : DbConnectionBusy
     {
         // Open Connection, Currently Busy - closing connection
         internal static readonly DbConnectionInternal SingletonInstance = new DbConnectionOpenBusy();   // singleton object
@@ -67,7 +67,7 @@ namespace System.Data.ProviderBase
         }
     }
 
-    sealed internal class DbConnectionClosedConnecting : DbConnectionBusy
+    internal sealed class DbConnectionClosedConnecting : DbConnectionBusy
     {
         // Closed Connection, Currently Connecting
 
@@ -111,7 +111,7 @@ namespace System.Data.ProviderBase
         }
     }
 
-    sealed internal class DbConnectionClosedNeverOpened : DbConnectionClosed
+    internal sealed class DbConnectionClosedNeverOpened : DbConnectionClosed
     {
         // Closed Connection, Has Never Been Opened
 
@@ -122,7 +122,7 @@ namespace System.Data.ProviderBase
         }
     }
 
-    sealed internal class DbConnectionClosedPreviouslyOpened : DbConnectionClosed
+    internal sealed class DbConnectionClosedPreviouslyOpened : DbConnectionClosed
     {
         // Closed Connection, Has Previously Been Opened
 
index f32c4d0..88716ce 100644 (file)
@@ -26,7 +26,7 @@ namespace System.Data.ProviderBase
     // and once no pools remain, change state from Active->Idle->Disabled
     // Once Disabled, factory can remove its reference to the pool entry
 
-    sealed internal class DbConnectionPoolGroup
+    internal sealed class DbConnectionPoolGroup
     {
         private readonly DbConnectionOptions _connectionOptions;
         private readonly DbConnectionPoolKey _poolKey;
@@ -187,8 +187,8 @@ namespace System.Data.ProviderBase
                                     // else pool entry has been disabled so don't create new pools
                                     Debug.Assert(PoolGroupStateDisabled == _state, "state should be disabled");
 
-                                    // don't need to call connectionFactory.QueuePoolForRelease(newPool) because               
-                                    // pool callbacks were delayed and no risk of connections being created            
+                                    // don't need to call connectionFactory.QueuePoolForRelease(newPool) because
+                                    // pool callbacks were delayed and no risk of connections being created
                                     newPool.Shutdown();
                                 }
                             }
index ce6b827..bdb69bf 100644 (file)
@@ -11,7 +11,7 @@ namespace System
         /// <summary>
         /// Returns a string from the given span, terminating the string at null if present.
         /// </summary>
-        internal unsafe static string GetStringFromFixedBuffer(this ReadOnlySpan<char> span)
+        internal static unsafe string GetStringFromFixedBuffer(this ReadOnlySpan<char> span)
         {
             fixed (char* c = &MemoryMarshal.GetReference(span))
             {
@@ -22,7 +22,7 @@ namespace System
         /// <summary>
         /// Gets the null-terminated string length of the given span.
         /// </summary>
-        internal unsafe static int GetFixedBufferStringLength(this ReadOnlySpan<char> span)
+        internal static unsafe int GetFixedBufferStringLength(this ReadOnlySpan<char> span)
         {
             int length = span.IndexOf('\0');
             return length < 0 ? span.Length : length;
@@ -32,7 +32,7 @@ namespace System
         /// Returns true if the given string equals the given span.
         /// The span's logical length is to the first null if present.
         /// </summary>
-        internal unsafe static bool FixedBufferEqualsString(this ReadOnlySpan<char> span, string value)
+        internal static unsafe bool FixedBufferEqualsString(this ReadOnlySpan<char> span, string value)
         {
             if (value == null || value.Length > span.Length)
                 return false;
index 10a8c56..7b80fc8 100644 (file)
@@ -14,7 +14,7 @@ namespace System
         // RFC 5952 Section 4.2.3
         // Longest consecutive sequence of zero segments, minimum 2.
         // On equal, first sequence wins. <-1, -1> for no compression.
-        internal unsafe static (int longestSequenceStart, int longestSequenceLength) FindCompressionRange(
+        internal static unsafe (int longestSequenceStart, int longestSequenceLength) FindCompressionRange(
             ReadOnlySpan<ushort> numbers)
         {
             int longestSequenceLength = 0, longestSequenceStart = -1, currentSequenceLength = 0;
@@ -43,7 +43,7 @@ namespace System
 
         // Returns true if the IPv6 address should be formatted with an embedded IPv4 address:
         // ::192.168.1.1
-        internal unsafe static bool ShouldHaveIpv4Embedded(ReadOnlySpan<ushort> numbers)
+        internal static unsafe bool ShouldHaveIpv4Embedded(ReadOnlySpan<ushort> numbers)
         {
             // 0:0 : 0:0 : x:x : x.x.x.x
             if (numbers[0] == 0 && numbers[1] == 0 && numbers[2] == 0 && numbers[3] == 0 && numbers[6] != 0)
@@ -96,7 +96,7 @@ namespace System
 
         //  Remarks: MUST NOT be used unless all input indexes are verified and trusted.
         //           start must be next to '[' position, or error is reported
-        internal unsafe static bool IsValidStrict(char* name, int start, ref int end)
+        internal static unsafe bool IsValidStrict(char* name, int start, ref int end)
         {
             int sequenceCount = 0;
             int sequenceLength = 0;
index 31b91bd..79480b9 100644 (file)
@@ -9,7 +9,7 @@ namespace System.Reflection
     {
         private string m_key;
         private string m_value;
-               
+
         public AssemblyMetadataAttribute(string key, string value) 
         {
             m_key = key;
@@ -20,10 +20,10 @@ namespace System.Reflection
         {
             get { return m_key; }
         }
-               
+
         public string Value
         {
             get { return m_value;}
         }
     }
-}
\ No newline at end of file
+}
index 56cdf0c..b3f9907 100644 (file)
@@ -33,7 +33,7 @@ namespace System
             }
         }
 
-        public unsafe static bool IsProcessElevated()
+        public static unsafe bool IsProcessElevated()
         {
             if (!RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
             {
index ca9a340..7106ee1 100644 (file)
@@ -8,7 +8,7 @@ namespace System.Net.Test.Common
 {
     public class TestLogging : ITestOutputHelper
     {
-        private readonly static TestLogging s_instance = new TestLogging();
+        private static readonly TestLogging s_instance = new TestLogging();
 
         private TestLogging()
         {
index b7f0e94..b0c71cf 100644 (file)
@@ -3,7 +3,7 @@
 // See the LICENSE file in the project root for more information.
 
 using System;
-using System.Diagnostics;              //Assert
+using System.Diagnostics;
 
 [assembly: System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverageAssembly]
 
index 9f4648c..92d702f 100644 (file)
@@ -3,7 +3,7 @@
 // See the LICENSE file in the project root for more information.
 
 using System;
-using System.Diagnostics;      //StackFrame
+using System.Diagnostics;
 using System.IO;
 using System.Text;
 
@@ -29,7 +29,7 @@ namespace OLEDB.Test.ModuleCore
         {
             set
             {
-                //Set the static Error interface...    
+                //Set the static Error interface...
                 s_rIError = value;
 
                 //Setup the standard c# Console to log to LTM instead...
@@ -343,12 +343,12 @@ namespace OLEDB.Test.ModuleCore
                 if (TestConsole != null)
                 {
                     //ITestConsole.Log
-                    TestConsole.Log(Common.Format(actual),                     //actual
-                                        Common.Format(expected),               //expected
-                                        source,                                                        //source
-                                        message,                                               //message
-                                        details,                                               //details
-                                        tagCONSOLEFLAGS.CONSOLE_TEXT,  //flags
+                    TestConsole.Log(Common.Format(actual),              //actual
+                                        Common.Format(expected),        //expected
+                                        source,                         //source
+                                        message,                        //message
+                                        details,                        //details
+                                        tagCONSOLEFLAGS.CONSOLE_TEXT,   //flags
                                         "fake_filename",
                                         999
                                     );
index d373bc4..ebe4197 100644 (file)
@@ -4,8 +4,8 @@
 
 using System;
 using System.IO;
-using System.Text;                     //Encoding
-using System.Diagnostics;      //TraceListener
+using System.Text;
+using System.Diagnostics;
 
 namespace OLEDB.Test.ModuleCore
 {
index 8e9a317..011784b 100644 (file)
@@ -3,7 +3,7 @@
 // See the LICENSE file in the project root for more information.
 
 using System;
-using System.Collections.Generic;              //StackTrace
+using System.Collections.Generic;
 using System.Diagnostics;
 
 namespace OLEDB.Test.ModuleCore
index 9b2d584..25fb281 100644 (file)
@@ -3,7 +3,7 @@
 // See the LICENSE file in the project root for more information.
 
 using System;
-using System.Diagnostics;              //Assert
+using System.Diagnostics;
 using System.IO;
 using System.Collections.Generic;
 
index ce9d817..6442681 100644 (file)
@@ -60,14 +60,14 @@ namespace OLEDB.Test.ModuleCore
         // These two methods get/set the ErrorLevel property. This property affects the
         // behavior of the 'Validate' method. The enum values have the following 
         // effects on that method:
-        //     HR_STRICT:      The 'hrActual' parameter MUST match the 'hrExpected' parameter,
-        //                             or else the error count in incremented.
-        //  HR_SUCCEED: The 'hrActual' MUST be a success code, or else the error count
-        //                             is incremented.
-        //     HR_FAIL:        The 'hrActual' MUST be an error code, or else the error count
-        //                             is incremented.
-        //     HR_OPTIONAL:The error count will not be incremented, regardless of the
-        //                             parameters passed in to 'Validate.'
+        //    HR_STRICT:  The 'hrActual' parameter MUST match the 'hrExpected' parameter,
+        //                or else the error count in incremented.
+        //  HR_SUCCEED:   The 'hrActual' MUST be a success code, or else the error count
+        //                is incremented.
+        //    HR_FAIL:    The 'hrActual' MUST be an error code, or else the error count
+        //                is incremented.
+        //    HR_OPTIONAL:The error count will not be incremented, regardless of the
+        //                parameters passed in to 'Validate.'
         // 
         tagERRORLEVEL GetErrorLevel();
         void SetErrorLevel(tagERRORLEVEL ErrorLevel);
@@ -175,19 +175,19 @@ namespace OLEDB.Test.ModuleCore
         // the provider they are running against (if any.)
         //
         // The properties are described as follows:
-        //     >Name:                  The name the provider gives itself. For Kagera this is MSDASQL.
-        //     >FriendlyName:  A special name the user has given this provider configuration.
-        //     >InitString:    A string which contains initialization data. The interpretation
-        //                                     of this string is Test Module-specific -- so you simply must
-        //                                     make users of LTM aware of what your particular Test Module
-        //                                     wants to see in this string.
-        //     >MachineName:   If you will be testing a remote provider, the user will pass
-        //                                     the machine name the provider is located on to you through
-        //                                     this property.
-        //     >CLSID:                 This is the CLSID of the provider you are to run against.
-        //     >CLSCTX:                This tells you whether the provider will be InProc, Local, or
-        //                                     Remote (values of this property are identical to the values
-        //                                     of the CLSCTX enumeration in wtypes.h)
+        //    >Name:          The name the provider gives itself. For Kagera this is MSDASQL.
+        //    >FriendlyName:  A special name the user has given this provider configuration.
+        //    >InitString:    A string which contains initialization data. The interpretation
+        //                    of this string is Test Module-specific -- so you simply must
+        //                    make users of LTM aware of what your particular Test Module
+        //                    wants to see in this string.
+        //    >MachineName:   If you will be testing a remote provider, the user will pass
+        //                    the machine name the provider is located on to you through
+        //                    this property.
+        //    >CLSID:         This is the CLSID of the provider you are to run against.
+        //    >CLSCTX:        This tells you whether the provider will be InProc, Local, or
+        //                    Remote (values of this property are identical to the values
+        //                    of the CLSCTX enumeration in wtypes.h)
         string GetName();
         void SetName(string bstrProviderName);
         string GetFriendlyName();
index 3150013..9d68c8a 100644 (file)
@@ -1181,7 +1181,7 @@ namespace XPathTests.FunctionalTests
         {
             var xml = "books.xml";
             var testExpression = @"
-          /bookstore/child             ::
+          /bookstore/child          ::
           book
         ";
             var expected = new XPathResult(0,
index 7d22604..6380899 100644 (file)
@@ -12,8 +12,8 @@ using OLEDB.Test.ModuleCore;
 /// This class is used to write out XML tokens. This tool can write 
 /// well-formed as well as non well-formed file. This writer does not 
 /// guarantee well-formedness. It does not implement XmlWriter.
-///    The class can write tokens by explicit API calls as well as parse
-///    a pattern string to generate these tokens.
+/// The class can write tokens by explicit API calls as well as parse
+/// a pattern string to generate these tokens.
 /// </summary>
 namespace XmlCoreTest.Common
 {
@@ -263,7 +263,7 @@ namespace XmlCoreTest.Common
 
         /// Writing text.
         /// Note : This is basically equivalent to WriteRaw and the string may contain any number of embedded tags.
-        ///                    No checking is performed on them either.
+        ///        No checking is performed on them either.
         public void PutText(string myStr)
         {
             _q.Append(myStr);
@@ -328,23 +328,23 @@ namespace XmlCoreTest.Common
 
         /// <summary>
         /// This method is a convenience method and a shortcut to create an XML string. Each character in the pattern
-        ///    maps to a particular Put/Open function and calls it for you. For e.g. XEAA/ will call PutDecl, OpenElement, 
-        ///    PutAttribute, PutAttribute and CloseElement for you.
-        ///    The following is the list of all allowed characters and their function mappings :
+        /// maps to a particular Put/Open function and calls it for you. For e.g. XEAA/ will call PutDecl, OpenElement, 
+        /// PutAttribute, PutAttribute and CloseElement for you.
+        /// The following is the list of all allowed characters and their function mappings :
         ///
-        ///'X' :       PutDecl()
-        ///'E' :       OpenElement()
-        ///'M' :       CloseEmptyElement()
-        ///'/' :       CloseElement()
-        ///'e' :       PutEndElement()
-        ///'A' :       PutAttribute()
-        ///'P' :       PutPI()
-        ///'T' :       PutText()
-        ///'C' :       PutComment()
-        ///'R' :       PutRoot()
-        ///'r' :       PutEndRoot()
-        ///'B' :       PutEndRoot()
-        ///'W' :       PutWhiteSpace()
+        ///'X' :    PutDecl()
+        ///'E' :    OpenElement()
+        ///'M' :    CloseEmptyElement()
+        ///'/' :    CloseElement()
+        ///'e' :    PutEndElement()
+        ///'A' :    PutAttribute()
+        ///'P' :    PutPI()
+        ///'T' :    PutText()
+        ///'C' :    PutComment()
+        ///'R' :    PutRoot()
+        ///'r' :    PutEndRoot()
+        ///'B' :    PutEndRoot()
+        ///'W' :    PutWhiteSpace()
         ///
         /// </summary>
         /// <param name="pattern">String containing the pattern which you want to use to create
index f296a58..b351344 100644 (file)
@@ -3,10 +3,10 @@
 // See the LICENSE file in the project root for more information.
 
 /// This class is primarily used to test buffer boundary integrity of readers.
-///    This class constructs a memory stream from the given buffer boundary length such that
-///    the required tag completely lies exactly on the start and end of buffer boundary.
+/// This class constructs a memory stream from the given buffer boundary length such that
+/// the required tag completely lies exactly on the start and end of buffer boundary.
 /// The class makes up the additional bytes by filling in whitespace if so.
-///    The first buffer length consists of the XML Decl and the Root Start (done by PrepareStream() )
+/// The first buffer length consists of the XML Decl and the Root Start (done by PrepareStream() )
 /// The next buffer length consists of the actual start and end text with the variable content stretched
 /// out to end at the buffer boundary.
 ///
@@ -22,9 +22,9 @@ namespace XmlCoreTest.Common
 
 
     /// <summary>
-    ///  This class contains helper methods for Readers.
-    ///         ConvertToBinaryStream : Converts the given xml string to the binary equivalent of the string and returns it
-    ///                using a memory stream.
+    /// This class contains helper methods for Readers.
+    /// ConvertToBinaryStream : Converts the given xml string to the binary equivalent of the string and returns it
+    /// using a memory stream.
     /// Common usage pattern would be something like :
     /// XmlReader.Create( new MemoryStream(ReaderHelper.ConvertToBinaryStream("<elem>abc</elem>", true, false)), "baseUri", readerSettings );
     /// </summary>
index 01cff9b..9886adb 100644 (file)
@@ -3,10 +3,10 @@
 // See the LICENSE file in the project root for more information.
 
 /// This class is primarily used to test buffer boundary integrity of readers.
-///    This class constructs a memory stream from the given buffer boundary length such that
-///    the required tag completely lies exactly on the start and end of buffer boundary.
+/// This class constructs a memory stream from the given buffer boundary length such that
+/// the required tag completely lies exactly on the start and end of buffer boundary.
 /// The class makes up the additional bytes by filling in whitespace if so.
-///    The first buffer length consists of the XML Decl and the Root Start (done by PrepareStream() )
+/// The first buffer length consists of the XML Decl and the Root Start (done by PrepareStream() )
 /// The next buffer length consists of the actual start and end text with the variable content stretched
 /// out to end at the buffer boundary.
 ///
@@ -43,9 +43,9 @@ namespace XmlCoreTest.Common
     }
 
     /// <summary>
-    ///  This class contains helper methods for Readers.
-    ///         ConvertToBinaryStream : Converts the given xml string to the binary equivalent of the string and returns it
-    ///                using a memory stream.
+    /// This class contains helper methods for Readers.
+    /// ConvertToBinaryStream : Converts the given xml string to the binary equivalent of the string and returns it
+    /// using a memory stream.
     /// Common usage pattern would be something like :
     /// XmlReader.Create( new MemoryStream(ReaderHelper.ConvertToBinaryStream("<elem>abc</elem>", true, false)), "baseUri", readerSettings );
     /// </summary>
index abbad0f..df333a5 100644 (file)
@@ -27,10 +27,10 @@ namespace XmlCoreTest.Common
         Async = 1024,
         NoAsync = 2048,
 
-        UTF8Writer = 1,                  // V2 writer with Encoding.UTF8
+        UTF8Writer = 1,           // V2 writer with Encoding.UTF8
         UnicodeWriter = 2,        // V2 writer with Encoding.Unicode
         CustomWriter = 4,         // CustomWriter implemented in this same folder
-        CharCheckingWriter = 8,          // CharCheckingWriter implemented in this same folder
+        CharCheckingWriter = 8,   // CharCheckingWriter implemented in this same folder
         UTF8WriterIndent = 16,    // UTF8WriterIndent implemented in this same folder
         UnicodeWriterIndent = 32, // UnicodeWriterIndent implemented in this same folder
         WrappedWriter = 64        // WrappedWriter implemented in this same folder
index 3248733..31986db 100644 (file)
@@ -248,7 +248,7 @@ namespace System.Xml.XmlDiff
             {
                 XmlDiffAttribute current1 = elem1.FirstAttribute;
                 XmlDiffAttribute current2 = elem2.FirstAttribute;
-                //                     NodePosition result = 0;
+                // NodePosition result = 0;
                 int nCompare = 0;
                 while (current1 != null && current2 != null && nCompare == 0)
                 {
index 6fb35f2..9ef03cb 100644 (file)
@@ -809,7 +809,7 @@ namespace System.Tests
             Assert.Equal(0, string.Compare(emptyValue, s, StringComparison.OrdinalIgnoreCase));
             
             ReadOnlySpan<char> span = value.AsSpan();
-            ReadOnlySpan<char> emptySlice = value.AsSpan(2, 0);           
+            ReadOnlySpan<char> emptySlice = value.AsSpan(2, 0);
             Assert.True(0 < span.CompareTo(emptySlice, StringComparison.Ordinal));
 
             Assert.True(0 < span.CompareTo(emptySlice, StringComparison.CurrentCulture));
@@ -818,7 +818,7 @@ namespace System.Tests
             Assert.True(0 < span.CompareTo(emptySlice, StringComparison.InvariantCultureIgnoreCase));
             Assert.True(0 < span.CompareTo(emptySlice, StringComparison.OrdinalIgnoreCase));
 
-            span = value.AsSpan(1, 0);            
+            span = value.AsSpan(1, 0);
             Assert.Equal(0, span.CompareTo(emptySlice, StringComparison.Ordinal));
 
             Assert.Equal(0, span.CompareTo(emptySlice, StringComparison.CurrentCulture));
@@ -892,7 +892,7 @@ namespace System.Tests
             Assert.Equal(0, string.Compare(s1, s2, StringComparison.OrdinalIgnoreCase));
             
             ReadOnlySpan<char> span = value.AsSpan(1, 3);
-            ReadOnlySpan<char> slice = value.AsSpan(3, 3);            
+            ReadOnlySpan<char> slice = value.AsSpan(3, 3);
             Assert.Equal(0, span.CompareTo(slice, StringComparison.Ordinal));
 
             Assert.Equal(0, span.CompareTo(slice, StringComparison.CurrentCulture));
@@ -920,7 +920,7 @@ namespace System.Tests
             Assert.Equal(0, string.Compare(s1, s2, StringComparison.OrdinalIgnoreCase));
             
             ReadOnlySpan<char> span = sa.AsSpan(0, 3);
-            ReadOnlySpan<char> slice = sb.AsSpan(0, 3);            
+            ReadOnlySpan<char> slice = sb.AsSpan(0, 3);
             Assert.Equal(0, span.CompareTo(slice, StringComparison.Ordinal));
 
             Assert.Equal(0, span.CompareTo(slice, StringComparison.CurrentCulture));
@@ -1164,7 +1164,7 @@ namespace System.Tests
 
         [Fact]
         public static void SameSpanContains_StringComparison()
-        {            
+        {
             string s1 = "456";
             Assert.True(s1.Contains(s1));
             
@@ -1312,7 +1312,7 @@ namespace System.Tests
 
         [Fact]
         public static void ContainsUnknownComparisonType_StringComparison()
-        {                        
+        {
             ReadOnlySpan<char> span = "456".AsSpan();
             SpanTestHelpers.AssertThrows<ArgumentException, char>(span, (_span) => _span.Contains(_span, StringComparison.CurrentCulture - 1));
             SpanTestHelpers.AssertThrows<ArgumentException, char>(span, (_span) => _span.Contains(_span, StringComparison.OrdinalIgnoreCase + 1));
@@ -1354,7 +1354,7 @@ namespace System.Tests
             int result = s1.CompareTo(s1);
             Assert.Equal(0, result);
 
-            ReadOnlySpan<char> first = s1.AsSpan(0, 3);            
+            ReadOnlySpan<char> first = s1.AsSpan(0, 3);
             result = first.SequenceCompareTo<char>(s1.AsSpan());
             Assert.Equal(0, result);
         }
@@ -1414,7 +1414,7 @@ namespace System.Tests
             Assert.True(result > 0);
         }
 
-        [Fact]        
+        [Fact]
         public static void SequenceCompareToWithSingleMismatch_Char()
         {
             for (int length = 1; length < 32; length++)
@@ -1432,7 +1432,7 @@ namespace System.Tests
 
                     string s1 = new string(first);
                     string s2 = new string(second);
-                    int result = string.Compare(s1, s2, StringComparison.Ordinal);                    
+                    int result = string.Compare(s1, s2, StringComparison.Ordinal);
                     Assert.True(result < 0);
 
                     result = string.Compare(s2, s1, StringComparison.Ordinal);
@@ -1449,7 +1449,7 @@ namespace System.Tests
             }
         }
 
-        [Fact]        
+        [Fact]
         public static void SequenceCompareToNoMatch_Char()
         {
             for (int length = 1; length < 32; length++)
@@ -1783,7 +1783,7 @@ namespace System.Tests
 
         [Fact]
         public static void SameSpanEndsWith_Char()
-        {            
+        {
             string s = "456";
             bool b = s.EndsWith(s);
             Assert.True(b);
@@ -1814,7 +1814,7 @@ namespace System.Tests
         {
             string value = "456";
 
-            string s1 = value.Substring(0, 3);            
+            string s1 = value.Substring(0, 3);
             string s2 = value.Substring(1, 2);
             bool b = s1.EndsWith(s2);
             Assert.True(b);
@@ -2008,7 +2008,7 @@ namespace System.Tests
             Assert.True(s1.EndsWith(s2, StringComparison.InvariantCultureIgnoreCase));
             Assert.True(s1.EndsWith(s2, StringComparison.OrdinalIgnoreCase));
 
-            ReadOnlySpan<char> span = value.AsSpan(0, 3);            
+            ReadOnlySpan<char> span = value.AsSpan(0, 3);
             ReadOnlySpan<char> slice = value.AsSpan(1 ,2);
             Assert.True(span.EndsWith(slice, StringComparison.Ordinal));
 
@@ -4716,252 +4716,252 @@ namespace System.Tests
             AssertExtensions.Throws<ArgumentException>("comparisonType", () => s.StartsWith("H", StringComparison.OrdinalIgnoreCase + 1));
         }
 
-        [Fact] 
-        public static void ZeroLengthStartsWith_Char() 
-        {      
-            var a = new char[3];       
-       
-            string s1 = new string(a); 
-            string s2 = new string(a, 2, 0);   
-            bool b = s1.StartsWith(s2);        
-            Assert.True(b);    
-       
+        [Fact]
+        public static void ZeroLengthStartsWith_Char()
+        {
+            var a = new char[3];
+
+            string s1 = new string(a);
+            string s2 = new string(a, 2, 0);
+            bool b = s1.StartsWith(s2);
+            Assert.True(b);
+
             ReadOnlySpan<char> span = s1.AsSpan();
-            ReadOnlySpan<char> slice = s2.AsSpan();    
-            b = span.StartsWith<char>(slice);  
-            Assert.True(b);    
-        }      
-       
-        [Fact] 
-        public static void SameSpanStartsWith_Char()   
-        {      
-            string s1 = "456"; 
-            bool b = s1.StartsWith(s1);        
+            ReadOnlySpan<char> slice = s2.AsSpan();
+            b = span.StartsWith<char>(slice);
+            Assert.True(b);
+        }
+    
+        [Fact]
+        public static void SameSpanStartsWith_Char()    
+        {
+            string s1 = "456";
+            bool b = s1.StartsWith(s1);
             Assert.True(b);
 
-            ReadOnlySpan<char> span = s1.AsSpan();     
-            b = span.StartsWith<char>(span);   
-            Assert.True(b);    
-        }      
-       
-        [Fact] 
-        public static void LengthMismatchStartsWith_Char()     
-        {      
-            char[] a = { '4', '5', '6' };      
-       
-            string s1 = new string(a, 0, 2);   
-            string s2 = new string(a, 0, 3);   
-            bool b = s1.StartsWith(s2);        
+            ReadOnlySpan<char> span = s1.AsSpan();
+            b = span.StartsWith<char>(span);
+            Assert.True(b);
+        }
+
+        [Fact]
+        public static void LengthMismatchStartsWith_Char()
+        {
+            char[] a = { '4', '5', '6' };
+
+            string s1 = new string(a, 0, 2);
+            string s2 = new string(a, 0, 3);
+            bool b = s1.StartsWith(s2);
             Assert.False(b);
 
             ReadOnlySpan<char> span = s1.AsSpan();
-            ReadOnlySpan<char> slice = s2.AsSpan();    
-            b = span.StartsWith<char>(slice);  
-            Assert.False(b);   
-        }      
-       
-        [Fact] 
-        public static void StartsWithMatch_Char()      
-        {      
-            char[] a = { '4', '5', '6' };      
-       
-            string s1 = new string(a, 0, 3);   
-            string s2 = new string(a, 0, 2);   
-            bool b = s1.StartsWith(s2);        
-            Assert.True(b);    
-       
-            var span = new ReadOnlySpan<char>(a, 0, 3);        
-            var slice = new ReadOnlySpan<char>(a, 0, 2);       
-            b = span.StartsWith<char>(slice);  
-            Assert.True(b);    
-        }      
-       
-        [Fact] 
-        public static void StartsWithMatchDifferentSpans_Char()        
-        {      
-            char[] a = { '4', '5', '6' };      
-            char[] b = { '4', '5', '6' };      
-       
-            string s1 = "456"; 
-            string s2 = "456"; 
-            bool c = s1.StartsWith(s2);        
+            ReadOnlySpan<char> slice = s2.AsSpan();
+            b = span.StartsWith<char>(slice);
+            Assert.False(b);
+        }
+
+        [Fact]
+        public static void StartsWithMatch_Char()
+        {
+            char[] a = { '4', '5', '6' };
+
+            string s1 = new string(a, 0, 3);
+            string s2 = new string(a, 0, 2);
+            bool b = s1.StartsWith(s2);
+            Assert.True(b);
+
+            var span = new ReadOnlySpan<char>(a, 0, 3);
+            var slice = new ReadOnlySpan<char>(a, 0, 2);
+            b = span.StartsWith<char>(slice);
+            Assert.True(b);
+        }
+
+        [Fact]
+        public static void StartsWithMatchDifferentSpans_Char()
+        {
+            char[] a = { '4', '5', '6' };
+            char[] b = { '4', '5', '6' };
+
+            string s1 = "456";
+            string s2 = "456";
+            bool c = s1.StartsWith(s2);
             Assert.True(c);
 
             ReadOnlySpan<char> span = s1.AsSpan();
-            ReadOnlySpan<char> slice = s2.AsSpan();    
-            c = span.StartsWith<char>(slice);  
-            Assert.True(c);    
-        }      
-       
-        [Fact] 
-        public static void StartsWithNoMatch_Char()    
-        {      
-            for (int length = 1; length < 32; length++)        
-            {  
-                for (int mismatchIndex = 0; mismatchIndex < length; mismatchIndex++)   
-                {      
-                    var first = new char[length];      
-                    var second = new char[length];     
-                    for (int i = 0; i < length; i++)   
-                    {  
-                        first[i] = second[i] = (char)(i + 1);  
-                    }  
-       
-                    second[mismatchIndex] = (char)(second[mismatchIndex] + 1); 
-       
-                    string s1 = new string(first);     
-                    string s2 = new string(second);    
-                    bool b = s1.StartsWith(s2, StringComparison.Ordinal);      
-                    Assert.False(b);   
-       
-                    var firstSpan = s1.AsSpan();       
-                    var secondSpan = s2.AsSpan();      
-                    b = firstSpan.StartsWith<char>(secondSpan);        
-                    Assert.False(b);   
-                }      
-            }  
-        }      
-       
-        [Fact] 
-        public static void MakeSureNoStartsWithChecksGoOutOfRange_Char()       
-        {      
-            for (int length = 0; length < 100; length++)       
-            {  
-                var first = new char[length + 2];      
-                first[0] = '9';        
-                first[length + 1] = '9';       
-                var second = new char[length + 2];     
-                second[0] = 'a';       
-                second[length + 1] = 'a';      
-       
-                string s1 = new string(first, 1, length);      
-                string s2 = new string(second, 1, length);     
-                bool b = s1.StartsWith(s2);    
+            ReadOnlySpan<char> slice = s2.AsSpan();
+            c = span.StartsWith<char>(slice);
+            Assert.True(c);
+        }
+
+        [Fact]
+        public static void StartsWithNoMatch_Char()
+        {
+            for (int length = 1; length < 32; length++)
+            {
+                for (int mismatchIndex = 0; mismatchIndex < length; mismatchIndex++)
+                {
+                    var first = new char[length];
+                    var second = new char[length];
+                    for (int i = 0; i < length; i++)
+                    {
+                        first[i] = second[i] = (char)(i + 1);
+                    }
+
+                    second[mismatchIndex] = (char)(second[mismatchIndex] + 1);
+
+                    string s1 = new string(first);
+                    string s2 = new string(second);
+                    bool b = s1.StartsWith(s2, StringComparison.Ordinal);
+                    Assert.False(b);
+
+                    var firstSpan = s1.AsSpan();
+                    var secondSpan = s2.AsSpan();
+                    b = firstSpan.StartsWith<char>(secondSpan);
+                    Assert.False(b);
+                }
+            }
+        }
+
+        [Fact]
+        public static void MakeSureNoStartsWithChecksGoOutOfRange_Char()
+        {
+            for (int length = 0; length < 100; length++)
+            {
+                var first = new char[length + 2];
+                first[0] = '9';
+                first[length + 1] = '9';
+                var second = new char[length + 2];
+                second[0] = 'a';
+                second[length + 1] = 'a';
+
+                string s1 = new string(first, 1, length);
+                string s2 = new string(second, 1, length);
+                bool b = s1.StartsWith(s2);
                 Assert.True(b);
 
                 ReadOnlySpan<char> span1 = s1.AsSpan();
-                ReadOnlySpan<char> span2 = s2.AsSpan();        
-                b = span1.StartsWith<char>(span2);     
-                Assert.True(b);        
-            }  
-        }      
-       
-        [Fact] 
-        public static void ZeroLengthStartsWith_StringComparison()     
-        {      
-            var a = new char[3];       
-       
-            string s1 = new string(a); 
-            string s2 = new string(a, 2, 0);   
-            Assert.True(s1.StartsWith(s2, StringComparison.Ordinal));  
-       
-            Assert.True(s1.StartsWith(s2, StringComparison.CurrentCulture));   
-            Assert.True(s1.StartsWith(s2, StringComparison.CurrentCultureIgnoreCase)); 
-            Assert.True(s1.StartsWith(s2, StringComparison.InvariantCulture)); 
-            Assert.True(s1.StartsWith(s2, StringComparison.InvariantCultureIgnoreCase));       
-            Assert.True(s1.StartsWith(s2, StringComparison.OrdinalIgnoreCase));        
-       
-            s1 = string.Empty; 
-            Assert.True(s1.StartsWith(s2, StringComparison.Ordinal));  
-       
-            Assert.True(s1.StartsWith(s2, StringComparison.CurrentCulture));   
-            Assert.True(s1.StartsWith(s2, StringComparison.CurrentCultureIgnoreCase)); 
-            Assert.True(s1.StartsWith(s2, StringComparison.InvariantCulture)); 
-            Assert.True(s1.StartsWith(s2, StringComparison.InvariantCultureIgnoreCase));       
+                ReadOnlySpan<char> span2 = s2.AsSpan();
+                b = span1.StartsWith<char>(span2);
+                Assert.True(b);
+            }
+        }
+    
+        [Fact]
+        public static void ZeroLengthStartsWith_StringComparison()
+        {
+            var a = new char[3];
+    
+            string s1 = new string(a);
+            string s2 = new string(a, 2, 0);
+            Assert.True(s1.StartsWith(s2, StringComparison.Ordinal));
+
+            Assert.True(s1.StartsWith(s2, StringComparison.CurrentCulture));
+            Assert.True(s1.StartsWith(s2, StringComparison.CurrentCultureIgnoreCase));
+            Assert.True(s1.StartsWith(s2, StringComparison.InvariantCulture));
+            Assert.True(s1.StartsWith(s2, StringComparison.InvariantCultureIgnoreCase));
+            Assert.True(s1.StartsWith(s2, StringComparison.OrdinalIgnoreCase));
+
+            s1 = string.Empty;
+            Assert.True(s1.StartsWith(s2, StringComparison.Ordinal));
+    
+            Assert.True(s1.StartsWith(s2, StringComparison.CurrentCulture));
+            Assert.True(s1.StartsWith(s2, StringComparison.CurrentCultureIgnoreCase));
+            Assert.True(s1.StartsWith(s2, StringComparison.InvariantCulture));
+            Assert.True(s1.StartsWith(s2, StringComparison.InvariantCultureIgnoreCase));
             Assert.True(s1.StartsWith(s2, StringComparison.OrdinalIgnoreCase));
 
             ReadOnlySpan<char> span = s1.AsSpan();
-            ReadOnlySpan<char> slice = s2.AsSpan();    
-            Assert.True(span.StartsWith(slice, StringComparison.Ordinal));     
-       
-            Assert.True(span.StartsWith(slice, StringComparison.CurrentCulture));      
-            Assert.True(span.StartsWith(slice, StringComparison.CurrentCultureIgnoreCase));    
-            Assert.True(span.StartsWith(slice, StringComparison.InvariantCulture));    
-            Assert.True(span.StartsWith(slice, StringComparison.InvariantCultureIgnoreCase));  
-            Assert.True(span.StartsWith(slice, StringComparison.OrdinalIgnoreCase));   
-       
-            span = ReadOnlySpan<char>.Empty;   
-            Assert.True(span.StartsWith(slice, StringComparison.Ordinal));     
-       
-            Assert.True(span.StartsWith(slice, StringComparison.CurrentCulture));      
-            Assert.True(span.StartsWith(slice, StringComparison.CurrentCultureIgnoreCase));    
-            Assert.True(span.StartsWith(slice, StringComparison.InvariantCulture));    
-            Assert.True(span.StartsWith(slice, StringComparison.InvariantCultureIgnoreCase));  
-            Assert.True(span.StartsWith(slice, StringComparison.OrdinalIgnoreCase));   
-        }      
-       
-        [Fact] 
-        public static void SameSpanStartsWith_StringComparison()       
-        {      
-            string s1 = "456"; 
-            Assert.True(s1.StartsWith(s1, StringComparison.Ordinal));  
-       
-            Assert.True(s1.StartsWith(s1, StringComparison.CurrentCulture));   
-            Assert.True(s1.StartsWith(s1, StringComparison.CurrentCultureIgnoreCase)); 
-            Assert.True(s1.StartsWith(s1, StringComparison.InvariantCulture)); 
-            Assert.True(s1.StartsWith(s1, StringComparison.InvariantCultureIgnoreCase));       
+            ReadOnlySpan<char> slice = s2.AsSpan();
+            Assert.True(span.StartsWith(slice, StringComparison.Ordinal));
+    
+            Assert.True(span.StartsWith(slice, StringComparison.CurrentCulture));
+            Assert.True(span.StartsWith(slice, StringComparison.CurrentCultureIgnoreCase));
+            Assert.True(span.StartsWith(slice, StringComparison.InvariantCulture));
+            Assert.True(span.StartsWith(slice, StringComparison.InvariantCultureIgnoreCase));
+            Assert.True(span.StartsWith(slice, StringComparison.OrdinalIgnoreCase));
+
+            span = ReadOnlySpan<char>.Empty;
+            Assert.True(span.StartsWith(slice, StringComparison.Ordinal));
+
+            Assert.True(span.StartsWith(slice, StringComparison.CurrentCulture));
+            Assert.True(span.StartsWith(slice, StringComparison.CurrentCultureIgnoreCase));
+            Assert.True(span.StartsWith(slice, StringComparison.InvariantCulture));
+            Assert.True(span.StartsWith(slice, StringComparison.InvariantCultureIgnoreCase));
+            Assert.True(span.StartsWith(slice, StringComparison.OrdinalIgnoreCase));
+        }
+
+        [Fact]
+        public static void SameSpanStartsWith_StringComparison()
+        {
+            string s1 = "456";
+            Assert.True(s1.StartsWith(s1, StringComparison.Ordinal));
+    
+            Assert.True(s1.StartsWith(s1, StringComparison.CurrentCulture));
+            Assert.True(s1.StartsWith(s1, StringComparison.CurrentCultureIgnoreCase));
+            Assert.True(s1.StartsWith(s1, StringComparison.InvariantCulture));
+            Assert.True(s1.StartsWith(s1, StringComparison.InvariantCultureIgnoreCase));
             Assert.True(s1.StartsWith(s1, StringComparison.OrdinalIgnoreCase));
 
-            ReadOnlySpan<char> span = s1.AsSpan();     
-            Assert.True(span.StartsWith(span, StringComparison.Ordinal));      
-       
-            Assert.True(span.StartsWith(span, StringComparison.CurrentCulture));       
-            Assert.True(span.StartsWith(span, StringComparison.CurrentCultureIgnoreCase));     
-            Assert.True(span.StartsWith(span, StringComparison.InvariantCulture));     
-            Assert.True(span.StartsWith(span, StringComparison.InvariantCultureIgnoreCase));   
-            Assert.True(span.StartsWith(span, StringComparison.OrdinalIgnoreCase));    
-        }      
-       
-        [Fact] 
-        public static void LengthMismatchStartsWith_StringComparison() 
-        {      
-            string value = "456";      
-       
-            string s1 = value.Substring(0, 2); 
-            string s2 = value.Substring(0, 3); 
-            Assert.False(s1.StartsWith(s2, StringComparison.Ordinal)); 
-       
-            Assert.False(s1.StartsWith(s2, StringComparison.CurrentCulture));  
-            Assert.False(s1.StartsWith(s2, StringComparison.CurrentCultureIgnoreCase));        
-            Assert.False(s1.StartsWith(s2, StringComparison.InvariantCulture));        
-            Assert.False(s1.StartsWith(s2, StringComparison.InvariantCultureIgnoreCase));      
+            ReadOnlySpan<char> span = s1.AsSpan();
+            Assert.True(span.StartsWith(span, StringComparison.Ordinal));
+    
+            Assert.True(span.StartsWith(span, StringComparison.CurrentCulture));
+            Assert.True(span.StartsWith(span, StringComparison.CurrentCultureIgnoreCase));
+            Assert.True(span.StartsWith(span, StringComparison.InvariantCulture));
+            Assert.True(span.StartsWith(span, StringComparison.InvariantCultureIgnoreCase));
+            Assert.True(span.StartsWith(span, StringComparison.OrdinalIgnoreCase));
+        }
+    
+        [Fact]
+        public static void LengthMismatchStartsWith_StringComparison()
+        {
+            string value = "456";
+    
+            string s1 = value.Substring(0, 2);
+            string s2 = value.Substring(0, 3);
+            Assert.False(s1.StartsWith(s2, StringComparison.Ordinal));
+    
+            Assert.False(s1.StartsWith(s2, StringComparison.CurrentCulture));
+            Assert.False(s1.StartsWith(s2, StringComparison.CurrentCultureIgnoreCase));
+            Assert.False(s1.StartsWith(s2, StringComparison.InvariantCulture));
+            Assert.False(s1.StartsWith(s2, StringComparison.InvariantCultureIgnoreCase));
             Assert.False(s1.StartsWith(s2, StringComparison.OrdinalIgnoreCase));
 
             ReadOnlySpan<char> span = s1.AsSpan();
-            ReadOnlySpan<char> slice = s2.AsSpan();    
-            Assert.False(span.StartsWith(slice, StringComparison.Ordinal));    
-       
-            Assert.False(span.StartsWith(slice, StringComparison.CurrentCulture));     
-            Assert.False(span.StartsWith(slice, StringComparison.CurrentCultureIgnoreCase));   
-            Assert.False(span.StartsWith(slice, StringComparison.InvariantCulture));   
-            Assert.False(span.StartsWith(slice, StringComparison.InvariantCultureIgnoreCase)); 
-            Assert.False(span.StartsWith(slice, StringComparison.OrdinalIgnoreCase));  
-        }      
-       
-        [Fact] 
-        public static void StartsWithMatch_StringComparison()  
-        {      
-            string value = "456";      
-       
-            string s1 = value.Substring(0, 3); 
-            string s2 = value.Substring(0, 2); 
-            Assert.True(s1.StartsWith(s2, StringComparison.Ordinal));  
-       
-            Assert.True(s1.StartsWith(s2, StringComparison.CurrentCulture));   
-            Assert.True(s1.StartsWith(s2, StringComparison.CurrentCultureIgnoreCase)); 
-            Assert.True(s1.StartsWith(s2, StringComparison.InvariantCulture)); 
-            Assert.True(s1.StartsWith(s2, StringComparison.InvariantCultureIgnoreCase));       
+            ReadOnlySpan<char> slice = s2.AsSpan();
+            Assert.False(span.StartsWith(slice, StringComparison.Ordinal));
+    
+            Assert.False(span.StartsWith(slice, StringComparison.CurrentCulture));
+            Assert.False(span.StartsWith(slice, StringComparison.CurrentCultureIgnoreCase));
+            Assert.False(span.StartsWith(slice, StringComparison.InvariantCulture));
+            Assert.False(span.StartsWith(slice, StringComparison.InvariantCultureIgnoreCase));
+            Assert.False(span.StartsWith(slice, StringComparison.OrdinalIgnoreCase));
+        }
+    
+        [Fact]
+        public static void StartsWithMatch_StringComparison()    
+        {
+            string value = "456";
+    
+            string s1 = value.Substring(0, 3);
+            string s2 = value.Substring(0, 2);
+            Assert.True(s1.StartsWith(s2, StringComparison.Ordinal));
+    
+            Assert.True(s1.StartsWith(s2, StringComparison.CurrentCulture));
+            Assert.True(s1.StartsWith(s2, StringComparison.CurrentCultureIgnoreCase));
+            Assert.True(s1.StartsWith(s2, StringComparison.InvariantCulture));
+            Assert.True(s1.StartsWith(s2, StringComparison.InvariantCultureIgnoreCase));
             Assert.True(s1.StartsWith(s2, StringComparison.OrdinalIgnoreCase));
 
             ReadOnlySpan<char> span = s1.AsSpan();
-            ReadOnlySpan<char> slice = s2.AsSpan();    
-            Assert.True(span.StartsWith(slice, StringComparison.Ordinal));     
-       
-            Assert.True(span.StartsWith(slice, StringComparison.CurrentCulture));      
-            Assert.True(span.StartsWith(slice, StringComparison.CurrentCultureIgnoreCase));    
-            Assert.True(span.StartsWith(slice, StringComparison.InvariantCulture));    
-            Assert.True(span.StartsWith(slice, StringComparison.InvariantCultureIgnoreCase));  
-            Assert.True(span.StartsWith(slice, StringComparison.OrdinalIgnoreCase));   
+            ReadOnlySpan<char> slice = s2.AsSpan();
+            Assert.True(span.StartsWith(slice, StringComparison.Ordinal));
+    
+            Assert.True(span.StartsWith(slice, StringComparison.CurrentCulture));
+            Assert.True(span.StartsWith(slice, StringComparison.CurrentCultureIgnoreCase));
+            Assert.True(span.StartsWith(slice, StringComparison.InvariantCulture));
+            Assert.True(span.StartsWith(slice, StringComparison.InvariantCultureIgnoreCase));
+            Assert.True(span.StartsWith(slice, StringComparison.OrdinalIgnoreCase));
         }
 
         [Theory]
@@ -5116,19 +5116,19 @@ namespace System.Tests
         {
             char[] expectedSource = { 'a', 'B', 'c' };
             char[] a = { 'a', 'B', 'c' };
-            var expectedDestination = new char[1] { 'a' };            
+            var expectedDestination = new char[1] { 'a' };
             Span<char> destination = new char[1] { 'a' };
 
             string emptyString = new string(a, 2, 0);
             Assert.Equal("", emptyString.ToLowerInvariant());
 
-            ReadOnlySpan<char> source = emptyString.AsSpan();                       
+            ReadOnlySpan<char> source = emptyString.AsSpan();
             Assert.Equal(source.Length, source.ToLower(destination, CultureInfo.CurrentCulture));
             Assert.Equal(source.Length, source.ToLowerInvariant(destination));
             Assert.Equal(expectedDestination, destination.ToArray());
             Assert.Equal(expectedSource, a);
 
-            emptyString = string.Empty;            
+            emptyString = string.Empty;
             Assert.Equal("", emptyString.ToLowerInvariant()); 
          
             source = emptyString.AsSpan();
@@ -5171,7 +5171,7 @@ namespace System.Tests
         {
             var expectedDestination = new char[3] { 'b', 'c', 'b' };
 
-            {                
+            {
                 char[] a = { 'a', 'B', 'c', 'B', 'c', 'B' };
 
                 string s1 = new string(a, 1, 3);
@@ -5207,7 +5207,7 @@ namespace System.Tests
             {
                 var expectedSource = new char[3] { 'a', 'B', 'c' };
                                 
-                string s1 = "aBc";                
+                string s1 = "aBc";
                 var expectedDestinationString = "abc";
                 Assert.Equal(expectedDestinationString, s1.ToLowerInvariant());
 
@@ -5329,19 +5329,19 @@ namespace System.Tests
         {
             char[] expectedSource = { 'a', 'B', 'c' };
             char[] a = { 'a', 'B', 'c' };
-            var expectedDestination = new char[1] { 'a' };            
+            var expectedDestination = new char[1] { 'a' };
             Span<char> destination = new char[1] { 'a' };
 
-            string emptyString = new string(a, 2, 0);            
-            Assert.Equal("", emptyString.ToUpperInvariant());            
+            string emptyString = new string(a, 2, 0);
+            Assert.Equal("", emptyString.ToUpperInvariant());
 
-            ReadOnlySpan<char> source = emptyString.AsSpan();                       
+            ReadOnlySpan<char> source = emptyString.AsSpan();
             Assert.Equal(source.Length, source.ToUpper(destination, CultureInfo.CurrentCulture));
             Assert.Equal(source.Length, source.ToUpperInvariant(destination));
             Assert.Equal(expectedDestination, destination.ToArray());
             Assert.Equal(expectedSource, a);
 
-            emptyString = string.Empty;            
+            emptyString = string.Empty;
             Assert.Equal("", emptyString.ToUpperInvariant()); 
          
             source = emptyString.AsSpan();
@@ -5384,10 +5384,10 @@ namespace System.Tests
         {
             var expectedDestination = new char[3] { 'B', 'C', 'B' };
 
-            {                
+            {
                 char[] a = { 'a', 'b', 'C', 'b', 'C', 'b' };
 
-                string s1 = new string(a, 1, 3);                
+                string s1 = new string(a, 1, 3);
                 Assert.Equal(expectedDestination, s1.ToUpper(CultureInfo.CurrentCulture).ToArray());
 
                 var source = new ReadOnlySpan<char>(a, 1, 3);
@@ -5401,7 +5401,7 @@ namespace System.Tests
             {
                 char[] a = { 'a', 'b', 'C', 'b', 'C', 'b' };
 
-                string s1 = new string(a, 1, 3);                
+                string s1 = new string(a, 1, 3);
                 Assert.Equal(expectedDestination, s1.ToUpperInvariant().ToArray());
 
                 var source = new ReadOnlySpan<char>(a, 1, 3);
@@ -5419,7 +5419,7 @@ namespace System.Tests
             {
                 var expectedSource = new char[3] { 'a', 'B', 'c' };
                                 
-                string s1 = "aBc";                
+                string s1 = "aBc";
                 var expectedDestinationString = "ABC";
                 Assert.Equal(expectedDestinationString, s1.ToUpperInvariant());
 
@@ -6326,7 +6326,7 @@ namespace System.Tests
                 a[0] = 'c';
                 a[length - 1] = 'c';
 
-                string s1 = new string(a);                
+                string s1 = new string(a);
                 string trimResultString = s1.Trim(chars);
                 string trimStartResultString = s1.TrimStart(chars);
                 string trimEndResultString = s1.TrimEnd(chars);
@@ -7109,7 +7109,7 @@ namespace System.Tests
                 Thread.CurrentThread.CurrentCulture = backupCulture;
 
                 s1 = "\u0069\u00df\u0049\u03b4"; // ißIδ
-                s2 = "\u0069\u03b4\u03b4\u0049";  // iδδI
+                s2 = "\u0069\u03b4\u03b4\u0049"; // iδδI
 
                 Assert.False(s1.StartsWith(s2, StringComparison.Ordinal));
                 Assert.False(s1.StartsWith(s2, StringComparison.InvariantCulture));
index 8fbc1f4..28b18f6 100644 (file)
@@ -242,7 +242,7 @@ namespace Microsoft.CSharp.RuntimeBinder
                 out argInfos);
 
             CallSiteBinder binder;
-            if (String.IsNullOrEmpty(methodName))
+            if (string.IsNullOrEmpty(methodName))
             {
                 //null or empty indicates delegate invocation.
                 binder = new CSharpInvokeBinder(
index 66de277..a10de91 100644 (file)
@@ -79,7 +79,7 @@ namespace Microsoft.CSharp.RuntimeBinder.Tests
 
             public static dynamic ValueTypeDelegate() => (Func<PrivateValueType>)(() => new PrivateValueType());
 
-            public unsafe static dynamic PointerArray() => new PrivateValueType*[4];
+            public static unsafe dynamic PointerArray() => new PrivateValueType*[4];
 
             public static dynamic PrivateInterfaceDelegate() => (Func<IPrivateInterface>)(() => null);
 
index 363345d..f1bddde 100644 (file)
@@ -516,7 +516,7 @@ namespace Microsoft.CSharp.RuntimeBinder.Tests
             dFirst.DoNothing();
             dynamic d = new DerivedOuterHidingNested();
             Assert.Equal(42, d.Inner());
-               }
+        }
 
         [Fact]
         public void CannotCallOperatorDirectly()
index 79078fe..7af27a3 100644 (file)
@@ -26,7 +26,7 @@ namespace Microsoft.IO
             return span.SequenceEqual(value);
         }
 
-        public unsafe static string Create<TState>(int length, TState state, SpanAction<char, TState> action)
+        public static unsafe string Create<TState>(int length, TState state, SpanAction<char, TState> action)
         {
             if (action == null)
                 throw new ArgumentNullException(nameof(action));
@@ -46,7 +46,7 @@ namespace Microsoft.IO
             return result;
         }
 
-        internal unsafe static string Concat(ReadOnlySpan<char> str0, ReadOnlySpan<char> str1)
+        internal static unsafe string Concat(ReadOnlySpan<char> str0, ReadOnlySpan<char> str1)
         {
             var result = new string('\0', checked(str0.Length + str1.Length));
             fixed (char* resultPtr = result)
@@ -59,7 +59,7 @@ namespace Microsoft.IO
             return result;
         }
 
-        internal unsafe static string Concat(ReadOnlySpan<char> str0, ReadOnlySpan<char> str1, ReadOnlySpan<char> str2)
+        internal static unsafe string Concat(ReadOnlySpan<char> str0, ReadOnlySpan<char> str1, ReadOnlySpan<char> str2)
         {
             var result = new string('\0', checked(str0.Length + str1.Length + str2.Length));
             fixed (char* resultPtr = result)
index 9dc19cf..59574e6 100644 (file)
@@ -73,7 +73,7 @@ namespace Microsoft.Win32
         [SuppressMessage("Microsoft.Reliability", "CA2006:UseSafeHandleToEncapsulateNativeResources")]
         private static volatile IntPtr s_processWinStation = IntPtr.Zero;
         private static volatile bool s_isUserInteractive = false;
-        private unsafe static bool UserInteractive
+        private static unsafe bool UserInteractive
         {
             get
             {
index 5982e32..99c4bce 100644 (file)
@@ -11,7 +11,7 @@ namespace System.CodeDom.Compiler
 {
     public partial class CompilerResults
     {
-       private Evidence _evidence;
+        private Evidence _evidence;
 
         [Obsolete("CAS policy is obsolete and will be removed in a future release of the .NET Framework. Please see https://go2.microsoft.com/fwlink/?LinkId=131738 for more information.")]
         public Evidence Evidence
index 1512207..50bba3b 100644 (file)
@@ -6,30 +6,30 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeArgumentReferenceExpressionTests : CodeObjectTestBase<CodeArgumentReferenceExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var argumentReference = new CodeArgumentReferenceExpression();
-                       Assert.Empty(argumentReference.ParameterName);
-               }
+    public class CodeArgumentReferenceExpressionTests : CodeObjectTestBase<CodeArgumentReferenceExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var argumentReference = new CodeArgumentReferenceExpression();
+            Assert.Empty(argumentReference.ParameterName);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Ctor_String(string parameterName)
-               {
-                       var argumentReference = new CodeArgumentReferenceExpression(parameterName);
-                       Assert.Equal(parameterName ?? string.Empty, argumentReference.ParameterName);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Ctor_String(string parameterName)
+        {
+            var argumentReference = new CodeArgumentReferenceExpression(parameterName);
+            Assert.Equal(parameterName ?? string.Empty, argumentReference.ParameterName);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void ParameterName_Set_Get_ReturnsExpected(string parameterName)
-               {
-                       var argumentReference = new CodeArgumentReferenceExpression();
-                       argumentReference.ParameterName = parameterName;
-                       Assert.Equal(parameterName ?? string.Empty, argumentReference.ParameterName);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void ParameterName_Set_Get_ReturnsExpected(string parameterName)
+        {
+            var argumentReference = new CodeArgumentReferenceExpression();
+            argumentReference.ParameterName = parameterName;
+            Assert.Equal(parameterName ?? string.Empty, argumentReference.ParameterName);
+        }
+    }
 }
index e9c212e..0706f1f 100644 (file)
@@ -8,255 +8,255 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeArrayCreateExpressionTests : CodeObjectTestBase<CodeArrayCreateExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var arrayCreate = new CodeArrayCreateExpression();
-                       Assert.Equal(typeof(void).FullName, arrayCreate.CreateType.BaseType);
-                       Assert.Empty(arrayCreate.Initializers);
+    public class CodeArrayCreateExpressionTests : CodeObjectTestBase<CodeArrayCreateExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var arrayCreate = new CodeArrayCreateExpression();
+            Assert.Equal(typeof(void).FullName, arrayCreate.CreateType.BaseType);
+            Assert.Empty(arrayCreate.Initializers);
 
-                       Assert.Equal(0, arrayCreate.Size);
-                       Assert.Null(arrayCreate.SizeExpression);
-               }
+            Assert.Equal(0, arrayCreate.Size);
+            Assert.Null(arrayCreate.SizeExpression);
+        }
 
-               public static IEnumerable<object[]> TypeString_TestData()
-               {
-                       yield return new object[] { null, "System.Void" };
-                       yield return new object[] { "", "System.Void" };
-                       yield return new object[] { "Int32", "Int32" };
-               }
+        public static IEnumerable<object[]> TypeString_TestData()
+        {
+            yield return new object[] { null, "System.Void" };
+            yield return new object[] { "", "System.Void" };
+            yield return new object[] { "Int32", "Int32" };
+        }
 
-               [Theory]
-               [MemberData(nameof(TypeString_TestData))]
-               public void Ctor_String_EmptyParamsCodeExpression(string type, string expectedBaseType)
-               {
-                       CodeExpression[] initializers = new CodeExpression[0];
-                       var arrayCreate = new CodeArrayCreateExpression(type, initializers);
-                       Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
-                       Assert.Equal(initializers, arrayCreate.Initializers.Cast<CodeExpression>());
-                       Assert.Equal(0, arrayCreate.Size);
-                       Assert.Null(arrayCreate.SizeExpression);
-               }
+        [Theory]
+        [MemberData(nameof(TypeString_TestData))]
+        public void Ctor_String_EmptyParamsCodeExpression(string type, string expectedBaseType)
+        {
+            CodeExpression[] initializers = new CodeExpression[0];
+            var arrayCreate = new CodeArrayCreateExpression(type, initializers);
+            Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
+            Assert.Equal(initializers, arrayCreate.Initializers.Cast<CodeExpression>());
+            Assert.Equal(0, arrayCreate.Size);
+            Assert.Null(arrayCreate.SizeExpression);
+        }
 
-               [Theory]
-               [MemberData(nameof(TypeString_TestData))]
-               public void Ctor_String_NonEmptyParamsCodeExpression(string type, string expectedBaseType)
-               {
-                       CodeExpression[] initializers = new CodeExpression[] { new CodePrimitiveExpression("Value1"), new CodePrimitiveExpression("Value2") };
-                       var arrayCreate = new CodeArrayCreateExpression(type, initializers);
-                       Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
-                       Assert.Equal(initializers, arrayCreate.Initializers.Cast<CodeExpression>());
-                       Assert.Equal(0, arrayCreate.Size);
-                       Assert.Null(arrayCreate.SizeExpression);
-               }
+        [Theory]
+        [MemberData(nameof(TypeString_TestData))]
+        public void Ctor_String_NonEmptyParamsCodeExpression(string type, string expectedBaseType)
+        {
+            CodeExpression[] initializers = new CodeExpression[] { new CodePrimitiveExpression("Value1"), new CodePrimitiveExpression("Value2") };
+            var arrayCreate = new CodeArrayCreateExpression(type, initializers);
+            Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
+            Assert.Equal(initializers, arrayCreate.Initializers.Cast<CodeExpression>());
+            Assert.Equal(0, arrayCreate.Size);
+            Assert.Null(arrayCreate.SizeExpression);
+        }
 
-               public static IEnumerable<object[]> Type_TestData()
-               {
-                       yield return new object[] { typeof(int), "System.Int32" };
-                       yield return new object[] { typeof(List<>), "System.Collections.Generic.List`1" };
-                       yield return new object[] { typeof(void), "System.Void" };
-               }
+        public static IEnumerable<object[]> Type_TestData()
+        {
+            yield return new object[] { typeof(int), "System.Int32" };
+            yield return new object[] { typeof(List<>), "System.Collections.Generic.List`1" };
+            yield return new object[] { typeof(void), "System.Void" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Type_TestData))]
-               public void Ctor_Type_EmptyParamsCodeExpression(Type type, string expectedBaseType)
-               {
-                       CodeExpression[] initializers = new CodeExpression[0];
-                       var arrayCreate = new CodeArrayCreateExpression(type, initializers);
-                       Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
-                       Assert.Equal(initializers, arrayCreate.Initializers.Cast<CodeExpression>());
-                       Assert.Equal(0, arrayCreate.Size);
-                       Assert.Null(arrayCreate.SizeExpression);
-               }
+        [Theory]
+        [MemberData(nameof(Type_TestData))]
+        public void Ctor_Type_EmptyParamsCodeExpression(Type type, string expectedBaseType)
+        {
+            CodeExpression[] initializers = new CodeExpression[0];
+            var arrayCreate = new CodeArrayCreateExpression(type, initializers);
+            Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
+            Assert.Equal(initializers, arrayCreate.Initializers.Cast<CodeExpression>());
+            Assert.Equal(0, arrayCreate.Size);
+            Assert.Null(arrayCreate.SizeExpression);
+        }
 
-               [Theory]
-               [MemberData(nameof(Type_TestData))]
-               public void Ctor_Type_NonEmptyParamsCodeExpression(Type type, string expectedBaseType)
-               {
-                       CodeExpression[] initializers = new CodeExpression[] { new CodePrimitiveExpression("Value1"), new CodePrimitiveExpression("Value2") };
-                       var arrayCreate = new CodeArrayCreateExpression(type, initializers);
-                       Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
-                       Assert.Equal(initializers, arrayCreate.Initializers.Cast<CodeExpression>());
-                       Assert.Equal(0, arrayCreate.Size);
-                       Assert.Null(arrayCreate.SizeExpression);
-               }
+        [Theory]
+        [MemberData(nameof(Type_TestData))]
+        public void Ctor_Type_NonEmptyParamsCodeExpression(Type type, string expectedBaseType)
+        {
+            CodeExpression[] initializers = new CodeExpression[] { new CodePrimitiveExpression("Value1"), new CodePrimitiveExpression("Value2") };
+            var arrayCreate = new CodeArrayCreateExpression(type, initializers);
+            Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
+            Assert.Equal(initializers, arrayCreate.Initializers.Cast<CodeExpression>());
+            Assert.Equal(0, arrayCreate.Size);
+            Assert.Null(arrayCreate.SizeExpression);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Ctor_CodeTypeReference_ParamsCodeExpression(CodeTypeReference type)
-               {
-                       CodeExpression[] initializers = new CodeExpression[0];
-                       var arrayCreate = new CodeArrayCreateExpression(type, initializers);
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, arrayCreate.CreateType.BaseType);
-                       Assert.Equal(initializers, arrayCreate.Initializers.Cast<CodeExpression>());
-                       Assert.Equal(0, arrayCreate.Size);
-                       Assert.Null(arrayCreate.SizeExpression);
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Ctor_CodeTypeReference_ParamsCodeExpression(CodeTypeReference type)
+        {
+            CodeExpression[] initializers = new CodeExpression[0];
+            var arrayCreate = new CodeArrayCreateExpression(type, initializers);
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, arrayCreate.CreateType.BaseType);
+            Assert.Equal(initializers, arrayCreate.Initializers.Cast<CodeExpression>());
+            Assert.Equal(0, arrayCreate.Size);
+            Assert.Null(arrayCreate.SizeExpression);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Ctor_CodeTypeReference_NonEmptyParamsCodeExpression(CodeTypeReference type)
-               {
-                       CodeExpression[] initializers = new CodeExpression[] { new CodePrimitiveExpression("Value1"), new CodePrimitiveExpression("Value2") };
-                       var arrayCreate = new CodeArrayCreateExpression(type, initializers);
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, arrayCreate.CreateType.BaseType);
-                       Assert.Equal(initializers, arrayCreate.Initializers.Cast<CodeExpression>());
-                       Assert.Equal(0, arrayCreate.Size);
-                       Assert.Null(arrayCreate.SizeExpression);
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Ctor_CodeTypeReference_NonEmptyParamsCodeExpression(CodeTypeReference type)
+        {
+            CodeExpression[] initializers = new CodeExpression[] { new CodePrimitiveExpression("Value1"), new CodePrimitiveExpression("Value2") };
+            var arrayCreate = new CodeArrayCreateExpression(type, initializers);
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, arrayCreate.CreateType.BaseType);
+            Assert.Equal(initializers, arrayCreate.Initializers.Cast<CodeExpression>());
+            Assert.Equal(0, arrayCreate.Size);
+            Assert.Null(arrayCreate.SizeExpression);
+        }
 
-               [Theory]
-               [MemberData(nameof(TypeString_TestData))]
-               public void Ctor_String_Int(string type, string expectedBaseType)
-               {
-                       foreach (int size in new int[] { -1, 0, 1 })
-                       {
-                               var arrayCreate = new CodeArrayCreateExpression(type, size);
-                               Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
-                               Assert.Empty(arrayCreate.Initializers);
-                               Assert.Equal(size, arrayCreate.Size);
-                               Assert.Null(arrayCreate.SizeExpression);
-                       }
-               }
+        [Theory]
+        [MemberData(nameof(TypeString_TestData))]
+        public void Ctor_String_Int(string type, string expectedBaseType)
+        {
+            foreach (int size in new int[] { -1, 0, 1 })
+            {
+                var arrayCreate = new CodeArrayCreateExpression(type, size);
+                Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
+                Assert.Empty(arrayCreate.Initializers);
+                Assert.Equal(size, arrayCreate.Size);
+                Assert.Null(arrayCreate.SizeExpression);
+            }
+        }
 
-               [Theory]
-               [MemberData(nameof(Type_TestData))]
-               public void Ctor_Type_Int(Type type, string expectedBaseType)
-               {
-                       foreach (int size in new int[] { -1, 0, 1 })
-                       {
-                               var arrayCreate = new CodeArrayCreateExpression(type, size);
-                               Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
-                               Assert.Empty(arrayCreate.Initializers);
-                               Assert.Equal(size, arrayCreate.Size);
-                               Assert.Null(arrayCreate.SizeExpression);
-                       }
-               }
+        [Theory]
+        [MemberData(nameof(Type_TestData))]
+        public void Ctor_Type_Int(Type type, string expectedBaseType)
+        {
+            foreach (int size in new int[] { -1, 0, 1 })
+            {
+                var arrayCreate = new CodeArrayCreateExpression(type, size);
+                Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
+                Assert.Empty(arrayCreate.Initializers);
+                Assert.Equal(size, arrayCreate.Size);
+                Assert.Null(arrayCreate.SizeExpression);
+            }
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Ctor_CodeTypeReference_Int(CodeTypeReference type)
-               {
-                       foreach (int size in new int[] { -1, 0, 1 })
-                       {
-                               var arrayCreate = new CodeArrayCreateExpression(type, size);
-                               Assert.Equal((type ?? new CodeTypeReference("")).BaseType, arrayCreate.CreateType.BaseType);
-                               Assert.Empty(arrayCreate.Initializers);
-                               Assert.Equal(size, arrayCreate.Size);
-                               Assert.Null(arrayCreate.SizeExpression);
-                       }
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Ctor_CodeTypeReference_Int(CodeTypeReference type)
+        {
+            foreach (int size in new int[] { -1, 0, 1 })
+            {
+                var arrayCreate = new CodeArrayCreateExpression(type, size);
+                Assert.Equal((type ?? new CodeTypeReference("")).BaseType, arrayCreate.CreateType.BaseType);
+                Assert.Empty(arrayCreate.Initializers);
+                Assert.Equal(size, arrayCreate.Size);
+                Assert.Null(arrayCreate.SizeExpression);
+            }
+        }
 
-               [Theory]
-               [MemberData(nameof(TypeString_TestData))]
-               public void Ctor_String_CodeExpression(string type, string expectedBaseType)
-               {
-                       foreach (CodeExpression sizeExpression in new CodeExpression[] { null, new CodePrimitiveExpression("Value") })
-                       {
-                               var arrayCreate = new CodeArrayCreateExpression(type, sizeExpression);
-                               Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
-                               Assert.Empty(arrayCreate.Initializers);
-                               Assert.Equal(0, arrayCreate.Size);
-                               Assert.Equal(sizeExpression, arrayCreate.SizeExpression);
-                       }
-               }
+        [Theory]
+        [MemberData(nameof(TypeString_TestData))]
+        public void Ctor_String_CodeExpression(string type, string expectedBaseType)
+        {
+            foreach (CodeExpression sizeExpression in new CodeExpression[] { null, new CodePrimitiveExpression("Value") })
+            {
+                var arrayCreate = new CodeArrayCreateExpression(type, sizeExpression);
+                Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
+                Assert.Empty(arrayCreate.Initializers);
+                Assert.Equal(0, arrayCreate.Size);
+                Assert.Equal(sizeExpression, arrayCreate.SizeExpression);
+            }
+        }
 
-               [Theory]
-               [MemberData(nameof(Type_TestData))]
-               public void Ctor_Type_CodeExpression(Type type, string expectedBaseType)
-               {
-                       foreach (CodeExpression sizeExpression in new CodeExpression[] { null, new CodePrimitiveExpression("Value") })
-                       {
-                               var arrayCreate = new CodeArrayCreateExpression(type, sizeExpression);
-                               Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
-                               Assert.Empty(arrayCreate.Initializers);
-                               Assert.Equal(0, arrayCreate.Size);
-                               Assert.Equal(sizeExpression, arrayCreate.SizeExpression);
-                       }
-               }
+        [Theory]
+        [MemberData(nameof(Type_TestData))]
+        public void Ctor_Type_CodeExpression(Type type, string expectedBaseType)
+        {
+            foreach (CodeExpression sizeExpression in new CodeExpression[] { null, new CodePrimitiveExpression("Value") })
+            {
+                var arrayCreate = new CodeArrayCreateExpression(type, sizeExpression);
+                Assert.Equal(expectedBaseType, arrayCreate.CreateType.BaseType);
+                Assert.Empty(arrayCreate.Initializers);
+                Assert.Equal(0, arrayCreate.Size);
+                Assert.Equal(sizeExpression, arrayCreate.SizeExpression);
+            }
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Ctor_CodeTypeReference_CodeExpression(CodeTypeReference type)
-               {
-                       foreach (CodeExpression sizeExpression in new CodeExpression[] { null, new CodePrimitiveExpression("Value") })
-                       {
-                               var arrayCreate = new CodeArrayCreateExpression(type, sizeExpression);
-                               Assert.Equal((type ?? new CodeTypeReference("")).BaseType, arrayCreate.CreateType.BaseType);
-                               Assert.Empty(arrayCreate.Initializers);
-                               Assert.Equal(0, arrayCreate.Size);
-                               Assert.Equal(sizeExpression, arrayCreate.SizeExpression);
-                       }
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Ctor_CodeTypeReference_CodeExpression(CodeTypeReference type)
+        {
+            foreach (CodeExpression sizeExpression in new CodeExpression[] { null, new CodePrimitiveExpression("Value") })
+            {
+                var arrayCreate = new CodeArrayCreateExpression(type, sizeExpression);
+                Assert.Equal((type ?? new CodeTypeReference("")).BaseType, arrayCreate.CreateType.BaseType);
+                Assert.Empty(arrayCreate.Initializers);
+                Assert.Equal(0, arrayCreate.Size);
+                Assert.Equal(sizeExpression, arrayCreate.SizeExpression);
+            }
+        }
 
-               [Fact]
-               public void Ctor_NullType_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeArrayCreateExpression((Type)null, new CodePrimitiveExpression()));
-                       AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeArrayCreateExpression((Type)null, new CodePrimitiveExpression[0]));
-                       AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeArrayCreateExpression((Type)null, 0));
-               }
+        [Fact]
+        public void Ctor_NullType_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeArrayCreateExpression((Type)null, new CodePrimitiveExpression()));
+            AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeArrayCreateExpression((Type)null, new CodePrimitiveExpression[0]));
+            AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeArrayCreateExpression((Type)null, 0));
+        }
 
-               [Fact]
-               public void Ctor_NullTypeInitializers_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayCreateExpression("", (CodePrimitiveExpression[])null));
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayCreateExpression(typeof(void), (CodePrimitiveExpression[])null));
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayCreateExpression(new CodeTypeReference(), (CodePrimitiveExpression[])null));
-               }
+        [Fact]
+        public void Ctor_NullTypeInitializers_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayCreateExpression("", (CodePrimitiveExpression[])null));
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayCreateExpression(typeof(void), (CodePrimitiveExpression[])null));
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayCreateExpression(new CodeTypeReference(), (CodePrimitiveExpression[])null));
+        }
 
-               [Fact]
-               public void Ctor_NullTypeInInitalizers_ThrowsArgumentNullException()
-               {
-                       CodePrimitiveExpression[] initializers = new CodePrimitiveExpression[] { null };
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayCreateExpression("", initializers));
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayCreateExpression(typeof(void), initializers));
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayCreateExpression(new CodeTypeReference(), initializers));
-               }
+        [Fact]
+        public void Ctor_NullTypeInInitalizers_ThrowsArgumentNullException()
+        {
+            CodePrimitiveExpression[] initializers = new CodePrimitiveExpression[] { null };
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayCreateExpression("", initializers));
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayCreateExpression(typeof(void), initializers));
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayCreateExpression(new CodeTypeReference(), initializers));
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void CreateType_Set_Get_ReturnsExpected(CodeTypeReference value)
-               {
-                       var arrayCreate = new CodeArrayCreateExpression();
-                       arrayCreate.CreateType = value;
-                       Assert.Equal((value ?? new CodeTypeReference("")).BaseType, arrayCreate.CreateType.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void CreateType_Set_Get_ReturnsExpected(CodeTypeReference value)
+        {
+            var arrayCreate = new CodeArrayCreateExpression();
+            arrayCreate.CreateType = value;
+            Assert.Equal((value ?? new CodeTypeReference("")).BaseType, arrayCreate.CreateType.BaseType);
+        }
 
-               [Fact]
-               public void Initializers_AddMultiple_ReturnsExpected()
-               {
-                       var arrayCreate = new CodeArrayCreateExpression();
+        [Fact]
+        public void Initializers_AddMultiple_ReturnsExpected()
+        {
+            var arrayCreate = new CodeArrayCreateExpression();
 
-                       CodeExpression expression1 = new CodePrimitiveExpression("Value1");
-                       arrayCreate.Initializers.Add(expression1);
-                       Assert.Equal(new CodeExpression[] { expression1 }, arrayCreate.Initializers.Cast<CodeExpression>());
+            CodeExpression expression1 = new CodePrimitiveExpression("Value1");
+            arrayCreate.Initializers.Add(expression1);
+            Assert.Equal(new CodeExpression[] { expression1 }, arrayCreate.Initializers.Cast<CodeExpression>());
 
-                       CodeExpression expression2 = new CodePrimitiveExpression("Value2");
-                       arrayCreate.Initializers.Add(expression2);
-                       Assert.Equal(new CodeExpression[] { expression1, expression2 }, arrayCreate.Initializers.Cast<CodeExpression>());
-               }
+            CodeExpression expression2 = new CodePrimitiveExpression("Value2");
+            arrayCreate.Initializers.Add(expression2);
+            Assert.Equal(new CodeExpression[] { expression1, expression2 }, arrayCreate.Initializers.Cast<CodeExpression>());
+        }
 
-               [Theory]
-               [InlineData(-1)]
-               [InlineData(0)]
-               [InlineData(1)]
-               public void Size_Set_Get_ReturnsExpected(int value)
-               {
-                       var arrayCreate = new CodeArrayCreateExpression();
-                       arrayCreate.Size = value;
-                       Assert.Equal(value, arrayCreate.Size);
-               }
+        [Theory]
+        [InlineData(-1)]
+        [InlineData(0)]
+        [InlineData(1)]
+        public void Size_Set_Get_ReturnsExpected(int value)
+        {
+            var arrayCreate = new CodeArrayCreateExpression();
+            arrayCreate.Size = value;
+            Assert.Equal(value, arrayCreate.Size);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void SizeExpression_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var arrayCreate = new CodeArrayCreateExpression();
-                       arrayCreate.SizeExpression = value;
-                       Assert.Equal(value, arrayCreate.SizeExpression);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void SizeExpression_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var arrayCreate = new CodeArrayCreateExpression();
+            arrayCreate.SizeExpression = value;
+            Assert.Equal(value, arrayCreate.SizeExpression);
+        }
+    }
 }
index edd7c54..a6eb6c0 100644 (file)
@@ -8,64 +8,64 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeArrayIndexerExpressionTests : CodeObjectTestBase<CodeArrayIndexerExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var arrayIndexer = new CodeArrayIndexerExpression();
-                       Assert.Null(arrayIndexer.TargetObject);
-                       Assert.Empty(arrayIndexer.Indices);
-               }
+    public class CodeArrayIndexerExpressionTests : CodeObjectTestBase<CodeArrayIndexerExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var arrayIndexer = new CodeArrayIndexerExpression();
+            Assert.Null(arrayIndexer.TargetObject);
+            Assert.Empty(arrayIndexer.Indices);
+        }
 
-               public static IEnumerable<object[]> Ctor_TestData()
-               {
-                       yield return new object[] { null, new CodeExpression[0] };
-                       yield return new object[] { new CodePrimitiveExpression("Value1"), new CodeExpression[] { new CodePrimitiveExpression("Value2") } };
-               }
+        public static IEnumerable<object[]> Ctor_TestData()
+        {
+            yield return new object[] { null, new CodeExpression[0] };
+            yield return new object[] { new CodePrimitiveExpression("Value1"), new CodeExpression[] { new CodePrimitiveExpression("Value2") } };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TestData))]
-               public void Ctor(CodeExpression targetObject, CodeExpression[] indices)
-               {
-                       var arrayIndexer = new CodeArrayIndexerExpression(targetObject, indices);
-                       Assert.Equal(targetObject, arrayIndexer.TargetObject);
-                       Assert.Equal(indices, arrayIndexer.Indices.Cast<CodeExpression>());
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TestData))]
+        public void Ctor(CodeExpression targetObject, CodeExpression[] indices)
+        {
+            var arrayIndexer = new CodeArrayIndexerExpression(targetObject, indices);
+            Assert.Equal(targetObject, arrayIndexer.TargetObject);
+            Assert.Equal(indices, arrayIndexer.Indices.Cast<CodeExpression>());
+        }
 
-               [Fact]
-               public void Ctor_NullIndices_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayIndexerExpression(new CodeExpression(), null));
-               }
+        [Fact]
+        public void Ctor_NullIndices_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayIndexerExpression(new CodeExpression(), null));
+        }
 
-               [Fact]
-               public void Ctor_NullObjectInIndices_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayIndexerExpression(new CodeExpression(), new CodeExpression[] { null }));
-               }
+        [Fact]
+        public void Ctor_NullObjectInIndices_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeArrayIndexerExpression(new CodeExpression(), new CodeExpression[] { null }));
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var arrayIndexer = new CodeArrayIndexerExpression();
-                       arrayIndexer.TargetObject = value;
-                       Assert.Equal(value, arrayIndexer.TargetObject);
-               }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var arrayIndexer = new CodeArrayIndexerExpression();
+            arrayIndexer.TargetObject = value;
+            Assert.Equal(value, arrayIndexer.TargetObject);
+        }
 
-               [Fact]
-               public void Indices_AddMultiple_ReturnsExpected()
-               {
-                       var arrayIndexer = new CodeArrayIndexerExpression();
+        [Fact]
+        public void Indices_AddMultiple_ReturnsExpected()
+        {
+            var arrayIndexer = new CodeArrayIndexerExpression();
 
-                       CodeExpression expression1 = new CodePrimitiveExpression("Value1");
-                       arrayIndexer.Indices.Add(expression1);
-                       Assert.Equal(new CodeExpression[] { expression1 }, arrayIndexer.Indices.Cast<CodeExpression>());
+            CodeExpression expression1 = new CodePrimitiveExpression("Value1");
+            arrayIndexer.Indices.Add(expression1);
+            Assert.Equal(new CodeExpression[] { expression1 }, arrayIndexer.Indices.Cast<CodeExpression>());
 
-                       CodeExpression expression2 = new CodePrimitiveExpression("Value2");
-                       arrayIndexer.Indices.Add(expression2);
-                       Assert.Equal(new CodeExpression[] { expression1, expression2 }, arrayIndexer.Indices.Cast<CodeExpression>());
-               }
-       }
+            CodeExpression expression2 = new CodePrimitiveExpression("Value2");
+            arrayIndexer.Indices.Add(expression2);
+            Assert.Equal(new CodeExpression[] { expression1, expression2 }, arrayIndexer.Indices.Cast<CodeExpression>());
+        }
+    }
 }
index 1bec665..890dc7a 100644 (file)
@@ -7,49 +7,49 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeAssignStatementTests : CodeStatementTestBase<CodeAssignStatement>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var assign = new CodeAssignStatement();
-                       Assert.Null(assign.Left);
-                       Assert.Null(assign.Right);
-               }
+    public class CodeAssignStatementTests : CodeStatementTestBase<CodeAssignStatement>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var assign = new CodeAssignStatement();
+            Assert.Null(assign.Left);
+            Assert.Null(assign.Right);
+        }
 
-               public static IEnumerable<object[]> Ctor_TestData()
-               {
-                       yield return new object[] { null, null };
-                       yield return new object[] { new CodePrimitiveExpression("Value1"), null };
-                       yield return new object[] { null, new CodePrimitiveExpression("Value2") };
-                       yield return new object[] { new CodePrimitiveExpression("Value1"), new CodePrimitiveExpression("Value2") };
-               }
+        public static IEnumerable<object[]> Ctor_TestData()
+        {
+            yield return new object[] { null, null };
+            yield return new object[] { new CodePrimitiveExpression("Value1"), null };
+            yield return new object[] { null, new CodePrimitiveExpression("Value2") };
+            yield return new object[] { new CodePrimitiveExpression("Value1"), new CodePrimitiveExpression("Value2") };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TestData))]
-               public void Ctor_CodeExpression_CodeExpression(CodeExpression left, CodeExpression right)
-               {
-                       var assign = new CodeAssignStatement(left, right);
-                       Assert.Equal(left, assign.Left);
-                       Assert.Equal(right, assign.Right);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TestData))]
+        public void Ctor_CodeExpression_CodeExpression(CodeExpression left, CodeExpression right)
+        {
+            var assign = new CodeAssignStatement(left, right);
+            Assert.Equal(left, assign.Left);
+            Assert.Equal(right, assign.Right);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Left_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var assign = new CodeAssignStatement();
-                       assign.Left = value;
-                       Assert.Equal(value, assign.Left);
-               }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Left_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var assign = new CodeAssignStatement();
+            assign.Left = value;
+            Assert.Equal(value, assign.Left);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Right_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var assign = new CodeAssignStatement();
-                       assign.Right = value;
-                       Assert.Equal(value, assign.Right);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Right_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var assign = new CodeAssignStatement();
+            assign.Right = value;
+            Assert.Equal(value, assign.Right);
+        }
+    }
 }
index 4908531..5b99fc9 100644 (file)
@@ -7,67 +7,67 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeAttachEventStatementTests : CodeStatementTestBase<CodeAttachEventStatement>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var attachEvent = new CodeAttachEventStatement();
-                       Assert.Empty(attachEvent.Event.EventName);
-                       Assert.Null(attachEvent.Event.TargetObject);
-                       Assert.Null(attachEvent.Listener);
-               }
+    public class CodeAttachEventStatementTests : CodeStatementTestBase<CodeAttachEventStatement>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var attachEvent = new CodeAttachEventStatement();
+            Assert.Empty(attachEvent.Event.EventName);
+            Assert.Null(attachEvent.Event.TargetObject);
+            Assert.Null(attachEvent.Listener);
+        }
 
-               public static IEnumerable<object[]> Ctor_CodeExpression_String_CodeExpression_TestData()
-               {
-                       yield return new object[] { null, null, null };
-                       yield return new object[] { new CodePrimitiveExpression("Value1"), "EventName", new CodePrimitiveExpression("Value2") };
-               }
+        public static IEnumerable<object[]> Ctor_CodeExpression_String_CodeExpression_TestData()
+        {
+            yield return new object[] { null, null, null };
+            yield return new object[] { new CodePrimitiveExpression("Value1"), "EventName", new CodePrimitiveExpression("Value2") };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_CodeExpression_String_CodeExpression_TestData))]
-               public void Ctor_CodeExpression_String_CodeExpression(CodeExpression targetObject, string eventName, CodeExpression listener)
-               {
-                       var attachEvent = new CodeAttachEventStatement(targetObject, eventName, listener);
-                       Assert.Equal(targetObject, attachEvent.Event.TargetObject);
-                       Assert.Equal(eventName ?? string.Empty, attachEvent.Event.EventName);
-                       Assert.Equal(listener, attachEvent.Listener);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_CodeExpression_String_CodeExpression_TestData))]
+        public void Ctor_CodeExpression_String_CodeExpression(CodeExpression targetObject, string eventName, CodeExpression listener)
+        {
+            var attachEvent = new CodeAttachEventStatement(targetObject, eventName, listener);
+            Assert.Equal(targetObject, attachEvent.Event.TargetObject);
+            Assert.Equal(eventName ?? string.Empty, attachEvent.Event.EventName);
+            Assert.Equal(listener, attachEvent.Listener);
+        }
 
-               public static IEnumerable<object[]> CodeEventReferenceExpression_CodeExpression_TestData()
-               {
-                       yield return new object[] { null, null };
-                       yield return new object[] { new CodeEventReferenceExpression(null, null), null };
-                       yield return new object[] { new CodeEventReferenceExpression(new CodePrimitiveExpression("Value1"), "EventName"), new CodePrimitiveExpression("Value2") };
-               }
+        public static IEnumerable<object[]> CodeEventReferenceExpression_CodeExpression_TestData()
+        {
+            yield return new object[] { null, null };
+            yield return new object[] { new CodeEventReferenceExpression(null, null), null };
+            yield return new object[] { new CodeEventReferenceExpression(new CodePrimitiveExpression("Value1"), "EventName"), new CodePrimitiveExpression("Value2") };
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeEventReferenceExpression_CodeExpression_TestData))]
-               public void Ctor_CodeEventReferenceExpression_CodeExpression(CodeEventReferenceExpression eventExpresion, CodeExpression listener)
-               {
-                       var attachEvent = new CodeAttachEventStatement(eventExpresion, listener);
-                       Assert.Equal((eventExpresion ?? new CodeEventReferenceExpression()).TargetObject, attachEvent.Event.TargetObject);
-                       Assert.Equal((eventExpresion ?? new CodeEventReferenceExpression()).EventName, attachEvent.Event.EventName);
-                       Assert.Equal(listener, attachEvent.Listener);
-               }
+        [Theory]
+        [MemberData(nameof(CodeEventReferenceExpression_CodeExpression_TestData))]
+        public void Ctor_CodeEventReferenceExpression_CodeExpression(CodeEventReferenceExpression eventExpresion, CodeExpression listener)
+        {
+            var attachEvent = new CodeAttachEventStatement(eventExpresion, listener);
+            Assert.Equal((eventExpresion ?? new CodeEventReferenceExpression()).TargetObject, attachEvent.Event.TargetObject);
+            Assert.Equal((eventExpresion ?? new CodeEventReferenceExpression()).EventName, attachEvent.Event.EventName);
+            Assert.Equal(listener, attachEvent.Listener);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeEventReferenceExpression_CodeExpression_TestData))]
-               public void Event_Set_Get_ReturnsExpected(CodeEventReferenceExpression value, CodeExpression _)
-               {
-                       var attachEvent = new CodeAttachEventStatement();
-                       attachEvent.Event = value;
-                       Assert.Equal((value ?? new CodeEventReferenceExpression()).TargetObject, attachEvent.Event.TargetObject);
-                       Assert.Equal((value ?? new CodeEventReferenceExpression()).EventName, attachEvent.Event.EventName);
-               }
+        [Theory]
+        [MemberData(nameof(CodeEventReferenceExpression_CodeExpression_TestData))]
+        public void Event_Set_Get_ReturnsExpected(CodeEventReferenceExpression value, CodeExpression _)
+        {
+            var attachEvent = new CodeAttachEventStatement();
+            attachEvent.Event = value;
+            Assert.Equal((value ?? new CodeEventReferenceExpression()).TargetObject, attachEvent.Event.TargetObject);
+            Assert.Equal((value ?? new CodeEventReferenceExpression()).EventName, attachEvent.Event.EventName);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Listener_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var attachEvent = new CodeAttachEventStatement();
-                       attachEvent.Listener = value;
-                       Assert.Equal(value, attachEvent.Listener);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Listener_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var attachEvent = new CodeAttachEventStatement();
+            attachEvent.Listener = value;
+            Assert.Equal(value, attachEvent.Listener);
+        }
+    }
 }
index 3a48078..924f4b7 100644 (file)
@@ -7,56 +7,56 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeAttributeArgumentTests : CodeDomTestBase
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var argument = new CodeAttributeArgument();
-                       Assert.Empty(argument.Name);
-                       Assert.Null(argument.Value);
-               }
+    public class CodeAttributeArgumentTests : CodeDomTestBase
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var argument = new CodeAttributeArgument();
+            Assert.Empty(argument.Name);
+            Assert.Null(argument.Value);
+        }
 
-               public static IEnumerable<object[]> Ctor_TestData()
-               {
-                       yield return new object[] { null, null };
-                       yield return new object[] { "", new CodePrimitiveExpression("Value1") };
-                       yield return new object[] { "Value1", new CodePrimitiveExpression("Value1") };
-               }
+        public static IEnumerable<object[]> Ctor_TestData()
+        {
+            yield return new object[] { null, null };
+            yield return new object[] { "", new CodePrimitiveExpression("Value1") };
+            yield return new object[] { "Value1", new CodePrimitiveExpression("Value1") };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TestData))]
-               public void Ctor(string name, CodeExpression value)
-               {
-                       if (string.IsNullOrEmpty(name))
-                       {
-                               var argument1 = new CodeAttributeArgument(value);
-                               Assert.Empty(argument1.Name);
-                               Assert.Equal(value, argument1.Value);
-                       }
-                       var argument2 = new CodeAttributeArgument(name, value);
-                       Assert.Equal(name ?? string.Empty, argument2.Name);
-                       Assert.Equal(value, argument2.Value);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TestData))]
+        public void Ctor(string name, CodeExpression value)
+        {
+            if (string.IsNullOrEmpty(name))
+            {
+                var argument1 = new CodeAttributeArgument(value);
+                Assert.Empty(argument1.Name);
+                Assert.Equal(value, argument1.Value);
+            }
+            var argument2 = new CodeAttributeArgument(name, value);
+            Assert.Equal(name ?? string.Empty, argument2.Name);
+            Assert.Equal(value, argument2.Value);
+        }
 
-               [Theory]
-               [InlineData(null)]
-               [InlineData("")]
-               [InlineData("Name")]
-               public void Name_Set_Get_ReturnsExpected(string value)
-               {
-                       var argument = new CodeAttributeArgument();
-                       argument.Name = value;
-                       Assert.Equal(value ?? string.Empty, argument.Name);
-               }
+        [Theory]
+        [InlineData(null)]
+        [InlineData("")]
+        [InlineData("Name")]
+        public void Name_Set_Get_ReturnsExpected(string value)
+        {
+            var argument = new CodeAttributeArgument();
+            argument.Name = value;
+            Assert.Equal(value ?? string.Empty, argument.Name);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Value_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var argument = new CodeAttributeArgument();
-                       argument.Value = value;
-                       Assert.Equal(value, argument.Value);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Value_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var argument = new CodeAttributeArgument();
+            argument.Value = value;
+            Assert.Equal(value, argument.Value);
+        }
+    }
 }
index 64040e8..da7986d 100644 (file)
@@ -8,105 +8,105 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeAttributeDeclarationTests : CodeDomTestBase
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var declaration = new CodeAttributeDeclaration();
-                       Assert.Empty(declaration.Name);
-                       Assert.Empty(declaration.Arguments);
-                       Assert.Null(declaration.AttributeType);
-               }
+    public class CodeAttributeDeclarationTests : CodeDomTestBase
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var declaration = new CodeAttributeDeclaration();
+            Assert.Empty(declaration.Name);
+            Assert.Empty(declaration.Arguments);
+            Assert.Null(declaration.AttributeType);
+        }
 
-               public static IEnumerable<object[]> Ctor_String_TestData()
-               {
-                       yield return new object[] { null, new CodePrimitiveExpression[0] };
-                       yield return new object[] { "", new CodePrimitiveExpression[0] };
-                       yield return new object[] { "Value1", new CodeAttributeArgument[0] };
-                       yield return new object[] { "Value1", new CodeAttributeArgument[] { new CodeAttributeArgument("Name", new CodePrimitiveExpression("Value")) } };
-                       yield return new object[] { "Value1", new CodeAttributeArgument[] { new CodeAttributeArgument() } };
-               }
+        public static IEnumerable<object[]> Ctor_String_TestData()
+        {
+            yield return new object[] { null, new CodePrimitiveExpression[0] };
+            yield return new object[] { "", new CodePrimitiveExpression[0] };
+            yield return new object[] { "Value1", new CodeAttributeArgument[0] };
+            yield return new object[] { "Value1", new CodeAttributeArgument[] { new CodeAttributeArgument("Name", new CodePrimitiveExpression("Value")) } };
+            yield return new object[] { "Value1", new CodeAttributeArgument[] { new CodeAttributeArgument() } };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_String_TestData))]
-               public void Ctor_String(string name, CodeAttributeArgument[] arguments)
-               {
-                       if (arguments.Length == 0)
-                       {
-                               var declaration1 = new CodeAttributeDeclaration(name);
-                               Assert.Equal(name ?? string.Empty, declaration1.Name);
-                               Assert.Empty(declaration1.Arguments);
-                               Assert.Equal(new CodeTypeReference(name).BaseType, declaration1.AttributeType.BaseType);
-                       }
-                       var declaration2 = new CodeAttributeDeclaration(name, arguments);
-                       Assert.Equal(name ?? string.Empty, declaration2.Name);
-                       Assert.Equal(arguments, declaration2.Arguments.Cast<CodeAttributeArgument>());
-                       Assert.Equal(new CodeTypeReference(name).BaseType, declaration2.AttributeType.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_String_TestData))]
+        public void Ctor_String(string name, CodeAttributeArgument[] arguments)
+        {
+            if (arguments.Length == 0)
+            {
+                var declaration1 = new CodeAttributeDeclaration(name);
+                Assert.Equal(name ?? string.Empty, declaration1.Name);
+                Assert.Empty(declaration1.Arguments);
+                Assert.Equal(new CodeTypeReference(name).BaseType, declaration1.AttributeType.BaseType);
+            }
+            var declaration2 = new CodeAttributeDeclaration(name, arguments);
+            Assert.Equal(name ?? string.Empty, declaration2.Name);
+            Assert.Equal(arguments, declaration2.Arguments.Cast<CodeAttributeArgument>());
+            Assert.Equal(new CodeTypeReference(name).BaseType, declaration2.AttributeType.BaseType);
+        }
 
-               public static IEnumerable<object[]> Ctor_CodeTypeReference_TestData()
-               {
-                       yield return new object[] { null, null };
-                       yield return new object[] { new CodeTypeReference(typeof(int)), new CodeAttributeArgument[0] };
-                       yield return new object[] { new CodeTypeReference("System.Void"), new CodeAttributeArgument[] { new CodeAttributeArgument("Name", new CodePrimitiveExpression("Value")) } };
-                       yield return new object[] { new CodeTypeReference("System.Void"), new CodeAttributeArgument[] { new CodeAttributeArgument() } };
-               }
+        public static IEnumerable<object[]> Ctor_CodeTypeReference_TestData()
+        {
+            yield return new object[] { null, null };
+            yield return new object[] { new CodeTypeReference(typeof(int)), new CodeAttributeArgument[0] };
+            yield return new object[] { new CodeTypeReference("System.Void"), new CodeAttributeArgument[] { new CodeAttributeArgument("Name", new CodePrimitiveExpression("Value")) } };
+            yield return new object[] { new CodeTypeReference("System.Void"), new CodeAttributeArgument[] { new CodeAttributeArgument() } };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_CodeTypeReference_TestData))]
-               public void Ctor_CodeTypeReference(CodeTypeReference attributeType, CodeAttributeArgument[] arguments)
-               {
-                       if (arguments == null || arguments.Length == 0)
-                       {
-                               var declaration1 = new CodeAttributeDeclaration(attributeType);
-                               Assert.Equal(attributeType?.BaseType ?? string.Empty, declaration1.Name);
-                               Assert.Equal(attributeType, declaration1.AttributeType);
-                               Assert.Empty(declaration1.Arguments);
-                       }
-                       var declaration2 = new CodeAttributeDeclaration(attributeType, arguments);
-                       Assert.Equal(attributeType?.BaseType ?? string.Empty, declaration2.Name);
-                       Assert.Equal(attributeType, declaration2.AttributeType);
-                       Assert.Equal(arguments ?? new CodeAttributeArgument[0], declaration2.Arguments.Cast<CodeAttributeArgument>());
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_CodeTypeReference_TestData))]
+        public void Ctor_CodeTypeReference(CodeTypeReference attributeType, CodeAttributeArgument[] arguments)
+        {
+            if (arguments == null || arguments.Length == 0)
+            {
+                var declaration1 = new CodeAttributeDeclaration(attributeType);
+                Assert.Equal(attributeType?.BaseType ?? string.Empty, declaration1.Name);
+                Assert.Equal(attributeType, declaration1.AttributeType);
+                Assert.Empty(declaration1.Arguments);
+            }
+            var declaration2 = new CodeAttributeDeclaration(attributeType, arguments);
+            Assert.Equal(attributeType?.BaseType ?? string.Empty, declaration2.Name);
+            Assert.Equal(attributeType, declaration2.AttributeType);
+            Assert.Equal(arguments ?? new CodeAttributeArgument[0], declaration2.Arguments.Cast<CodeAttributeArgument>());
+        }
 
-               [Fact]
-               public void Ctor_NullArguments_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeAttributeDeclaration("name", null));
-               }
+        [Fact]
+        public void Ctor_NullArguments_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeAttributeDeclaration("name", null));
+        }
 
-               [Fact]
-               public void Ctor_NullObjectInArguments_ThrowsArgumentNullException()
-               {
-                       CodeAttributeArgument[] arguments = new CodeAttributeArgument[] { null };
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeAttributeDeclaration("name", arguments));
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeAttributeDeclaration(new CodeTypeReference(), arguments));
-               }
+        [Fact]
+        public void Ctor_NullObjectInArguments_ThrowsArgumentNullException()
+        {
+            CodeAttributeArgument[] arguments = new CodeAttributeArgument[] { null };
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeAttributeDeclaration("name", arguments));
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeAttributeDeclaration(new CodeTypeReference(), arguments));
+        }
 
-               [Theory]
-               [InlineData(null)]
-               [InlineData("")]
-               [InlineData("Name")]
-               public void Name_Set_Get_ReturnsExpected(string value)
-               {
-                       var declaration = new CodeAttributeDeclaration();
-                       declaration.Name = value;
-                       Assert.Equal(value ?? string.Empty, declaration.Name);
-               }
+        [Theory]
+        [InlineData(null)]
+        [InlineData("")]
+        [InlineData("Name")]
+        public void Name_Set_Get_ReturnsExpected(string value)
+        {
+            var declaration = new CodeAttributeDeclaration();
+            declaration.Name = value;
+            Assert.Equal(value ?? string.Empty, declaration.Name);
+        }
 
-               [Fact]
-               public void Arguments_AddMultiple_ReturnsExpected()
-               {
-                       var declaration = new CodeAttributeDeclaration();
+        [Fact]
+        public void Arguments_AddMultiple_ReturnsExpected()
+        {
+            var declaration = new CodeAttributeDeclaration();
 
-                       CodeAttributeArgument argument1 = new CodeAttributeArgument(new CodePrimitiveExpression("Value1"));
-                       declaration.Arguments.Add(argument1);
-                       Assert.Equal(new CodeAttributeArgument[] { argument1 }, declaration.Arguments.Cast<CodeAttributeArgument>());
+            CodeAttributeArgument argument1 = new CodeAttributeArgument(new CodePrimitiveExpression("Value1"));
+            declaration.Arguments.Add(argument1);
+            Assert.Equal(new CodeAttributeArgument[] { argument1 }, declaration.Arguments.Cast<CodeAttributeArgument>());
 
-                       CodeAttributeArgument argument2 = new CodeAttributeArgument(new CodePrimitiveExpression("Value2"));
-                       declaration.Arguments.Add(argument2);
-                       Assert.Equal(new CodeAttributeArgument[] { argument1, argument2 }, declaration.Arguments.Cast<CodeAttributeArgument>());
-               }
-       }
+            CodeAttributeArgument argument2 = new CodeAttributeArgument(new CodePrimitiveExpression("Value2"));
+            declaration.Arguments.Add(argument2);
+            Assert.Equal(new CodeAttributeArgument[] { argument1, argument2 }, declaration.Arguments.Cast<CodeAttributeArgument>());
+        }
+    }
 }
index afb79c1..fa21000 100644 (file)
@@ -7,63 +7,63 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeBinaryOperatorExpressionTests : CodeObjectTestBase<CodeBinaryOperatorExpression>
-       {
-               [Fact]
-               public void Ctor_HasNullLeftRightAndOperator()
-               {
-                       var binaryOperator = new CodeBinaryOperatorExpression();
-                       Assert.Null(binaryOperator.Left);
-                       Assert.Null(binaryOperator.Right);
-                       Assert.Equal(CodeBinaryOperatorType.Add, binaryOperator.Operator);
-               }
+    public class CodeBinaryOperatorExpressionTests : CodeObjectTestBase<CodeBinaryOperatorExpression>
+    {
+        [Fact]
+        public void Ctor_HasNullLeftRightAndOperator()
+        {
+            var binaryOperator = new CodeBinaryOperatorExpression();
+            Assert.Null(binaryOperator.Left);
+            Assert.Null(binaryOperator.Right);
+            Assert.Equal(CodeBinaryOperatorType.Add, binaryOperator.Operator);
+        }
 
-               public static IEnumerable<object[]> Ctor_TestData()
-               {
-                       yield return new object[] { null, (CodeBinaryOperatorType)(-1), null };
-                       yield return new object[] { new CodePrimitiveExpression("Value1"), CodeBinaryOperatorType.Add, null };
-                       yield return new object[] { null, CodeBinaryOperatorType.Add | CodeBinaryOperatorType.BitwiseAnd, new CodePrimitiveExpression("Value2") };
-                       yield return new object[] { new CodePrimitiveExpression("Value1"), (CodeBinaryOperatorType)int.MaxValue, new CodePrimitiveExpression("Value2") };
-               }
+        public static IEnumerable<object[]> Ctor_TestData()
+        {
+            yield return new object[] { null, (CodeBinaryOperatorType)(-1), null };
+            yield return new object[] { new CodePrimitiveExpression("Value1"), CodeBinaryOperatorType.Add, null };
+            yield return new object[] { null, CodeBinaryOperatorType.Add | CodeBinaryOperatorType.BitwiseAnd, new CodePrimitiveExpression("Value2") };
+            yield return new object[] { new CodePrimitiveExpression("Value1"), (CodeBinaryOperatorType)int.MaxValue, new CodePrimitiveExpression("Value2") };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TestData))]
-               public void Ctor_CodeExpression_CodeBinaryOperatorType_CodeExpression(CodeExpression left, CodeBinaryOperatorType operatorType, CodeExpression right)
-               {
-                       var binaryOperator = new CodeBinaryOperatorExpression(left, operatorType, right);
-                       Assert.Equal(left, binaryOperator.Left);
-                       Assert.Equal(operatorType, binaryOperator.Operator);
-                       Assert.Equal(right, binaryOperator.Right);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TestData))]
+        public void Ctor_CodeExpression_CodeBinaryOperatorType_CodeExpression(CodeExpression left, CodeBinaryOperatorType operatorType, CodeExpression right)
+        {
+            var binaryOperator = new CodeBinaryOperatorExpression(left, operatorType, right);
+            Assert.Equal(left, binaryOperator.Left);
+            Assert.Equal(operatorType, binaryOperator.Operator);
+            Assert.Equal(right, binaryOperator.Right);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Left_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var binaryOperator = new CodeBinaryOperatorExpression();
-                       binaryOperator.Left = value;
-                       Assert.Equal(value, binaryOperator.Left);
-               }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Left_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var binaryOperator = new CodeBinaryOperatorExpression();
+            binaryOperator.Left = value;
+            Assert.Equal(value, binaryOperator.Left);
+        }
 
-               [Theory]
-               [InlineData((CodeBinaryOperatorType)(-1))]
-               [InlineData(CodeBinaryOperatorType.Add)]
-               [InlineData(CodeBinaryOperatorType.Add | CodeBinaryOperatorType.BitwiseAnd)]
-               [InlineData((CodeBinaryOperatorType)int.MaxValue)]
-               public void Operator_Set_Get_ReturnsExpected(CodeBinaryOperatorType value)
-               {
-                       var binaryOperator = new CodeBinaryOperatorExpression();
-                       binaryOperator.Operator = value;
-                       Assert.Equal(value, binaryOperator.Operator);
-               }
+        [Theory]
+        [InlineData((CodeBinaryOperatorType)(-1))]
+        [InlineData(CodeBinaryOperatorType.Add)]
+        [InlineData(CodeBinaryOperatorType.Add | CodeBinaryOperatorType.BitwiseAnd)]
+        [InlineData((CodeBinaryOperatorType)int.MaxValue)]
+        public void Operator_Set_Get_ReturnsExpected(CodeBinaryOperatorType value)
+        {
+            var binaryOperator = new CodeBinaryOperatorExpression();
+            binaryOperator.Operator = value;
+            Assert.Equal(value, binaryOperator.Operator);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Right_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var binaryOperator = new CodeBinaryOperatorExpression();
-                       binaryOperator.Right = value;
-                       Assert.Equal(value, binaryOperator.Right);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Right_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var binaryOperator = new CodeBinaryOperatorExpression();
+            binaryOperator.Right = value;
+            Assert.Equal(value, binaryOperator.Right);
+        }
+    }
 }
index 4a4528e..ab166fe 100644 (file)
@@ -7,81 +7,81 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeCastExpressionTests : CodeObjectTestBase<CodeCastExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var cast = new CodeCastExpression();
-                       Assert.Equal(typeof(void).FullName, cast.TargetType.BaseType);
-                       Assert.Null(cast.Expression);
-               }
+    public class CodeCastExpressionTests : CodeObjectTestBase<CodeCastExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var cast = new CodeCastExpression();
+            Assert.Equal(typeof(void).FullName, cast.TargetType.BaseType);
+            Assert.Null(cast.Expression);
+        }
 
-               public static IEnumerable<object[]> Ctor_CodeTypeReference_TestData()
-               {
-                       yield return new object[] { null, null };
-                       yield return new object[] { new CodeTypeReference(), new CodePrimitiveExpression() };
-                       yield return new object[] { new CodeTypeReference(typeof(void)), new CodePrimitiveExpression("Value") };
-               }
+        public static IEnumerable<object[]> Ctor_CodeTypeReference_TestData()
+        {
+            yield return new object[] { null, null };
+            yield return new object[] { new CodeTypeReference(), new CodePrimitiveExpression() };
+            yield return new object[] { new CodeTypeReference(typeof(void)), new CodePrimitiveExpression("Value") };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_CodeTypeReference_TestData))]
-               public void Ctor_CodeTypeReference_CodeExpression(CodeTypeReference type, CodeExpression expression)
-               {
-                       CodeExpression[] initializers = new CodeExpression[0];
-                       var cast = new CodeCastExpression(type, expression);
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, cast.TargetType.BaseType);
-                       Assert.Equal(expression, cast.Expression);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_CodeTypeReference_TestData))]
+        public void Ctor_CodeTypeReference_CodeExpression(CodeTypeReference type, CodeExpression expression)
+        {
+            CodeExpression[] initializers = new CodeExpression[0];
+            var cast = new CodeCastExpression(type, expression);
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, cast.TargetType.BaseType);
+            Assert.Equal(expression, cast.Expression);
+        }
 
-               public static IEnumerable<object[]> Ctor_TypeString_TestData()
-               {
-                       yield return new object[] { null, null, "System.Void" };
-                       yield return new object[] { "", new CodePrimitiveExpression(), "System.Void" };
-                       yield return new object[] { "Int32", new CodePrimitiveExpression("Value"), "Int32" };
-               }
+        public static IEnumerable<object[]> Ctor_TypeString_TestData()
+        {
+            yield return new object[] { null, null, "System.Void" };
+            yield return new object[] { "", new CodePrimitiveExpression(), "System.Void" };
+            yield return new object[] { "Int32", new CodePrimitiveExpression("Value"), "Int32" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TypeString_TestData))]
-               public void Ctor_String_CodeExpression(string type, CodeExpression expression, string expectedBaseType)
-               {
-                       var cast = new CodeCastExpression(type, expression);
-                       Assert.Equal(expectedBaseType, cast.TargetType.BaseType);
-                       Assert.Equal(expression, cast.Expression);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TypeString_TestData))]
+        public void Ctor_String_CodeExpression(string type, CodeExpression expression, string expectedBaseType)
+        {
+            var cast = new CodeCastExpression(type, expression);
+            Assert.Equal(expectedBaseType, cast.TargetType.BaseType);
+            Assert.Equal(expression, cast.Expression);
+        }
 
-               public static IEnumerable<object[]> Ctor_Type_TestData()
-               {
-                       yield return new object[] { typeof(int), null, "System.Int32" };
-                       yield return new object[] { typeof(List<>), new CodePrimitiveExpression(), "System.Collections.Generic.List`1" };
-                       yield return new object[] { typeof(void), new CodePrimitiveExpression("Value"), "System.Void" };
-               }
+        public static IEnumerable<object[]> Ctor_Type_TestData()
+        {
+            yield return new object[] { typeof(int), null, "System.Int32" };
+            yield return new object[] { typeof(List<>), new CodePrimitiveExpression(), "System.Collections.Generic.List`1" };
+            yield return new object[] { typeof(void), new CodePrimitiveExpression("Value"), "System.Void" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_Type_TestData))]
-               public void Ctor_Type_CodeExpression(Type type, CodeExpression expression, string expectedBaseType)
-               {
-                       var cast = new CodeCastExpression(type, expression);
-                       Assert.Equal(expectedBaseType, cast.TargetType.BaseType);
-                       Assert.Equal(expression, cast.Expression);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_Type_TestData))]
+        public void Ctor_Type_CodeExpression(Type type, CodeExpression expression, string expectedBaseType)
+        {
+            var cast = new CodeCastExpression(type, expression);
+            Assert.Equal(expectedBaseType, cast.TargetType.BaseType);
+            Assert.Equal(expression, cast.Expression);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void TargetType_Set_Get_ReturnsExpected(CodeTypeReference value)
-               {
-                       var cast = new CodeCastExpression();
-                       cast.TargetType = value;
-                       Assert.Equal((value ?? new CodeTypeReference("")).BaseType, cast.TargetType.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void TargetType_Set_Get_ReturnsExpected(CodeTypeReference value)
+        {
+            var cast = new CodeCastExpression();
+            cast.TargetType = value;
+            Assert.Equal((value ?? new CodeTypeReference("")).BaseType, cast.TargetType.BaseType);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Expression_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var cast = new CodeCastExpression();
-                       cast.Expression = value;
-                       Assert.Equal(value, cast.Expression);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Expression_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var cast = new CodeCastExpression();
+            cast.Expression = value;
+            Assert.Equal(value, cast.Expression);
+        }
+    }
 }
index 7dbdb56..a32ce27 100644 (file)
@@ -8,105 +8,105 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeCatchClauseTests : CodeDomTestBase
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var catchClause = new CodeCatchClause();
-                       Assert.Empty(catchClause.LocalName);
-                       Assert.Empty(catchClause.Statements);
+    public class CodeCatchClauseTests : CodeDomTestBase
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var catchClause = new CodeCatchClause();
+            Assert.Empty(catchClause.LocalName);
+            Assert.Empty(catchClause.Statements);
 
-                       Assert.Equal(new CodeTypeReference(typeof(Exception)).BaseType, catchClause.CatchExceptionType.BaseType);
-               }
+            Assert.Equal(new CodeTypeReference(typeof(Exception)).BaseType, catchClause.CatchExceptionType.BaseType);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Ctor_String(string localName)
-               {
-                       var catchClause = new CodeCatchClause(localName);
-                       Assert.Equal(localName ?? string.Empty, catchClause.LocalName);
-                       Assert.Equal(typeof(Exception).ToString(), catchClause.CatchExceptionType.BaseType);
-                       Assert.Empty(catchClause.Statements);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Ctor_String(string localName)
+        {
+            var catchClause = new CodeCatchClause(localName);
+            Assert.Equal(localName ?? string.Empty, catchClause.LocalName);
+            Assert.Equal(typeof(Exception).ToString(), catchClause.CatchExceptionType.BaseType);
+            Assert.Empty(catchClause.Statements);
+        }
 
-               public static IEnumerable<object[]> Ctor_String_CodeTypeReference_TestData()
-               {
-                       yield return new object[] { null, null };
-                       yield return new object[] { "", new CodeTypeReference() };
-                       yield return new object[] { "Value1", new CodeTypeReference(typeof(ArgumentException)) };
-               }
+        public static IEnumerable<object[]> Ctor_String_CodeTypeReference_TestData()
+        {
+            yield return new object[] { null, null };
+            yield return new object[] { "", new CodeTypeReference() };
+            yield return new object[] { "Value1", new CodeTypeReference(typeof(ArgumentException)) };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_String_CodeTypeReference_TestData))]
-               public void Ctor_String_CodeTypeReference(string localName, CodeTypeReference catchExceptionType)
-               {
-                       var catchClause = new CodeCatchClause(localName, catchExceptionType);
-                       Assert.Equal(localName ?? string.Empty, catchClause.LocalName);
-                       Assert.Equal((catchExceptionType ?? new CodeTypeReference(typeof(Exception))).BaseType, catchClause.CatchExceptionType.BaseType);
-                       Assert.Empty(catchClause.Statements);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_String_CodeTypeReference_TestData))]
+        public void Ctor_String_CodeTypeReference(string localName, CodeTypeReference catchExceptionType)
+        {
+            var catchClause = new CodeCatchClause(localName, catchExceptionType);
+            Assert.Equal(localName ?? string.Empty, catchClause.LocalName);
+            Assert.Equal((catchExceptionType ?? new CodeTypeReference(typeof(Exception))).BaseType, catchClause.CatchExceptionType.BaseType);
+            Assert.Empty(catchClause.Statements);
+        }
 
-               public static IEnumerable<object[]> Ctor_String_CodeTypeReference_ParamsCodeStatement_TestData()
-               {
-                       yield return new object[] { null, null, new CodeStatement[0] };
-                       yield return new object[] { "", new CodeTypeReference(), new CodeStatement[] { new CodeCommentStatement("") } };
-                       yield return new object[] { "Value1", new CodeTypeReference(typeof(ArgumentException)), new CodeStatement[] { new CodeCommentStatement("") } };
-               }
+        public static IEnumerable<object[]> Ctor_String_CodeTypeReference_ParamsCodeStatement_TestData()
+        {
+            yield return new object[] { null, null, new CodeStatement[0] };
+            yield return new object[] { "", new CodeTypeReference(), new CodeStatement[] { new CodeCommentStatement("") } };
+            yield return new object[] { "Value1", new CodeTypeReference(typeof(ArgumentException)), new CodeStatement[] { new CodeCommentStatement("") } };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_String_CodeTypeReference_ParamsCodeStatement_TestData))]
-               public void Ctor_String_CodeTypeReference_ParamsCodeStatement(string localName, CodeTypeReference catchExceptionType, CodeStatement[] statements)
-               {
-                       var catchClause = new CodeCatchClause(localName, catchExceptionType, statements);
-                       Assert.Equal(localName ?? string.Empty, catchClause.LocalName);
-                       Assert.Equal((catchExceptionType ?? new CodeTypeReference(typeof(Exception))).BaseType, catchClause.CatchExceptionType.BaseType);
-                       Assert.Equal(statements, catchClause.Statements.Cast<CodeStatement>());
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_String_CodeTypeReference_ParamsCodeStatement_TestData))]
+        public void Ctor_String_CodeTypeReference_ParamsCodeStatement(string localName, CodeTypeReference catchExceptionType, CodeStatement[] statements)
+        {
+            var catchClause = new CodeCatchClause(localName, catchExceptionType, statements);
+            Assert.Equal(localName ?? string.Empty, catchClause.LocalName);
+            Assert.Equal((catchExceptionType ?? new CodeTypeReference(typeof(Exception))).BaseType, catchClause.CatchExceptionType.BaseType);
+            Assert.Equal(statements, catchClause.Statements.Cast<CodeStatement>());
+        }
 
-               [Fact]
-               public void Ctor_NullStatements_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeCatchClause("name", new CodeTypeReference(typeof(void)), null));
-               }
+        [Fact]
+        public void Ctor_NullStatements_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeCatchClause("name", new CodeTypeReference(typeof(void)), null));
+        }
 
-               [Fact]
-               public void Ctor_NullObjectInStatements_ThrowsArgumentNullException()
-               {
-                       CodeStatement[] statements = new CodeStatement[] { null };
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeCatchClause("name", new CodeTypeReference(typeof(void)), statements));
-               }
+        [Fact]
+        public void Ctor_NullObjectInStatements_ThrowsArgumentNullException()
+        {
+            CodeStatement[] statements = new CodeStatement[] { null };
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeCatchClause("name", new CodeTypeReference(typeof(void)), statements));
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void LocalName_Set_Get_ReturnsExpected(string value)
-               {
-                       var catchClause = new CodeCatchClause();
-                       catchClause.LocalName = value;
-                       Assert.Equal(value ?? string.Empty, catchClause.LocalName);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void LocalName_Set_Get_ReturnsExpected(string value)
+        {
+            var catchClause = new CodeCatchClause();
+            catchClause.LocalName = value;
+            Assert.Equal(value ?? string.Empty, catchClause.LocalName);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void CatchExceptionType_Set_Get_ReturnsExpected(CodeTypeReference value)
-               {
-                       var catchClause = new CodeCatchClause();
-                       catchClause.CatchExceptionType = value;
-                       Assert.Equal((value ?? new CodeTypeReference(typeof(Exception))).BaseType, catchClause.CatchExceptionType.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void CatchExceptionType_Set_Get_ReturnsExpected(CodeTypeReference value)
+        {
+            var catchClause = new CodeCatchClause();
+            catchClause.CatchExceptionType = value;
+            Assert.Equal((value ?? new CodeTypeReference(typeof(Exception))).BaseType, catchClause.CatchExceptionType.BaseType);
+        }
 
-               [Fact]
-               public void Statements_AddMultiple_ReturnsExpected()
-               {
-                       var catchClause = new CodeCatchClause();
+        [Fact]
+        public void Statements_AddMultiple_ReturnsExpected()
+        {
+            var catchClause = new CodeCatchClause();
 
-                       CodeStatement statement1 = new CodeCommentStatement("Value1");
-                       catchClause.Statements.Add(statement1);
-                       Assert.Equal(new CodeStatement[] { statement1 }, catchClause.Statements.Cast<CodeStatement>());
+            CodeStatement statement1 = new CodeCommentStatement("Value1");
+            catchClause.Statements.Add(statement1);
+            Assert.Equal(new CodeStatement[] { statement1 }, catchClause.Statements.Cast<CodeStatement>());
 
-                       CodeStatement statement2 = new CodeCommentStatement("Value1");
-                       catchClause.Statements.Add(statement2);
-                       Assert.Equal(new CodeStatement[] { statement1, statement2 }, catchClause.Statements.Cast<CodeStatement>());
-               }
-       }
+            CodeStatement statement2 = new CodeCommentStatement("Value1");
+            catchClause.Statements.Add(statement2);
+            Assert.Equal(new CodeStatement[] { statement1, statement2 }, catchClause.Statements.Cast<CodeStatement>());
+        }
+    }
 }
index ac7326b..f19fc47 100644 (file)
@@ -7,67 +7,67 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeChecksumPragmaTests : CodeObjectTestBase<CodeChecksumPragma>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var pragma = new CodeChecksumPragma();
-                       Assert.Empty(pragma.FileName);
-                       Assert.Equal(Guid.Empty, pragma.ChecksumAlgorithmId);
-                       Assert.Null(pragma.ChecksumData);
-               }
+    public class CodeChecksumPragmaTests : CodeObjectTestBase<CodeChecksumPragma>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var pragma = new CodeChecksumPragma();
+            Assert.Empty(pragma.FileName);
+            Assert.Equal(Guid.Empty, pragma.ChecksumAlgorithmId);
+            Assert.Null(pragma.ChecksumData);
+        }
 
-               public static IEnumerable<object[]> Ctor_TestData()
-               {
-                       yield return new object[] { null, new Guid(), null };
-                       yield return new object[] { "", Guid.NewGuid(), new byte[0] };
-                       yield return new object[] { "Value1", Guid.NewGuid(), new byte[] { 0, 1, 2, 3 } };
-               }
+        public static IEnumerable<object[]> Ctor_TestData()
+        {
+            yield return new object[] { null, new Guid(), null };
+            yield return new object[] { "", Guid.NewGuid(), new byte[0] };
+            yield return new object[] { "Value1", Guid.NewGuid(), new byte[] { 0, 1, 2, 3 } };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TestData))]
-               public void Ctor(string fileName, Guid algorithmId, byte[] checksumData)
-               {
-                       var pragma = new CodeChecksumPragma(fileName, algorithmId, checksumData);
-                       Assert.Equal(fileName ?? string.Empty, pragma.FileName);
-                       Assert.Equal(algorithmId, pragma.ChecksumAlgorithmId);
-                       Assert.Equal(checksumData, pragma.ChecksumData);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TestData))]
+        public void Ctor(string fileName, Guid algorithmId, byte[] checksumData)
+        {
+            var pragma = new CodeChecksumPragma(fileName, algorithmId, checksumData);
+            Assert.Equal(fileName ?? string.Empty, pragma.FileName);
+            Assert.Equal(algorithmId, pragma.ChecksumAlgorithmId);
+            Assert.Equal(checksumData, pragma.ChecksumData);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void FileName_Set_Get_ReturnsExpected(string value)
-               {
-                       var pragma = new CodeChecksumPragma();
-                       pragma.FileName = value;
-                       Assert.Equal(value ?? string.Empty, pragma.FileName);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void FileName_Set_Get_ReturnsExpected(string value)
+        {
+            var pragma = new CodeChecksumPragma();
+            pragma.FileName = value;
+            Assert.Equal(value ?? string.Empty, pragma.FileName);
+        }
 
-               public static IEnumerable<object[]> Guid_TestData()
-               {
-                       yield return new object[] { new Guid() };
-                       yield return new object[] { Guid.NewGuid() };
-               }
+        public static IEnumerable<object[]> Guid_TestData()
+        {
+            yield return new object[] { new Guid() };
+            yield return new object[] { Guid.NewGuid() };
+        }
 
-               [Theory]
-               [MemberData(nameof(Guid_TestData))]
-               public void AlgorithmId_Set_Get_ReturnsExpected(Guid value)
-               {
-                       var pragma = new CodeChecksumPragma();
-                       pragma.ChecksumAlgorithmId = value;
-                       Assert.Equal(value, pragma.ChecksumAlgorithmId);
-               }
+        [Theory]
+        [MemberData(nameof(Guid_TestData))]
+        public void AlgorithmId_Set_Get_ReturnsExpected(Guid value)
+        {
+            var pragma = new CodeChecksumPragma();
+            pragma.ChecksumAlgorithmId = value;
+            Assert.Equal(value, pragma.ChecksumAlgorithmId);
+        }
 
-               [Theory]
-               [InlineData(null)]
-               [InlineData(new byte[0])]
-               [InlineData(new byte[] { 0, 1, 2, 3 })]
-               public void ChecksumData_Set_Get_ReturnsExpected(byte[] value)
-               {
-                       var pragma = new CodeChecksumPragma();
-                       pragma.ChecksumData = value;
-                       Assert.Equal(value, pragma.ChecksumData);
-               }
-       }
+        [Theory]
+        [InlineData(null)]
+        [InlineData(new byte[0])]
+        [InlineData(new byte[] { 0, 1, 2, 3 })]
+        public void ChecksumData_Set_Get_ReturnsExpected(byte[] value)
+        {
+            var pragma = new CodeChecksumPragma();
+            pragma.ChecksumData = value;
+            Assert.Equal(value, pragma.ChecksumData);
+        }
+    }
 }
index 1a8a1f4..a4f23b3 100644 (file)
@@ -7,73 +7,73 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeCommentStatementTests : CodeStatementTestBase<CodeCommentStatement>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var comment = new CodeCommentStatement();
-                       Assert.Null(comment.Comment);
-               }
+    public class CodeCommentStatementTests : CodeStatementTestBase<CodeCommentStatement>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var comment = new CodeCommentStatement();
+            Assert.Null(comment.Comment);
+        }
 
-               public static IEnumerable<object[]> Comment_TestData()
-               {
-                       yield return new object[] { null, false };
-                       yield return new object[] { "", true };
-                       yield return new object[] { "Text", false };
-                       yield return new object[] { "text", true };
-               }
+        public static IEnumerable<object[]> Comment_TestData()
+        {
+            yield return new object[] { null, false };
+            yield return new object[] { "", true };
+            yield return new object[] { "Text", false };
+            yield return new object[] { "text", true };
+        }
 
-               [Theory]
-               [MemberData(nameof(Comment_TestData))]
-               public void Ctor_String(string text, bool docComment)
-               {
-                       CodeCommentStatement comment = new CodeCommentStatement(text);
-                       Assert.Equal(text ?? string.Empty, comment.Comment.Text);
-                       Assert.False(comment.Comment.DocComment);
-               }
+        [Theory]
+        [MemberData(nameof(Comment_TestData))]
+        public void Ctor_String(string text, bool docComment)
+        {
+            CodeCommentStatement comment = new CodeCommentStatement(text);
+            Assert.Equal(text ?? string.Empty, comment.Comment.Text);
+            Assert.False(comment.Comment.DocComment);
+        }
 
-               [Theory]
-               [MemberData(nameof(Comment_TestData))]
-               public void Ctor_String_Bool(string text, bool docComment)
-               {
-                       CodeCommentStatement comment = new CodeCommentStatement(text, docComment);
-                       Assert.Equal(text ?? string.Empty, comment.Comment.Text);
-                       Assert.Equal(docComment, comment.Comment.DocComment);
-               }
+        [Theory]
+        [MemberData(nameof(Comment_TestData))]
+        public void Ctor_String_Bool(string text, bool docComment)
+        {
+            CodeCommentStatement comment = new CodeCommentStatement(text, docComment);
+            Assert.Equal(text ?? string.Empty, comment.Comment.Text);
+            Assert.Equal(docComment, comment.Comment.DocComment);
+        }
 
-               [Theory]
-               [MemberData(nameof(Comment_TestData))]
-               public void Ctor_CodeComment(string text, bool docComment)
-               {
-                       CodeComment codeComment = new CodeComment(text, docComment);
-                       CodeCommentStatement comment = new CodeCommentStatement(codeComment);
-                       Assert.Same(codeComment, comment.Comment);
-               }
+        [Theory]
+        [MemberData(nameof(Comment_TestData))]
+        public void Ctor_CodeComment(string text, bool docComment)
+        {
+            CodeComment codeComment = new CodeComment(text, docComment);
+            CodeCommentStatement comment = new CodeCommentStatement(codeComment);
+            Assert.Same(codeComment, comment.Comment);
+        }
 
-               [Fact]
-               public void Ctor_CodeComment_Null()
-               {
-                       CodeCommentStatement comment = new CodeCommentStatement((CodeComment)null);
-                       Assert.Null(comment.Comment);
-               }
+        [Fact]
+        public void Ctor_CodeComment_Null()
+        {
+            CodeCommentStatement comment = new CodeCommentStatement((CodeComment)null);
+            Assert.Null(comment.Comment);
+        }
 
-               [Theory]
-               [MemberData(nameof(Comment_TestData))]
-               public void Comment_Set_Get_ReturnsExpected(string text, bool docComment)
-               {
-                       CodeComment codeComment = new CodeComment(text, docComment);
-                       CodeCommentStatement comment = new CodeCommentStatement();
-                       comment.Comment = codeComment;
-                       Assert.Same(codeComment, comment.Comment);
-               }
+        [Theory]
+        [MemberData(nameof(Comment_TestData))]
+        public void Comment_Set_Get_ReturnsExpected(string text, bool docComment)
+        {
+            CodeComment codeComment = new CodeComment(text, docComment);
+            CodeCommentStatement comment = new CodeCommentStatement();
+            comment.Comment = codeComment;
+            Assert.Same(codeComment, comment.Comment);
+        }
 
-               [Fact]
-               public void Ctor_SetNull_Get_ReturnsNull()
-               {
-                       CodeCommentStatement comment = new CodeCommentStatement();
-                       comment.Comment = null;
-                       Assert.Null(comment.Comment);
-               }
-       }
+        [Fact]
+        public void Ctor_SetNull_Get_ReturnsNull()
+        {
+            CodeCommentStatement comment = new CodeCommentStatement();
+            comment.Comment = null;
+            Assert.Null(comment.Comment);
+        }
+    }
 }
index b66937d..a392280 100644 (file)
@@ -7,58 +7,58 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeCommentTests : CodeObjectTestBase<CodeComment>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var comment = new CodeComment();
-                       Assert.Empty(comment.Text);
-                       Assert.False(comment.DocComment);
-               }
+    public class CodeCommentTests : CodeObjectTestBase<CodeComment>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var comment = new CodeComment();
+            Assert.Empty(comment.Text);
+            Assert.False(comment.DocComment);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Ctor_String(string text)
-               {
-                       var comment = new CodeComment(text);
-                       Assert.Equal(text ?? string.Empty, comment.Text);
-                       Assert.False(comment.DocComment);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Ctor_String(string text)
+        {
+            var comment = new CodeComment(text);
+            Assert.Equal(text ?? string.Empty, comment.Text);
+            Assert.False(comment.DocComment);
+        }
 
-               public static IEnumerable<object[]> Ctor_String_Bool_TestData()
-               {
-                       yield return new object[] { null, true };
-                       yield return new object[] { "", false };
-                       yield return new object[] { "Value", true };
-               }
+        public static IEnumerable<object[]> Ctor_String_Bool_TestData()
+        {
+            yield return new object[] { null, true };
+            yield return new object[] { "", false };
+            yield return new object[] { "Value", true };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_String_Bool_TestData))]
-               public void Ctor_String_Bool(string text, bool docComment)
-               {
-                       var comment = new CodeComment(text, docComment);
-                       Assert.Equal(text ?? string.Empty, comment.Text);
-                       Assert.Equal(docComment, comment.DocComment);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_String_Bool_TestData))]
+        public void Ctor_String_Bool(string text, bool docComment)
+        {
+            var comment = new CodeComment(text, docComment);
+            Assert.Equal(text ?? string.Empty, comment.Text);
+            Assert.Equal(docComment, comment.DocComment);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Text_Set_Get_ReturnsExpected(string value)
-               {
-                       var comment = new CodeComment();
-                       comment.Text = value;
-                       Assert.Equal(value ?? string.Empty, comment.Text);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Text_Set_Get_ReturnsExpected(string value)
+        {
+            var comment = new CodeComment();
+            comment.Text = value;
+            Assert.Equal(value ?? string.Empty, comment.Text);
+        }
 
-               [Theory]
-               [InlineData(true)]
-               [InlineData(false)]
-               public void DocComment_Set_Get_ReturnsExpected(bool value)
-               {
-                       var comment = new CodeComment();
-                       comment.DocComment = value;
-                       Assert.Equal(value, comment.DocComment);
-               }
-       }
+        [Theory]
+        [InlineData(true)]
+        [InlineData(false)]
+        public void DocComment_Set_Get_ReturnsExpected(bool value)
+        {
+            var comment = new CodeComment();
+            comment.DocComment = value;
+            Assert.Equal(value, comment.DocComment);
+        }
+    }
 }
index 83027c4..7760852 100644 (file)
@@ -7,87 +7,87 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeCompileUnitTests : CodeObjectTestBase<CodeCompileUnit>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var compileUnit = new CodeCompileUnit();
-                       Assert.Empty(compileUnit.Namespaces);
-                       Assert.Empty(compileUnit.ReferencedAssemblies);
-                       Assert.Empty(compileUnit.AssemblyCustomAttributes);
-                       Assert.Empty(compileUnit.StartDirectives);
-                       Assert.Empty(compileUnit.EndDirectives);
-               }
-
-               [Fact]
-               public void Namespaces_AddMultiple_ReturnsExpected()
-               {
-                       var compileUnit = new CodeCompileUnit();
-
-                       CodeNamespace namespace1 = new CodeNamespace("Name1");
-                       compileUnit.Namespaces.Add(namespace1);
-                       Assert.Equal(new CodeNamespace[] { namespace1 }, compileUnit.Namespaces.Cast<CodeNamespace>());
-
-                       CodeNamespace namespace2 = new CodeNamespace("Name2");
-                       compileUnit.Namespaces.Add(namespace2);
-                       Assert.Equal(new CodeNamespace[] { namespace1, namespace2 }, compileUnit.Namespaces.Cast<CodeNamespace>());
-               }
-
-               [Fact]
-               public void ReferencedAssemblies_AddMultiple_ReturnsExpected()
-               {
-                       var compileUnit = new CodeCompileUnit();
-
-                       string assembly1 = "Name1";
-                       compileUnit.ReferencedAssemblies.Add(assembly1);
-                       Assert.Equal(new string[] { assembly1 }, compileUnit.ReferencedAssemblies.Cast<string>());
-
-                       string assembly2 = "Name2";
-                       compileUnit.ReferencedAssemblies.Add(assembly2);
-                       Assert.Equal(new string[] { assembly1, assembly2 }, compileUnit.ReferencedAssemblies.Cast<string>());
-               }
-
-               [Fact]
-               public void CustomAttributes_AddMultiple_ReturnsExpected()
-               {
-                       var compileUnit = new CodeCompileUnit();
-
-                       CodeAttributeDeclaration attribute1 = new CodeAttributeDeclaration("Name1");
-                       compileUnit.AssemblyCustomAttributes.Add(attribute1);
-                       Assert.Equal(new CodeAttributeDeclaration[] { attribute1 }, compileUnit.AssemblyCustomAttributes.Cast<CodeAttributeDeclaration>());
-
-                       CodeAttributeDeclaration attribute2 = new CodeAttributeDeclaration("Name2");
-                       compileUnit.AssemblyCustomAttributes.Add(attribute2);
-                       Assert.Equal(new CodeAttributeDeclaration[] { attribute1, attribute2 }, compileUnit.AssemblyCustomAttributes.Cast<CodeAttributeDeclaration>());
-               }
-
-               [Fact]
-               public void StartDirectives_AddMultiple_ReturnsExpected()
-               {
-                       var compileUnit = new CodeCompileUnit();
-
-                       CodeRegionDirective directive1 = new CodeRegionDirective(CodeRegionMode.None, "Region1");
-                       compileUnit.StartDirectives.Add(directive1);
-                       Assert.Equal(new CodeRegionDirective[] { directive1 }, compileUnit.StartDirectives.Cast<CodeDirective>());
-
-                       CodeRegionDirective directive2 = new CodeRegionDirective(CodeRegionMode.None, "Region2");
-                       compileUnit.StartDirectives.Add(directive2);
-                       Assert.Equal(new CodeRegionDirective[] { directive1, directive2 }, compileUnit.StartDirectives.Cast<CodeDirective>());
-               }
-
-               [Fact]
-               public void EndDirectives_AddMultiple_ReturnsExpected()
-               {
-                       var compileUnit = new CodeCompileUnit();
-
-                       CodeRegionDirective directive1 = new CodeRegionDirective(CodeRegionMode.None, "Region1");
-                       compileUnit.EndDirectives.Add(directive1);
-                       Assert.Equal(new CodeRegionDirective[] { directive1 }, compileUnit.EndDirectives.Cast<CodeDirective>());
-
-                       CodeRegionDirective directive2 = new CodeRegionDirective(CodeRegionMode.None, "Region2");
-                       compileUnit.EndDirectives.Add(directive2);
-                       Assert.Equal(new CodeRegionDirective[] { directive1, directive2 }, compileUnit.EndDirectives.Cast<CodeDirective>());
-               }
-       }
+    public class CodeCompileUnitTests : CodeObjectTestBase<CodeCompileUnit>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var compileUnit = new CodeCompileUnit();
+            Assert.Empty(compileUnit.Namespaces);
+            Assert.Empty(compileUnit.ReferencedAssemblies);
+            Assert.Empty(compileUnit.AssemblyCustomAttributes);
+            Assert.Empty(compileUnit.StartDirectives);
+            Assert.Empty(compileUnit.EndDirectives);
+        }
+
+        [Fact]
+        public void Namespaces_AddMultiple_ReturnsExpected()
+        {
+            var compileUnit = new CodeCompileUnit();
+
+            CodeNamespace namespace1 = new CodeNamespace("Name1");
+            compileUnit.Namespaces.Add(namespace1);
+            Assert.Equal(new CodeNamespace[] { namespace1 }, compileUnit.Namespaces.Cast<CodeNamespace>());
+
+            CodeNamespace namespace2 = new CodeNamespace("Name2");
+            compileUnit.Namespaces.Add(namespace2);
+            Assert.Equal(new CodeNamespace[] { namespace1, namespace2 }, compileUnit.Namespaces.Cast<CodeNamespace>());
+        }
+
+        [Fact]
+        public void ReferencedAssemblies_AddMultiple_ReturnsExpected()
+        {
+            var compileUnit = new CodeCompileUnit();
+
+            string assembly1 = "Name1";
+            compileUnit.ReferencedAssemblies.Add(assembly1);
+            Assert.Equal(new string[] { assembly1 }, compileUnit.ReferencedAssemblies.Cast<string>());
+
+            string assembly2 = "Name2";
+            compileUnit.ReferencedAssemblies.Add(assembly2);
+            Assert.Equal(new string[] { assembly1, assembly2 }, compileUnit.ReferencedAssemblies.Cast<string>());
+        }
+
+        [Fact]
+        public void CustomAttributes_AddMultiple_ReturnsExpected()
+        {
+            var compileUnit = new CodeCompileUnit();
+
+            CodeAttributeDeclaration attribute1 = new CodeAttributeDeclaration("Name1");
+            compileUnit.AssemblyCustomAttributes.Add(attribute1);
+            Assert.Equal(new CodeAttributeDeclaration[] { attribute1 }, compileUnit.AssemblyCustomAttributes.Cast<CodeAttributeDeclaration>());
+
+            CodeAttributeDeclaration attribute2 = new CodeAttributeDeclaration("Name2");
+            compileUnit.AssemblyCustomAttributes.Add(attribute2);
+            Assert.Equal(new CodeAttributeDeclaration[] { attribute1, attribute2 }, compileUnit.AssemblyCustomAttributes.Cast<CodeAttributeDeclaration>());
+        }
+
+        [Fact]
+        public void StartDirectives_AddMultiple_ReturnsExpected()
+        {
+            var compileUnit = new CodeCompileUnit();
+
+            CodeRegionDirective directive1 = new CodeRegionDirective(CodeRegionMode.None, "Region1");
+            compileUnit.StartDirectives.Add(directive1);
+            Assert.Equal(new CodeRegionDirective[] { directive1 }, compileUnit.StartDirectives.Cast<CodeDirective>());
+
+            CodeRegionDirective directive2 = new CodeRegionDirective(CodeRegionMode.None, "Region2");
+            compileUnit.StartDirectives.Add(directive2);
+            Assert.Equal(new CodeRegionDirective[] { directive1, directive2 }, compileUnit.StartDirectives.Cast<CodeDirective>());
+        }
+
+        [Fact]
+        public void EndDirectives_AddMultiple_ReturnsExpected()
+        {
+            var compileUnit = new CodeCompileUnit();
+
+            CodeRegionDirective directive1 = new CodeRegionDirective(CodeRegionMode.None, "Region1");
+            compileUnit.EndDirectives.Add(directive1);
+            Assert.Equal(new CodeRegionDirective[] { directive1 }, compileUnit.EndDirectives.Cast<CodeDirective>());
+
+            CodeRegionDirective directive2 = new CodeRegionDirective(CodeRegionMode.None, "Region2");
+            compileUnit.EndDirectives.Add(directive2);
+            Assert.Equal(new CodeRegionDirective[] { directive1, directive2 }, compileUnit.EndDirectives.Cast<CodeDirective>());
+        }
+    }
 }
index 2df722c..6f9a270 100644 (file)
@@ -8,87 +8,87 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeConditionStatementTests : CodeStatementTestBase<CodeConditionStatement>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var condition = new CodeConditionStatement();
-                       Assert.Null(condition.Condition);
-                       Assert.Empty(condition.TrueStatements);
-                       Assert.Empty(condition.FalseStatements);
-               }
+    public class CodeConditionStatementTests : CodeStatementTestBase<CodeConditionStatement>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var condition = new CodeConditionStatement();
+            Assert.Null(condition.Condition);
+            Assert.Empty(condition.TrueStatements);
+            Assert.Empty(condition.FalseStatements);
+        }
 
-               public static IEnumerable<object[]> Ctor_TestData()
-               {
-                       yield return new object[] { null, new CodeStatement[0], new CodeStatement[0] };
-                       yield return new object[] { new CodePrimitiveExpression("Value1"), new CodeStatement[] { new CodeCommentStatement("Value2") }, new CodeStatement[0] };
-                       yield return new object[] { new CodePrimitiveExpression("Value1"), new CodeStatement[] { new CodeCommentStatement("Value2") }, new CodeStatement[] { new CodeCommentStatement("Value3") } };
-                       yield return new object[] { new CodePrimitiveExpression("Value1"), new CodeStatement[0], new CodeStatement[] { new CodeCommentStatement("Value3") } };
-               }
+        public static IEnumerable<object[]> Ctor_TestData()
+        {
+            yield return new object[] { null, new CodeStatement[0], new CodeStatement[0] };
+            yield return new object[] { new CodePrimitiveExpression("Value1"), new CodeStatement[] { new CodeCommentStatement("Value2") }, new CodeStatement[0] };
+            yield return new object[] { new CodePrimitiveExpression("Value1"), new CodeStatement[] { new CodeCommentStatement("Value2") }, new CodeStatement[] { new CodeCommentStatement("Value3") } };
+            yield return new object[] { new CodePrimitiveExpression("Value1"), new CodeStatement[0], new CodeStatement[] { new CodeCommentStatement("Value3") } };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TestData))]
-               public void Ctor(CodeExpression expression, CodeStatement[] trueStatements, CodeStatement[] falseStatements)
-               {
-                       if (falseStatements.Length == 0)
-                       {
-                               if (trueStatements.Length == 0)
-                               {
-                                       // Use Ctor(CodeExpression)
-                                       var condition1 = new CodeConditionStatement(expression);
-                                       Assert.Equal(expression, condition1.Condition);
-                                       Assert.Empty(condition1.TrueStatements);
-                                       Assert.Empty(condition1.FalseStatements);
-                               }
-                               // Use Ctor(CodeExpression, CodeStatement[])
-                               var condition2 = new CodeConditionStatement(expression, trueStatements);
-                               Assert.Equal(expression, condition2.Condition);
-                               Assert.Equal(trueStatements, condition2.TrueStatements.Cast<CodeStatement>());
-                               Assert.Empty(condition2.FalseStatements);
-                       }
-                       // Use Ctor(CodeExpression, CodeStatement[], CodeStatement[])
-                       var condition3 = new CodeConditionStatement(expression, trueStatements, falseStatements);
-                       Assert.Equal(expression, condition3.Condition);
-                       Assert.Equal(trueStatements, condition3.TrueStatements.Cast<CodeStatement>());
-                       Assert.Equal(falseStatements, condition3.FalseStatements.Cast<CodeStatement>());
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TestData))]
+        public void Ctor(CodeExpression expression, CodeStatement[] trueStatements, CodeStatement[] falseStatements)
+        {
+            if (falseStatements.Length == 0)
+            {
+                if (trueStatements.Length == 0)
+                {
+                    // Use Ctor(CodeExpression)
+                    var condition1 = new CodeConditionStatement(expression);
+                    Assert.Equal(expression, condition1.Condition);
+                    Assert.Empty(condition1.TrueStatements);
+                    Assert.Empty(condition1.FalseStatements);
+                }
+                // Use Ctor(CodeExpression, CodeStatement[])
+                var condition2 = new CodeConditionStatement(expression, trueStatements);
+                Assert.Equal(expression, condition2.Condition);
+                Assert.Equal(trueStatements, condition2.TrueStatements.Cast<CodeStatement>());
+                Assert.Empty(condition2.FalseStatements);
+            }
+            // Use Ctor(CodeExpression, CodeStatement[], CodeStatement[])
+            var condition3 = new CodeConditionStatement(expression, trueStatements, falseStatements);
+            Assert.Equal(expression, condition3.Condition);
+            Assert.Equal(trueStatements, condition3.TrueStatements.Cast<CodeStatement>());
+            Assert.Equal(falseStatements, condition3.FalseStatements.Cast<CodeStatement>());
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Condition_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var condition = new CodeConditionStatement();
-                       condition.Condition = value;
-                       Assert.Equal(value, condition.Condition);
-               }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Condition_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var condition = new CodeConditionStatement();
+            condition.Condition = value;
+            Assert.Equal(value, condition.Condition);
+        }
 
-               [Fact]
-               public void TrueStatements_AddMultiple_ReturnsExpected()
-               {
-                       var condition = new CodeConditionStatement();
+        [Fact]
+        public void TrueStatements_AddMultiple_ReturnsExpected()
+        {
+            var condition = new CodeConditionStatement();
 
-                       CodeStatement statement1 = new CodeCommentStatement("Value1");
-                       condition.TrueStatements.Add(statement1);
-                       Assert.Equal(new CodeStatement[] { statement1 }, condition.TrueStatements.Cast<CodeStatement>());
+            CodeStatement statement1 = new CodeCommentStatement("Value1");
+            condition.TrueStatements.Add(statement1);
+            Assert.Equal(new CodeStatement[] { statement1 }, condition.TrueStatements.Cast<CodeStatement>());
 
-                       CodeStatement statement2 = new CodeCommentStatement("Value2");
-                       condition.TrueStatements.Add(statement2);
-                       Assert.Equal(new CodeStatement[] { statement1, statement2 }, condition.TrueStatements.Cast<CodeStatement>());
-               }
+            CodeStatement statement2 = new CodeCommentStatement("Value2");
+            condition.TrueStatements.Add(statement2);
+            Assert.Equal(new CodeStatement[] { statement1, statement2 }, condition.TrueStatements.Cast<CodeStatement>());
+        }
 
-               [Fact]
-               public void FalseStatements_AddMultiple_ReturnsExpected()
-               {
-                       var condition = new CodeConditionStatement();
+        [Fact]
+        public void FalseStatements_AddMultiple_ReturnsExpected()
+        {
+            var condition = new CodeConditionStatement();
 
-                       CodeStatement statement1 = new CodeCommentStatement("Value1");
-                       condition.FalseStatements.Add(statement1);
-                       Assert.Equal(new CodeStatement[] { statement1 }, condition.FalseStatements.Cast<CodeStatement>());
+            CodeStatement statement1 = new CodeCommentStatement("Value1");
+            condition.FalseStatements.Add(statement1);
+            Assert.Equal(new CodeStatement[] { statement1 }, condition.FalseStatements.Cast<CodeStatement>());
 
-                       CodeStatement statement2 = new CodeCommentStatement("Value2");
-                       condition.FalseStatements.Add(statement2);
-                       Assert.Equal(new CodeStatement[] { statement1, statement2 }, condition.FalseStatements.Cast<CodeStatement>());
-               }
-       }
+            CodeStatement statement2 = new CodeCommentStatement("Value2");
+            condition.FalseStatements.Add(statement2);
+            Assert.Equal(new CodeStatement[] { statement1, statement2 }, condition.FalseStatements.Cast<CodeStatement>());
+        }
+    }
 }
index 58c09bf..9ea3ce6 100644 (file)
@@ -7,43 +7,43 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeConstructorTests : CodeObjectTestBase<CodeConstructor>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var constructor = new CodeConstructor();
-                       Assert.Equal(".ctor", constructor.Name);
-                       Assert.Empty(constructor.BaseConstructorArgs);
-                       Assert.Empty(constructor.ChainedConstructorArgs);
-               }
-
-               [Fact]
-               public void BaseConstructorArgs_AddMultiple_ReturnsExpected()
-               {
-                       var constructor = new CodeConstructor();
-
-                       CodeExpression expression1 = new CodePrimitiveExpression("Value1");
-                       constructor.BaseConstructorArgs.Add(expression1);
-                       Assert.Equal(new CodeExpression[] { expression1 }, constructor.BaseConstructorArgs.Cast<CodeExpression>());
-
-                       CodeExpression expression2 = new CodePrimitiveExpression("Value2");
-                       constructor.BaseConstructorArgs.Add(expression2);
-                       Assert.Equal(new CodeExpression[] { expression1, expression2 }, constructor.BaseConstructorArgs.Cast<CodeExpression>());
-               }
-
-               [Fact]
-               public void ChainedConstructorArgs_AddMultiple_ReturnsExpected()
-               {
-                       var constructor = new CodeConstructor();
-
-                       CodeExpression expression1 = new CodePrimitiveExpression("Value1");
-                       constructor.ChainedConstructorArgs.Add(expression1);
-                       Assert.Equal(new CodeExpression[] { expression1 }, constructor.ChainedConstructorArgs.Cast<CodeExpression>());
-
-                       CodeExpression expression2 = new CodePrimitiveExpression("Value2");
-                       constructor.ChainedConstructorArgs.Add(expression2);
-                       Assert.Equal(new CodeExpression[] { expression1, expression2 }, constructor.ChainedConstructorArgs.Cast<CodeExpression>());
-               }
-       }
+    public class CodeConstructorTests : CodeObjectTestBase<CodeConstructor>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var constructor = new CodeConstructor();
+            Assert.Equal(".ctor", constructor.Name);
+            Assert.Empty(constructor.BaseConstructorArgs);
+            Assert.Empty(constructor.ChainedConstructorArgs);
+        }
+
+        [Fact]
+        public void BaseConstructorArgs_AddMultiple_ReturnsExpected()
+        {
+            var constructor = new CodeConstructor();
+
+            CodeExpression expression1 = new CodePrimitiveExpression("Value1");
+            constructor.BaseConstructorArgs.Add(expression1);
+            Assert.Equal(new CodeExpression[] { expression1 }, constructor.BaseConstructorArgs.Cast<CodeExpression>());
+
+            CodeExpression expression2 = new CodePrimitiveExpression("Value2");
+            constructor.BaseConstructorArgs.Add(expression2);
+            Assert.Equal(new CodeExpression[] { expression1, expression2 }, constructor.BaseConstructorArgs.Cast<CodeExpression>());
+        }
+
+        [Fact]
+        public void ChainedConstructorArgs_AddMultiple_ReturnsExpected()
+        {
+            var constructor = new CodeConstructor();
+
+            CodeExpression expression1 = new CodePrimitiveExpression("Value1");
+            constructor.ChainedConstructorArgs.Add(expression1);
+            Assert.Equal(new CodeExpression[] { expression1 }, constructor.ChainedConstructorArgs.Cast<CodeExpression>());
+
+            CodeExpression expression2 = new CodePrimitiveExpression("Value2");
+            constructor.ChainedConstructorArgs.Add(expression2);
+            Assert.Equal(new CodeExpression[] { expression1, expression2 }, constructor.ChainedConstructorArgs.Cast<CodeExpression>());
+        }
+    }
 }
index 9866bf5..2e5bbdc 100644 (file)
@@ -6,30 +6,30 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeDefaultValueExpressionTests : CodeObjectTestBase<CodeDefaultValueExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var defaultValue = new CodeDefaultValueExpression();
-                       Assert.Equal(typeof(void).FullName, defaultValue.Type.BaseType);
-               }
+    public class CodeDefaultValueExpressionTests : CodeObjectTestBase<CodeDefaultValueExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var defaultValue = new CodeDefaultValueExpression();
+            Assert.Equal(typeof(void).FullName, defaultValue.Type.BaseType);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Ctor_CodeTypeReference(CodeTypeReference type)
-               {
-                       var defaultValue = new CodeDefaultValueExpression(type);
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, defaultValue.Type.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Ctor_CodeTypeReference(CodeTypeReference type)
+        {
+            var defaultValue = new CodeDefaultValueExpression(type);
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, defaultValue.Type.BaseType);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Type_Set_Get_ReturnsExpected(CodeTypeReference value)
-               {
-                       var defaultValue = new CodeDefaultValueExpression();
-                       defaultValue.Type = value;
-                       Assert.Equal((value ?? new CodeTypeReference("")).BaseType, defaultValue.Type.BaseType);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Type_Set_Get_ReturnsExpected(CodeTypeReference value)
+        {
+            var defaultValue = new CodeDefaultValueExpression();
+            defaultValue.Type = value;
+            Assert.Equal((value ?? new CodeTypeReference("")).BaseType, defaultValue.Type.BaseType);
+        }
+    }
 }
index 6d6be3e..269c615 100644 (file)
@@ -7,62 +7,62 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeDelegateCreateExpressionTests : CodeObjectTestBase<CodeDelegateCreateExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var delegateCreate = new CodeDelegateCreateExpression();
-                       Assert.Equal(typeof(void).FullName, delegateCreate.DelegateType.BaseType);
+    public class CodeDelegateCreateExpressionTests : CodeObjectTestBase<CodeDelegateCreateExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var delegateCreate = new CodeDelegateCreateExpression();
+            Assert.Equal(typeof(void).FullName, delegateCreate.DelegateType.BaseType);
 
-                       Assert.Null(delegateCreate.TargetObject);
-                       Assert.Empty(delegateCreate.MethodName);
-               }
+            Assert.Null(delegateCreate.TargetObject);
+            Assert.Empty(delegateCreate.MethodName);
+        }
 
-               public static IEnumerable<object[]> Ctor_TestData()
-               {
-                       yield return new object[] { null, null, null };
-                       yield return new object[] { new CodeTypeReference(""), new CodePrimitiveExpression(""), "" };
-                       yield return new object[] { new CodeTypeReference(typeof(Delegate)), new CodePrimitiveExpression("Value"), "MethodName" };
-               }
+        public static IEnumerable<object[]> Ctor_TestData()
+        {
+            yield return new object[] { null, null, null };
+            yield return new object[] { new CodeTypeReference(""), new CodePrimitiveExpression(""), "" };
+            yield return new object[] { new CodeTypeReference(typeof(Delegate)), new CodePrimitiveExpression("Value"), "MethodName" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TestData))]
-               public void Ctor(CodeTypeReference delegateType, CodeExpression targetObject, string methodName)
-               {
-                       var delegateCreate = new CodeDelegateCreateExpression(delegateType, targetObject, methodName);
-                       Assert.Equal((delegateType ?? new CodeTypeReference("")).BaseType, delegateCreate.DelegateType.BaseType);
-                       Assert.Equal(targetObject, delegateCreate.TargetObject);
-                       Assert.Equal(methodName ?? string.Empty, delegateCreate.MethodName);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TestData))]
+        public void Ctor(CodeTypeReference delegateType, CodeExpression targetObject, string methodName)
+        {
+            var delegateCreate = new CodeDelegateCreateExpression(delegateType, targetObject, methodName);
+            Assert.Equal((delegateType ?? new CodeTypeReference("")).BaseType, delegateCreate.DelegateType.BaseType);
+            Assert.Equal(targetObject, delegateCreate.TargetObject);
+            Assert.Equal(methodName ?? string.Empty, delegateCreate.MethodName);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void DelegateType_Set_Get_ReturnsExpected(CodeTypeReference value)
-               {
-                       var delegateCreate = new CodeDelegateCreateExpression();
-                       delegateCreate.DelegateType = value;
-                       Assert.Equal((value ?? new CodeTypeReference("")).BaseType, delegateCreate.DelegateType.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void DelegateType_Set_Get_ReturnsExpected(CodeTypeReference value)
+        {
+            var delegateCreate = new CodeDelegateCreateExpression();
+            delegateCreate.DelegateType = value;
+            Assert.Equal((value ?? new CodeTypeReference("")).BaseType, delegateCreate.DelegateType.BaseType);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var delegateCreate = new CodeDelegateCreateExpression();
-                       delegateCreate.TargetObject = value;
-                       Assert.Equal(value, delegateCreate.TargetObject);
-               }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var delegateCreate = new CodeDelegateCreateExpression();
+            delegateCreate.TargetObject = value;
+            Assert.Equal(value, delegateCreate.TargetObject);
+        }
 
-               [Theory]
-               [InlineData(null)]
-               [InlineData("")]
-               [InlineData("MethodName")]
-               public void MethodName_Set_Get_ReturnsExpected(string value)
-               {
-                       var delegateCreate = new CodeDelegateCreateExpression();
-                       delegateCreate.MethodName = value;
-                       Assert.Equal(value ?? string.Empty, delegateCreate.MethodName);
-               }
-       }
+        [Theory]
+        [InlineData(null)]
+        [InlineData("")]
+        [InlineData("MethodName")]
+        public void MethodName_Set_Get_ReturnsExpected(string value)
+        {
+            var delegateCreate = new CodeDelegateCreateExpression();
+            delegateCreate.MethodName = value;
+            Assert.Equal(value ?? string.Empty, delegateCreate.MethodName);
+        }
+    }
 }
index b821650..18fa738 100644 (file)
@@ -8,76 +8,76 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeDelegateInvokeExpressionTests : CodeObjectTestBase<CodeDelegateInvokeExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var delegateInvoke = new CodeDelegateInvokeExpression();
-                       Assert.Null(delegateInvoke.TargetObject);
+    public class CodeDelegateInvokeExpressionTests : CodeObjectTestBase<CodeDelegateInvokeExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var delegateInvoke = new CodeDelegateInvokeExpression();
+            Assert.Null(delegateInvoke.TargetObject);
 
-                       Assert.Empty(delegateInvoke.Parameters);
-               }
+            Assert.Empty(delegateInvoke.Parameters);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Ctor_CodeExpression(CodeExpression targetObject)
-               {
-                       var delegateInvoke = new CodeDelegateInvokeExpression(targetObject);
-                       Assert.Equal(targetObject, delegateInvoke.TargetObject);
-                       Assert.Empty(delegateInvoke.Parameters);
-               }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Ctor_CodeExpression(CodeExpression targetObject)
+        {
+            var delegateInvoke = new CodeDelegateInvokeExpression(targetObject);
+            Assert.Equal(targetObject, delegateInvoke.TargetObject);
+            Assert.Empty(delegateInvoke.Parameters);
+        }
 
-               public static IEnumerable<object[]> Ctor_CodeExpression_ParamsCodeExpression_TestData()
-               {
-                       yield return new object[] { null, new CodeExpression[0] };
-                       yield return new object[] { new CodePrimitiveExpression(""), new CodeExpression[] { new CodePrimitiveExpression() } };
-                       yield return new object[] { new CodePrimitiveExpression("Hello"), new CodeExpression[] { new CodePrimitiveExpression("Value1") } };
-               }
+        public static IEnumerable<object[]> Ctor_CodeExpression_ParamsCodeExpression_TestData()
+        {
+            yield return new object[] { null, new CodeExpression[0] };
+            yield return new object[] { new CodePrimitiveExpression(""), new CodeExpression[] { new CodePrimitiveExpression() } };
+            yield return new object[] { new CodePrimitiveExpression("Hello"), new CodeExpression[] { new CodePrimitiveExpression("Value1") } };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_CodeExpression_ParamsCodeExpression_TestData))]
-               public void Ctor_CodeExpression_ParamsCodeExpression(CodeExpression targetObject, CodeExpression[] parameters)
-               {
-                       var delegateInvoke = new CodeDelegateInvokeExpression(targetObject, parameters);
-                       Assert.Equal(targetObject, delegateInvoke.TargetObject);
-                       Assert.Equal(parameters, delegateInvoke.Parameters.Cast<CodeExpression>());
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_CodeExpression_ParamsCodeExpression_TestData))]
+        public void Ctor_CodeExpression_ParamsCodeExpression(CodeExpression targetObject, CodeExpression[] parameters)
+        {
+            var delegateInvoke = new CodeDelegateInvokeExpression(targetObject, parameters);
+            Assert.Equal(targetObject, delegateInvoke.TargetObject);
+            Assert.Equal(parameters, delegateInvoke.Parameters.Cast<CodeExpression>());
+        }
 
-               [Fact]
-               public void Ctor_NullParameters_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeDelegateInvokeExpression(new CodePrimitiveExpression("Hello"), null));
-               }
+        [Fact]
+        public void Ctor_NullParameters_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeDelegateInvokeExpression(new CodePrimitiveExpression("Hello"), null));
+        }
 
-               [Fact]
-               public void Ctor_NullObjectInParameters_ThrowsArgumentNullException()
-               {
-                       CodeExpression[] parameters = new CodeExpression[] { null };
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeDelegateInvokeExpression(new CodePrimitiveExpression("Hello"), parameters));
-               }
+        [Fact]
+        public void Ctor_NullObjectInParameters_ThrowsArgumentNullException()
+        {
+            CodeExpression[] parameters = new CodeExpression[] { null };
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeDelegateInvokeExpression(new CodePrimitiveExpression("Hello"), parameters));
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var delegateInvoke = new CodeDelegateInvokeExpression();
-                       delegateInvoke.TargetObject = value;
-                       Assert.Same(value, delegateInvoke.TargetObject);
-               }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var delegateInvoke = new CodeDelegateInvokeExpression();
+            delegateInvoke.TargetObject = value;
+            Assert.Same(value, delegateInvoke.TargetObject);
+        }
 
-               [Fact]
-               public void Parameters_AddMultiple_ReturnsExpected()
-               {
-                       var delegateInvoke = new CodeDelegateInvokeExpression();
+        [Fact]
+        public void Parameters_AddMultiple_ReturnsExpected()
+        {
+            var delegateInvoke = new CodeDelegateInvokeExpression();
 
-                       CodeParameterDeclarationExpression parameter1 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name1");
-                       delegateInvoke.Parameters.Add(parameter1);
-                       Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1 }, delegateInvoke.Parameters.Cast<CodeParameterDeclarationExpression>());
+            CodeParameterDeclarationExpression parameter1 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name1");
+            delegateInvoke.Parameters.Add(parameter1);
+            Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1 }, delegateInvoke.Parameters.Cast<CodeParameterDeclarationExpression>());
 
-                       CodeParameterDeclarationExpression parameter2 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name2");
-                       delegateInvoke.Parameters.Add(parameter2);
-                       Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1, parameter2 }, delegateInvoke.Parameters.Cast<CodeParameterDeclarationExpression>());
-               }
-       }
+            CodeParameterDeclarationExpression parameter2 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name2");
+            delegateInvoke.Parameters.Add(parameter2);
+            Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1, parameter2 }, delegateInvoke.Parameters.Cast<CodeParameterDeclarationExpression>());
+        }
+    }
 }
index 1132fa7..3b47d5d 100644 (file)
@@ -7,51 +7,51 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeDirectionExpressionTests : CodeObjectTestBase<CodeDirectionExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var direction = new CodeDirectionExpression();
-                       Assert.Null(direction.Expression);
-                       Assert.Equal(FieldDirection.In, direction.Direction);
-               }
+    public class CodeDirectionExpressionTests : CodeObjectTestBase<CodeDirectionExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var direction = new CodeDirectionExpression();
+            Assert.Null(direction.Expression);
+            Assert.Equal(FieldDirection.In, direction.Direction);
+        }
 
-               public static IEnumerable<object[]> Ctor_TestData()
-               {
-                       yield return new object[] { FieldDirection.In, null };
-                       yield return new object[] { FieldDirection.In - 1, new CodePrimitiveExpression() };
-                       yield return new object[] { FieldDirection.Ref + 1, new CodePrimitiveExpression("Value") };
-               }
+        public static IEnumerable<object[]> Ctor_TestData()
+        {
+            yield return new object[] { FieldDirection.In, null };
+            yield return new object[] { FieldDirection.In - 1, new CodePrimitiveExpression() };
+            yield return new object[] { FieldDirection.Ref + 1, new CodePrimitiveExpression("Value") };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TestData))]
-               public void Ctor(FieldDirection direction, CodeExpression expression)
-               {
-                       var directionExpression = new CodeDirectionExpression(direction, expression);
-                       Assert.Equal(direction, directionExpression.Direction);
-                       Assert.Equal(expression, directionExpression.Expression);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TestData))]
+        public void Ctor(FieldDirection direction, CodeExpression expression)
+        {
+            var directionExpression = new CodeDirectionExpression(direction, expression);
+            Assert.Equal(direction, directionExpression.Direction);
+            Assert.Equal(expression, directionExpression.Expression);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Expression_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var direction = new CodeDirectionExpression();
-                       direction.Expression = value;
-                       Assert.Equal(value, direction.Expression);
-               }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Expression_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var direction = new CodeDirectionExpression();
+            direction.Expression = value;
+            Assert.Equal(value, direction.Expression);
+        }
 
-               [Theory]
-               [InlineData(FieldDirection.In - 1)]
-               [InlineData(FieldDirection.In)]
-               [InlineData(FieldDirection.In | FieldDirection.Out)]
-               [InlineData(FieldDirection.Ref + 1)]
-               public void Direction_Set_Get_ReturnsExpected(FieldDirection value)
-               {
-                       var direction = new CodeDirectionExpression();
-                       direction.Direction = value;
-                       Assert.Equal(value, direction.Direction);
-               }
-       }
+        [Theory]
+        [InlineData(FieldDirection.In - 1)]
+        [InlineData(FieldDirection.In)]
+        [InlineData(FieldDirection.In | FieldDirection.Out)]
+        [InlineData(FieldDirection.Ref + 1)]
+        public void Direction_Set_Get_ReturnsExpected(FieldDirection value)
+        {
+            var direction = new CodeDirectionExpression();
+            direction.Direction = value;
+            Assert.Equal(value, direction.Direction);
+        }
+    }
 }
index 9b6741a..b48ba2a 100644 (file)
@@ -7,50 +7,50 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeEventReferenceExpressionTests : CodeObjectTestBase<CodeEventReferenceExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var eventReference = new CodeEventReferenceExpression();
-                       Assert.Null(eventReference.TargetObject);
-                       Assert.Empty(eventReference.EventName);
-               }
+    public class CodeEventReferenceExpressionTests : CodeObjectTestBase<CodeEventReferenceExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var eventReference = new CodeEventReferenceExpression();
+            Assert.Null(eventReference.TargetObject);
+            Assert.Empty(eventReference.EventName);
+        }
 
-               public static IEnumerable<object[]> Ctor_TestData()
-               {
-                       yield return new object[] { null, null };
-                       yield return new object[] { new CodePrimitiveExpression(""), "" };
-                       yield return new object[] { new CodePrimitiveExpression("Value"), "EventName" };
-               }
+        public static IEnumerable<object[]> Ctor_TestData()
+        {
+            yield return new object[] { null, null };
+            yield return new object[] { new CodePrimitiveExpression(""), "" };
+            yield return new object[] { new CodePrimitiveExpression("Value"), "EventName" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TestData))]
-               public void Ctor(CodeExpression targetObject, string eventName)
-               {
-                       var eventReference = new CodeEventReferenceExpression(targetObject, eventName);
-                       Assert.Equal(targetObject, eventReference.TargetObject);
-                       Assert.Equal(eventName ?? string.Empty, eventReference.EventName);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TestData))]
+        public void Ctor(CodeExpression targetObject, string eventName)
+        {
+            var eventReference = new CodeEventReferenceExpression(targetObject, eventName);
+            Assert.Equal(targetObject, eventReference.TargetObject);
+            Assert.Equal(eventName ?? string.Empty, eventReference.EventName);
+        }
 
-               [Theory]
-               [InlineData(null)]
-               [InlineData("")]
-               [InlineData("EventName")]
-               public void EventName_Set_Get_ReturnsExpected(string value)
-               {
-                       var eventReference = new CodeEventReferenceExpression();
-                       eventReference.EventName = value;
-                       Assert.Equal(value ?? string.Empty, eventReference.EventName);
-               }
+        [Theory]
+        [InlineData(null)]
+        [InlineData("")]
+        [InlineData("EventName")]
+        public void EventName_Set_Get_ReturnsExpected(string value)
+        {
+            var eventReference = new CodeEventReferenceExpression();
+            eventReference.EventName = value;
+            Assert.Equal(value ?? string.Empty, eventReference.EventName);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var eventReference = new CodeEventReferenceExpression();
-                       eventReference.TargetObject = value;
-                       Assert.Equal(value, eventReference.TargetObject);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var eventReference = new CodeEventReferenceExpression();
+            eventReference.TargetObject = value;
+            Assert.Equal(value, eventReference.TargetObject);
+        }
+    }
 }
index e0b8ee2..422e9c7 100644 (file)
@@ -6,30 +6,30 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeExpressionStatementTests : CodeStatementTestBase<CodeExpressionStatement>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var expressionStatement = new CodeExpressionStatement();
-                       Assert.Null(expressionStatement.Expression);
-               }
+    public class CodeExpressionStatementTests : CodeStatementTestBase<CodeExpressionStatement>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var expressionStatement = new CodeExpressionStatement();
+            Assert.Null(expressionStatement.Expression);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Ctor_CodeExpression(CodeExpression expression)
-               {
-                       var expressionStatement = new CodeExpressionStatement(expression);
-                       Assert.Equal(expression, expressionStatement.Expression);
-               }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Ctor_CodeExpression(CodeExpression expression)
+        {
+            var expressionStatement = new CodeExpressionStatement(expression);
+            Assert.Equal(expression, expressionStatement.Expression);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Expression_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var expressionStatement = new CodeExpressionStatement();
-                       expressionStatement.Expression = value;
-                       Assert.Equal(value, expressionStatement.Expression);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Expression_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var expressionStatement = new CodeExpressionStatement();
+            expressionStatement.Expression = value;
+            Assert.Equal(value, expressionStatement.Expression);
+        }
+    }
 }
index fef5fb9..0149ec8 100644 (file)
@@ -7,50 +7,50 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeFieldReferenceExpressionTests : CodeObjectTestBase<CodeFieldReferenceExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var fieldReference = new CodeFieldReferenceExpression();
-                       Assert.Null(fieldReference.TargetObject);
-                       Assert.Empty(fieldReference.FieldName);
-               }
+    public class CodeFieldReferenceExpressionTests : CodeObjectTestBase<CodeFieldReferenceExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var fieldReference = new CodeFieldReferenceExpression();
+            Assert.Null(fieldReference.TargetObject);
+            Assert.Empty(fieldReference.FieldName);
+        }
 
-               public static IEnumerable<object[]> Ctor_TestData()
-               {
-                       yield return new object[] { null, null };
-                       yield return new object[] { new CodePrimitiveExpression(""), "" };
-                       yield return new object[] { new CodePrimitiveExpression("Value"), "FieldName" };
-               }
+        public static IEnumerable<object[]> Ctor_TestData()
+        {
+            yield return new object[] { null, null };
+            yield return new object[] { new CodePrimitiveExpression(""), "" };
+            yield return new object[] { new CodePrimitiveExpression("Value"), "FieldName" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TestData))]
-               public void Ctor(CodeExpression targetObject, string fieldName)
-               {
-                       var fieldReference = new CodeFieldReferenceExpression(targetObject, fieldName);
-                       Assert.Equal(targetObject, fieldReference.TargetObject);
-                       Assert.Equal(fieldName ?? string.Empty, fieldReference.FieldName);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TestData))]
+        public void Ctor(CodeExpression targetObject, string fieldName)
+        {
+            var fieldReference = new CodeFieldReferenceExpression(targetObject, fieldName);
+            Assert.Equal(targetObject, fieldReference.TargetObject);
+            Assert.Equal(fieldName ?? string.Empty, fieldReference.FieldName);
+        }
 
-               [Theory]
-               [InlineData(null)]
-               [InlineData("")]
-               [InlineData("FieldName")]
-               public void EventName_Set_Get_ReturnsExpected(string value)
-               {
-                       var fieldReference = new CodeFieldReferenceExpression();
-                       fieldReference.FieldName = value;
-                       Assert.Equal(value ?? string.Empty, fieldReference.FieldName);
-               }
+        [Theory]
+        [InlineData(null)]
+        [InlineData("")]
+        [InlineData("FieldName")]
+        public void EventName_Set_Get_ReturnsExpected(string value)
+        {
+            var fieldReference = new CodeFieldReferenceExpression();
+            fieldReference.FieldName = value;
+            Assert.Equal(value ?? string.Empty, fieldReference.FieldName);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var fieldReference = new CodeFieldReferenceExpression();
-                       fieldReference.TargetObject = value;
-                       Assert.Equal(value, fieldReference.TargetObject);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var fieldReference = new CodeFieldReferenceExpression();
+            fieldReference.TargetObject = value;
+            Assert.Equal(value, fieldReference.TargetObject);
+        }
+    }
 }
index 7e576e6..122fbcd 100644 (file)
@@ -6,49 +6,49 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeGotoStatementTests : CodeStatementTestBase<CodeGotoStatement>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var gotoStatement = new CodeGotoStatement();
-                       Assert.Null(gotoStatement.Label);
-               }
+    public class CodeGotoStatementTests : CodeStatementTestBase<CodeGotoStatement>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var gotoStatement = new CodeGotoStatement();
+            Assert.Null(gotoStatement.Label);
+        }
 
-               [Theory]
-               [InlineData("\r n \t")]
-               [InlineData("Label")]
-               public void Ctor_String(string label)
-               {
-                       var gotoStatement = new CodeGotoStatement(label);
-                       Assert.Equal(label, gotoStatement.Label);
-               }
+        [Theory]
+        [InlineData("\r n \t")]
+        [InlineData("Label")]
+        public void Ctor_String(string label)
+        {
+            var gotoStatement = new CodeGotoStatement(label);
+            Assert.Equal(label, gotoStatement.Label);
+        }
 
-               [Theory]
-               [InlineData(null)]
-               [InlineData("")]
-               public void Ctor_StringNullOrEmpty_ThrowsArgumentNullException(string value)
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeGotoStatement(value));
-               }
+        [Theory]
+        [InlineData(null)]
+        [InlineData("")]
+        public void Ctor_StringNullOrEmpty_ThrowsArgumentNullException(string value)
+        {
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeGotoStatement(value));
+        }
 
-               [Theory]
-               [InlineData("\r \n \t")]
-               [InlineData("Label")]
-               public void Label_Set_Get_ReturnsExpected(string value)
-               {
-                       var gotoStatement = new CodeGotoStatement();
-                       gotoStatement.Label = value;
-                       Assert.Equal(value, gotoStatement.Label);
-               }
+        [Theory]
+        [InlineData("\r \n \t")]
+        [InlineData("Label")]
+        public void Label_Set_Get_ReturnsExpected(string value)
+        {
+            var gotoStatement = new CodeGotoStatement();
+            gotoStatement.Label = value;
+            Assert.Equal(value, gotoStatement.Label);
+        }
 
-               [Theory]
-               [InlineData(null)]
-               [InlineData("")]
-               public void Label_SetNullOrEmpty_ThrowsArgumentNullException(string value)
-               {
-                       var gotoStatement = new CodeGotoStatement();
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => gotoStatement.Label = value);
-               }
-       }
+        [Theory]
+        [InlineData(null)]
+        [InlineData("")]
+        public void Label_SetNullOrEmpty_ThrowsArgumentNullException(string value)
+        {
+            var gotoStatement = new CodeGotoStatement();
+            AssertExtensions.Throws<ArgumentNullException>("value", () => gotoStatement.Label = value);
+        }
+    }
 }
index a1171f5..833fae6 100644 (file)
@@ -8,66 +8,66 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeIndexerExpressionTests : CodeObjectTestBase<CodeIndexerExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var indexer = new CodeIndexerExpression();
-                       Assert.Null(indexer.TargetObject);
-                       Assert.Empty(indexer.Indices);
-               }
+    public class CodeIndexerExpressionTests : CodeObjectTestBase<CodeIndexerExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var indexer = new CodeIndexerExpression();
+            Assert.Null(indexer.TargetObject);
+            Assert.Empty(indexer.Indices);
+        }
 
-               public static IEnumerable<object[]> Ctor_CodeExpression_ParamsCodeExpression_TestData()
-               {
-                       yield return new object[] { null, new CodeExpression[0] };
-                       yield return new object[] { new CodePrimitiveExpression(""), new CodeExpression[] { new CodePrimitiveExpression() } };
-                       yield return new object[] { new CodePrimitiveExpression("Hello"), new CodeExpression[] { new CodePrimitiveExpression("Value1") } };
-               }
+        public static IEnumerable<object[]> Ctor_CodeExpression_ParamsCodeExpression_TestData()
+        {
+            yield return new object[] { null, new CodeExpression[0] };
+            yield return new object[] { new CodePrimitiveExpression(""), new CodeExpression[] { new CodePrimitiveExpression() } };
+            yield return new object[] { new CodePrimitiveExpression("Hello"), new CodeExpression[] { new CodePrimitiveExpression("Value1") } };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_CodeExpression_ParamsCodeExpression_TestData))]
-               public void Ctor_CodeExpression_ParamsCodeExpression(CodeExpression targetObject, CodeExpression[] parameters)
-               {
-                       var indexer = new CodeIndexerExpression(targetObject, parameters);
-                       Assert.Equal(targetObject, indexer.TargetObject);
-                       Assert.Equal(parameters, indexer.Indices.Cast<CodeExpression>());
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_CodeExpression_ParamsCodeExpression_TestData))]
+        public void Ctor_CodeExpression_ParamsCodeExpression(CodeExpression targetObject, CodeExpression[] parameters)
+        {
+            var indexer = new CodeIndexerExpression(targetObject, parameters);
+            Assert.Equal(targetObject, indexer.TargetObject);
+            Assert.Equal(parameters, indexer.Indices.Cast<CodeExpression>());
+        }
 
-               [Fact]
-               public void Ctor_NullIndices_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeIndexerExpression(new CodePrimitiveExpression("Hello"), null));
-               }
+        [Fact]
+        public void Ctor_NullIndices_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeIndexerExpression(new CodePrimitiveExpression("Hello"), null));
+        }
 
-               [Fact]
-               public void Ctor_NullObjectInIndices_ThrowsArgumentNullException()
-               {
-                       CodeExpression[] parameters = new CodeExpression[] { null };
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeIndexerExpression(new CodePrimitiveExpression("Hello"), parameters));
-               }
+        [Fact]
+        public void Ctor_NullObjectInIndices_ThrowsArgumentNullException()
+        {
+            CodeExpression[] parameters = new CodeExpression[] { null };
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeIndexerExpression(new CodePrimitiveExpression("Hello"), parameters));
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var indexer = new CodeIndexerExpression();
-                       indexer.TargetObject = value;
-                       Assert.Equal(value, indexer.TargetObject);
-               }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var indexer = new CodeIndexerExpression();
+            indexer.TargetObject = value;
+            Assert.Equal(value, indexer.TargetObject);
+        }
 
-               [Fact]
-               public void Parameters_AddMultiple_ReturnsExpected()
-               {
-                       var indexer = new CodeIndexerExpression();
+        [Fact]
+        public void Parameters_AddMultiple_ReturnsExpected()
+        {
+            var indexer = new CodeIndexerExpression();
 
-                       CodeExpression expression1 = new CodePrimitiveExpression("Value1");
-                       indexer.Indices.Add(expression1);
-                       Assert.Equal(new CodeExpression[] { expression1 }, indexer.Indices.Cast<CodeExpression>());
+            CodeExpression expression1 = new CodePrimitiveExpression("Value1");
+            indexer.Indices.Add(expression1);
+            Assert.Equal(new CodeExpression[] { expression1 }, indexer.Indices.Cast<CodeExpression>());
 
-                       CodeExpression expression2 = new CodePrimitiveExpression("Value2");
-                       indexer.Indices.Add(expression2);
-                       Assert.Equal(new CodeExpression[] { expression1, expression2 }, indexer.Indices.Cast<CodeExpression>());
-               }
-       }
+            CodeExpression expression2 = new CodePrimitiveExpression("Value2");
+            indexer.Indices.Add(expression2);
+            Assert.Equal(new CodeExpression[] { expression1, expression2 }, indexer.Indices.Cast<CodeExpression>());
+        }
+    }
 }
index d1f15e0..7a8bde2 100644 (file)
@@ -8,92 +8,92 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeIterationStatementTests : CodeStatementTestBase<CodeIterationStatement>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var iteration = new CodeIterationStatement();
-                       Assert.Null(iteration.InitStatement);
-                       Assert.Null(iteration.TestExpression);
-                       Assert.Null(iteration.IncrementStatement);
+    public class CodeIterationStatementTests : CodeStatementTestBase<CodeIterationStatement>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var iteration = new CodeIterationStatement();
+            Assert.Null(iteration.InitStatement);
+            Assert.Null(iteration.TestExpression);
+            Assert.Null(iteration.IncrementStatement);
 
-                       Assert.Empty(iteration.Statements);
-               }
+            Assert.Empty(iteration.Statements);
+        }
 
-               public static IEnumerable<object[]> Ctor_TestData()
-               {
-                       yield return new object[] { null, null, null, new CodeStatement[0] };
-                       yield return new object[] { new CodeCommentStatement("1"), new CodePrimitiveExpression("2"), new CodeCommentStatement("3"), new CodeStatement[] { new CodeCommentStatement("4") } };
-               }
+        public static IEnumerable<object[]> Ctor_TestData()
+        {
+            yield return new object[] { null, null, null, new CodeStatement[0] };
+            yield return new object[] { new CodeCommentStatement("1"), new CodePrimitiveExpression("2"), new CodeCommentStatement("3"), new CodeStatement[] { new CodeCommentStatement("4") } };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TestData))]
-               public void Ctor(CodeStatement initStatement, CodeExpression testExpression, CodeStatement incrementStatement, CodeStatement[] statements)
-               {
-                       var iteration = new CodeIterationStatement(initStatement, testExpression, incrementStatement, statements);
-                       Assert.Equal(initStatement, iteration.InitStatement);
-                       Assert.Equal(testExpression, iteration.TestExpression);
-                       Assert.Equal(incrementStatement, iteration.IncrementStatement);
-                       Assert.Equal(statements, iteration.Statements.Cast<CodeStatement>());
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TestData))]
+        public void Ctor(CodeStatement initStatement, CodeExpression testExpression, CodeStatement incrementStatement, CodeStatement[] statements)
+        {
+            var iteration = new CodeIterationStatement(initStatement, testExpression, incrementStatement, statements);
+            Assert.Equal(initStatement, iteration.InitStatement);
+            Assert.Equal(testExpression, iteration.TestExpression);
+            Assert.Equal(incrementStatement, iteration.IncrementStatement);
+            Assert.Equal(statements, iteration.Statements.Cast<CodeStatement>());
+        }
 
-               [Theory]
-               [InlineData(null)]
-               [InlineData("")]
-               public void Ctor_NullStatements_ThrowsArgumentNullException(string value)
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeIterationStatement(null, null, null, null));
-               }
+        [Theory]
+        [InlineData(null)]
+        [InlineData("")]
+        public void Ctor_NullStatements_ThrowsArgumentNullException(string value)
+        {
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeIterationStatement(null, null, null, null));
+        }
 
-               [Theory]
-               [InlineData(null)]
-               [InlineData("")]
-               public void Ctor_NullObjectInStatements_ThrowsArgumentNullException(string value)
-               {
-                       CodeStatement[] statements = new CodeStatement[] { null };
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeIterationStatement(null, null, null, statements));
-               }
+        [Theory]
+        [InlineData(null)]
+        [InlineData("")]
+        public void Ctor_NullObjectInStatements_ThrowsArgumentNullException(string value)
+        {
+            CodeStatement[] statements = new CodeStatement[] { null };
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeIterationStatement(null, null, null, statements));
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeStatement_TestData))]
-               public void InitStatement_Set_Get_ReturnsExpected(CodeStatement value)
-               {
-                       var iteration = new CodeIterationStatement();
-                       iteration.InitStatement = value;
-                       Assert.Equal(value, iteration.InitStatement);
-               }
+        [Theory]
+        [MemberData(nameof(CodeStatement_TestData))]
+        public void InitStatement_Set_Get_ReturnsExpected(CodeStatement value)
+        {
+            var iteration = new CodeIterationStatement();
+            iteration.InitStatement = value;
+            Assert.Equal(value, iteration.InitStatement);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void TestExpression_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var iteration = new CodeIterationStatement();
-                       iteration.TestExpression = value;
-                       Assert.Equal(value, iteration.TestExpression);
-               }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void TestExpression_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var iteration = new CodeIterationStatement();
+            iteration.TestExpression = value;
+            Assert.Equal(value, iteration.TestExpression);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeStatement_TestData))]
-               public void IncrementStatement_Set_Get_ReturnsExpected(CodeStatement value)
-               {
-                       var iteration = new CodeIterationStatement();
-                       iteration.IncrementStatement = value;
-                       Assert.Equal(value, iteration.IncrementStatement);
-               }
+        [Theory]
+        [MemberData(nameof(CodeStatement_TestData))]
+        public void IncrementStatement_Set_Get_ReturnsExpected(CodeStatement value)
+        {
+            var iteration = new CodeIterationStatement();
+            iteration.IncrementStatement = value;
+            Assert.Equal(value, iteration.IncrementStatement);
+        }
 
-               [Fact]
-               public void Statements_AddMultiple_ReturnsExpected()
-               {
-                       var iteration = new CodeIterationStatement();
+        [Fact]
+        public void Statements_AddMultiple_ReturnsExpected()
+        {
+            var iteration = new CodeIterationStatement();
 
-                       CodeStatement statement1 = new CodeCommentStatement("Value1");
-                       iteration.Statements.Add(statement1);
-                       Assert.Equal(new CodeStatement[] { statement1 }, iteration.Statements.Cast<CodeStatement>());
+            CodeStatement statement1 = new CodeCommentStatement("Value1");
+            iteration.Statements.Add(statement1);
+            Assert.Equal(new CodeStatement[] { statement1 }, iteration.Statements.Cast<CodeStatement>());
 
-                       CodeStatement statement2 = new CodeCommentStatement("Value2");
-                       iteration.Statements.Add(statement2);
-                       Assert.Equal(new CodeStatement[] { statement1, statement2 }, iteration.Statements.Cast<CodeStatement>());
-               }
-       }
+            CodeStatement statement2 = new CodeCommentStatement("Value2");
+            iteration.Statements.Add(statement2);
+            Assert.Equal(new CodeStatement[] { statement1, statement2 }, iteration.Statements.Cast<CodeStatement>());
+        }
+    }
 }
index 06d6153..da11783 100644 (file)
@@ -7,57 +7,57 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeLabeledStatementTests : CodeStatementTestBase<CodeLabeledStatement>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var labeled = new CodeLabeledStatement();
-                       Assert.Empty(labeled.Label);
-                       Assert.Null(labeled.Statement);
-               }
+    public class CodeLabeledStatementTests : CodeStatementTestBase<CodeLabeledStatement>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var labeled = new CodeLabeledStatement();
+            Assert.Empty(labeled.Label);
+            Assert.Null(labeled.Statement);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Ctor_String(string label)
-               {
-                       var labeled = new CodeLabeledStatement(label);
-                       Assert.Equal(label ?? string.Empty, labeled.Label);
-                       Assert.Null(labeled.Statement);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Ctor_String(string label)
+        {
+            var labeled = new CodeLabeledStatement(label);
+            Assert.Equal(label ?? string.Empty, labeled.Label);
+            Assert.Null(labeled.Statement);
+        }
 
-               public static IEnumerable<object[]> Ctor_String_CodeStatement_TestData()
-               {
-                       yield return new object[] { null, null };
-                       yield return new object[] { "", new CodeStatement() };
-                       yield return new object[] { "Label", new CodeCommentStatement("Comment") };
-               }
+        public static IEnumerable<object[]> Ctor_String_CodeStatement_TestData()
+        {
+            yield return new object[] { null, null };
+            yield return new object[] { "", new CodeStatement() };
+            yield return new object[] { "Label", new CodeCommentStatement("Comment") };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_String_CodeStatement_TestData))]
-               public void Ctor_String_CodeStatement(string label, CodeStatement statement)
-               {
-                       var labeled = new CodeLabeledStatement(label, statement);
-                       Assert.Equal(label ?? string.Empty, labeled.Label);
-                       Assert.Equal(statement, labeled.Statement);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_String_CodeStatement_TestData))]
+        public void Ctor_String_CodeStatement(string label, CodeStatement statement)
+        {
+            var labeled = new CodeLabeledStatement(label, statement);
+            Assert.Equal(label ?? string.Empty, labeled.Label);
+            Assert.Equal(statement, labeled.Statement);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Label_Set_Get_ReturnsExpected(string value)
-               {
-                       var labeled = new CodeLabeledStatement();
-                       labeled.Label = value;
-                       Assert.Equal(value ?? string.Empty, labeled.Label);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Label_Set_Get_ReturnsExpected(string value)
+        {
+            var labeled = new CodeLabeledStatement();
+            labeled.Label = value;
+            Assert.Equal(value ?? string.Empty, labeled.Label);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeStatement_TestData))]
-               public void Statement_Set_Get_ReturnsExpected(CodeStatement value)
-               {
-                       var labeled = new CodeLabeledStatement();
-                       labeled.Statement = value;
-                       Assert.Equal(value, labeled.Statement);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeStatement_TestData))]
+        public void Statement_Set_Get_ReturnsExpected(CodeStatement value)
+        {
+            var labeled = new CodeLabeledStatement();
+            labeled.Statement = value;
+            Assert.Equal(value, labeled.Statement);
+        }
+    }
 }
index 5cd90c7..ed71a15 100644 (file)
@@ -7,50 +7,50 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeLinePragmaTests : CodeDomTestBase
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var linePragma = new CodeLinePragma();
-                       Assert.Empty(linePragma.FileName);
-                       Assert.Equal(0, linePragma.LineNumber);
-               }
+    public class CodeLinePragmaTests : CodeDomTestBase
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var linePragma = new CodeLinePragma();
+            Assert.Empty(linePragma.FileName);
+            Assert.Equal(0, linePragma.LineNumber);
+        }
 
-               public static IEnumerable<object[]> Ctor_String_Int_TestData()
-               {
-                       yield return new object[] { null, 0 };
-                       yield return new object[] { "", -1 };
-                       yield return new object[] { "Value1", 1 };
-               }
+        public static IEnumerable<object[]> Ctor_String_Int_TestData()
+        {
+            yield return new object[] { null, 0 };
+            yield return new object[] { "", -1 };
+            yield return new object[] { "Value1", 1 };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_String_Int_TestData))]
-               public void Ctor_String_Int(string fileName, int lineNumber)
-               {
-                       var linePragma = new CodeLinePragma(fileName, lineNumber);
-                       Assert.Equal(fileName ?? string.Empty, linePragma.FileName);
-                       Assert.Equal(lineNumber, linePragma.LineNumber);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_String_Int_TestData))]
+        public void Ctor_String_Int(string fileName, int lineNumber)
+        {
+            var linePragma = new CodeLinePragma(fileName, lineNumber);
+            Assert.Equal(fileName ?? string.Empty, linePragma.FileName);
+            Assert.Equal(lineNumber, linePragma.LineNumber);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void FileName_Set_Get_ReturnsExpected(string value)
-               {
-                       var linePragma = new CodeLinePragma();
-                       linePragma.FileName = value;
-                       Assert.Equal(value ?? string.Empty, linePragma.FileName);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void FileName_Set_Get_ReturnsExpected(string value)
+        {
+            var linePragma = new CodeLinePragma();
+            linePragma.FileName = value;
+            Assert.Equal(value ?? string.Empty, linePragma.FileName);
+        }
 
-               [Theory]
-               [InlineData(-1)]
-               [InlineData(0)]
-               [InlineData(1)]
-               public void LineNumber_Set_Get_ReturnsExpected(int value)
-               {
-                       var linePragma = new CodeLinePragma();
-                       linePragma.LineNumber = value;
-                       Assert.Equal(value, linePragma.LineNumber);
-               }
-       }
+        [Theory]
+        [InlineData(-1)]
+        [InlineData(0)]
+        [InlineData(1)]
+        public void LineNumber_Set_Get_ReturnsExpected(int value)
+        {
+            var linePragma = new CodeLinePragma();
+            linePragma.LineNumber = value;
+            Assert.Equal(value, linePragma.LineNumber);
+        }
+    }
 }
index 9665919..f65a2e0 100644 (file)
@@ -7,45 +7,45 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeMemberEventTests : CodeTypeMemberTestBase<CodeMemberEvent>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var memberEvent = new CodeMemberEvent();
-                       Assert.Equal(typeof(void).FullName, memberEvent.Type.BaseType);
-                       Assert.Empty(memberEvent.ImplementationTypes);
-                       Assert.Null(memberEvent.PrivateImplementationType);
-               }
+    public class CodeMemberEventTests : CodeTypeMemberTestBase<CodeMemberEvent>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var memberEvent = new CodeMemberEvent();
+            Assert.Equal(typeof(void).FullName, memberEvent.Type.BaseType);
+            Assert.Empty(memberEvent.ImplementationTypes);
+            Assert.Null(memberEvent.PrivateImplementationType);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Type_Set_Get_ReturnsExpected(CodeTypeReference type)
-               {
-                       var memberEvent = new CodeMemberEvent() { Type = type };
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, memberEvent.Type.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Type_Set_Get_ReturnsExpected(CodeTypeReference type)
+        {
+            var memberEvent = new CodeMemberEvent() { Type = type };
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, memberEvent.Type.BaseType);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void PrivateImplementationType_Set_Get_ReturnsExpected(CodeTypeReference type)
-               {
-                       var memberEvent = new CodeMemberEvent() { PrivateImplementationType = type };
-                       Assert.Equal(type, memberEvent.PrivateImplementationType);
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void PrivateImplementationType_Set_Get_ReturnsExpected(CodeTypeReference type)
+        {
+            var memberEvent = new CodeMemberEvent() { PrivateImplementationType = type };
+            Assert.Equal(type, memberEvent.PrivateImplementationType);
+        }
 
-               [Fact]
-               public void ImplementationTypes_AddMultiple_ReturnsExpected()
-               {
-                       var memberEvent = new CodeMemberEvent();
+        [Fact]
+        public void ImplementationTypes_AddMultiple_ReturnsExpected()
+        {
+            var memberEvent = new CodeMemberEvent();
 
-                       CodeTypeReference type1 = new CodeTypeReference(typeof(int));
-                       memberEvent.ImplementationTypes.Add(type1);
-                       Assert.Equal(new CodeTypeReference[] { type1 }, memberEvent.ImplementationTypes.Cast<CodeTypeReference>());
+            CodeTypeReference type1 = new CodeTypeReference(typeof(int));
+            memberEvent.ImplementationTypes.Add(type1);
+            Assert.Equal(new CodeTypeReference[] { type1 }, memberEvent.ImplementationTypes.Cast<CodeTypeReference>());
 
-                       CodeTypeReference type2 = new CodeTypeReference(typeof(int));
-                       memberEvent.ImplementationTypes.Add(type2);
-                       Assert.Equal(new CodeTypeReference[] { type1, type2 }, memberEvent.ImplementationTypes.Cast<CodeTypeReference>());
-               }
-       }
+            CodeTypeReference type2 = new CodeTypeReference(typeof(int));
+            memberEvent.ImplementationTypes.Add(type2);
+            Assert.Equal(new CodeTypeReference[] { type1, type2 }, memberEvent.ImplementationTypes.Cast<CodeTypeReference>());
+        }
+    }
 }
index f0d680f..b810ce5 100644 (file)
@@ -7,67 +7,67 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeMemberFieldTests : CodeTypeMemberTestBase<CodeMemberField>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var field = new CodeMemberField();
-                       Assert.Equal(typeof(void).FullName, field.Type.BaseType);
-                       Assert.Null(field.InitExpression);
-               }
+    public class CodeMemberFieldTests : CodeTypeMemberTestBase<CodeMemberField>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var field = new CodeMemberField();
+            Assert.Equal(typeof(void).FullName, field.Type.BaseType);
+            Assert.Null(field.InitExpression);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Ctor_CodeTypeReference_String(CodeTypeReference type)
-               {
-                       var field = new CodeMemberField(type, "name");
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, field.Type.BaseType);
-                       Assert.Equal("name", field.Name);
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Ctor_CodeTypeReference_String(CodeTypeReference type)
+        {
+            var field = new CodeMemberField(type, "name");
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, field.Type.BaseType);
+            Assert.Equal("name", field.Name);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Ctor_Type_String(CodeTypeReference type)
-               {
-                       if (type == null)
-                       {
-                               return;
-                       }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Ctor_Type_String(CodeTypeReference type)
+        {
+            if (type == null)
+            {
+                return;
+            }
 
-                       var field = new CodeMemberField(type.BaseType, "name");
-                       Assert.Equal(type.BaseType, field.Type.BaseType);
-                       Assert.Equal("name", field.Name);
-               }
+            var field = new CodeMemberField(type.BaseType, "name");
+            Assert.Equal(type.BaseType, field.Type.BaseType);
+            Assert.Equal("name", field.Name);
+        }
 
-               [Fact]
-               public void Ctor_Type_String_NullType_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeMemberField((Type)null, "name"));
-               }
+        [Fact]
+        public void Ctor_Type_String_NullType_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeMemberField((Type)null, "name"));
+        }
 
-               public static IEnumerable<object[]> Ctor_String_String_TestData()
-               {
-                       yield return new object[] { null, null, "System.Void" };
-                       yield return new object[] { "", "", "System.Void" };
-                       yield return new object[] { "Int32", "Name", "Int32" };
-               }
+        public static IEnumerable<object[]> Ctor_String_String_TestData()
+        {
+            yield return new object[] { null, null, "System.Void" };
+            yield return new object[] { "", "", "System.Void" };
+            yield return new object[] { "Int32", "Name", "Int32" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_String_String_TestData))]
-               public void Ctor_String_String(string type, string name, string expectedBaseType)
-               {
-                       var field = new CodeMemberField(type, name);
-                       Assert.Equal(expectedBaseType, field.Type.BaseType);
-                       Assert.Equal(name ?? string.Empty, field.Name);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_String_String_TestData))]
+        public void Ctor_String_String(string type, string name, string expectedBaseType)
+        {
+            var field = new CodeMemberField(type, name);
+            Assert.Equal(expectedBaseType, field.Type.BaseType);
+            Assert.Equal(name ?? string.Empty, field.Name);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Type_Set_Get_ReturnsExpected(CodeTypeReference type)
-               {
-                       var field = new CodeMemberField() { Type = type };
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, field.Type.BaseType);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Type_Set_Get_ReturnsExpected(CodeTypeReference type)
+        {
+            var field = new CodeMemberField() { Type = type };
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, field.Type.BaseType);
+        }
+    }
 }
index 5fb90cd..3101b91 100644 (file)
@@ -7,176 +7,176 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeMemberMemberTests : CodeTypeMemberTestBase<CodeMemberMethod>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var method = new CodeMemberMethod();
-                       Assert.Equal(typeof(void).FullName, method.ReturnType.BaseType);
-                       Assert.Empty(method.Statements);
-                       Assert.Empty(method.Parameters);
-
-                       Assert.Empty(method.ImplementationTypes);
-                       Assert.Null(method.PrivateImplementationType);
-
-                       Assert.Empty(method.ReturnTypeCustomAttributes);
-                       Assert.Empty(method.TypeParameters);
-               }
-
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void ReturnType_Set_Get_ReturnsExpected(CodeTypeReference type)
-               {
-                       var method = new CodeMemberMethod() { ReturnType = type };
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, method.ReturnType.BaseType);
-               }
-
-               [Fact]
-               public void Statements_AddMultiple_ReturnsExpected()
-               {
-                       var method = new CodeMemberMethod();
-
-                       CodeStatement statement1 = new CodeCommentStatement("Value1");
-                       method.Statements.Add(statement1);
-                       Assert.Equal(new CodeStatement[] { statement1 }, method.Statements.Cast<CodeStatement>());
-
-                       CodeStatement statement2 = new CodeCommentStatement("Value2");
-                       method.Statements.Add(statement2);
-                       Assert.Equal(new CodeStatement[] { statement1, statement2 }, method.Statements.Cast<CodeStatement>());
-               }
-
-               [Fact]
-               public void Statements_Get_CallsPopulateStatementsOnce()
-               {
-                       var method = new CodeMemberMethod();
-                       bool calledPopulateStatements = false;
-                       method.PopulateStatements += (object sender, EventArgs args) =>
-                       {
-                               calledPopulateStatements = true;
-                               Assert.Same(method, sender);
-                               Assert.Equal(EventArgs.Empty, args);
-                       };
-
-                       CodeStatement statement = new CodeMethodReturnStatement(new CodePrimitiveExpression("Value2"));
-                       method.Statements.Add(statement);
-                       Assert.Equal(new CodeStatement[] { statement }, method.Statements.Cast<CodeStatement>());
-                       Assert.True(calledPopulateStatements);
-
-                       // Only calls PopulateStatements once
-                       calledPopulateStatements = false;
-                       method.Statements.Add(statement);
-                       Assert.False(calledPopulateStatements);
-               }
-
-               [Fact]
-               public void Parameters_AddMultiple_ReturnsExpected()
-               {
-                       var method = new CodeMemberMethod();
-
-                       CodeParameterDeclarationExpression parameter1 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name1");
-                       method.Parameters.Add(parameter1);
-                       Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1 }, method.Parameters.Cast<CodeParameterDeclarationExpression>());
-
-                       CodeParameterDeclarationExpression parameter2 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name2");
-                       method.Parameters.Add(parameter2);
-                       Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1, parameter2 }, method.Parameters.Cast<CodeParameterDeclarationExpression>());
-               }
-
-               [Fact]
-               public void Parameters_Get_CallsPopulateParametersOnce()
-               {
-                       var method = new CodeMemberMethod();
-                       bool calledPopulateParameters = false;
-                       method.PopulateParameters += (object sender, EventArgs args) =>
-                       {
-                               calledPopulateParameters = true;
-                               Assert.Same(method, sender);
-                               Assert.Equal(EventArgs.Empty, args);
-                       };
-
-                       CodeParameterDeclarationExpression parameter = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name1");
-                       method.Parameters.Add(parameter);
-                       Assert.Equal(new CodeParameterDeclarationExpression[] { parameter }, method.Parameters.Cast<CodeParameterDeclarationExpression>());
-                       Assert.True(calledPopulateParameters);
-
-                       // Only calls PopulateParameters once
-                       calledPopulateParameters = false;
-                       method.Parameters.Add(parameter);
-                       Assert.False(calledPopulateParameters);
-               }
-
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void PrivateImplementationType_Set_Get_ReturnsExpected(CodeTypeReference type)
-               {
-                       var method = new CodeMemberMethod() { PrivateImplementationType = type };
-                       Assert.Equal(type, method.PrivateImplementationType);
-               }
-
-               [Fact]
-               public void ImplementationTypes_AddMultiple_ReturnsExpected()
-               {
-                       var method = new CodeMemberMethod();
-
-                       CodeTypeReference type1 = new CodeTypeReference(typeof(int));
-                       method.ImplementationTypes.Add(type1);
-                       Assert.Equal(new CodeTypeReference[] { type1 }, method.ImplementationTypes.Cast<CodeTypeReference>());
-
-                       CodeTypeReference type2 = new CodeTypeReference(typeof(int));
-                       method.ImplementationTypes.Add(type2);
-                       Assert.Equal(new CodeTypeReference[] { type1, type2 }, method.ImplementationTypes.Cast<CodeTypeReference>());
-               }
-
-               [Fact]
-               public void ImplementationTypes_Get_CallsPopulateImplementationTypesOnce()
-               {
-                       var method = new CodeMemberMethod();
-                       bool calledImplementationTypes = false;
-                       method.PopulateImplementationTypes += (object sender, EventArgs args) =>
-                       {
-                               calledImplementationTypes = true;
-                               Assert.Same(method, sender);
-                               Assert.Equal(EventArgs.Empty, args);
-                       };
-
-                       CodeTypeReference type = new CodeTypeReference(typeof(int));
-                       method.ImplementationTypes.Add(type);
-                       Assert.Equal(new CodeTypeReference[] { type }, method.ImplementationTypes.Cast<CodeTypeReference>());
-                       Assert.True(calledImplementationTypes);
-
-                       // Only calls PopulateImplementationTypes once
-                       calledImplementationTypes = false;
-                       method.ImplementationTypes.Add(type);
-                       Assert.False(calledImplementationTypes);
-               }
-
-               [Fact]
-               public void ReturnTypeCustomAttributes_AddMultiple_ReturnsExpected()
-               {
-                       var method = new CodeMemberMethod();
-
-                       CodeAttributeDeclaration attribute1 = new CodeAttributeDeclaration("Name1");
-                       method.ReturnTypeCustomAttributes.Add(attribute1);
-                       Assert.Equal(new CodeAttributeDeclaration[] { attribute1 }, method.ReturnTypeCustomAttributes.Cast<CodeAttributeDeclaration>());
-
-                       CodeAttributeDeclaration attribute2 = new CodeAttributeDeclaration("Name2");
-                       method.ReturnTypeCustomAttributes.Add(attribute2);
-                       Assert.Equal(new CodeAttributeDeclaration[] { attribute1, attribute2 }, method.ReturnTypeCustomAttributes.Cast<CodeAttributeDeclaration>());
-               }
-
-               [Fact]
-               public void TypeParameters_AddMultiple_ReturnsExpected()
-               {
-                       var method = new CodeMemberMethod();
-
-                       CodeTypeParameter parameter1 = new CodeTypeParameter("Name1");
-                       method.TypeParameters.Add(parameter1);
-                       Assert.Equal(new CodeTypeParameter[] { parameter1 }, method.TypeParameters.Cast<CodeTypeParameter>());
-
-                       CodeTypeParameter parameter2 = new CodeTypeParameter("Name2");
-                       method.TypeParameters.Add(parameter2);
-                       Assert.Equal(new CodeTypeParameter[] { parameter1, parameter2 }, method.TypeParameters.Cast<CodeTypeParameter>());
-               }
-       }
+    public class CodeMemberMemberTests : CodeTypeMemberTestBase<CodeMemberMethod>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var method = new CodeMemberMethod();
+            Assert.Equal(typeof(void).FullName, method.ReturnType.BaseType);
+            Assert.Empty(method.Statements);
+            Assert.Empty(method.Parameters);
+
+            Assert.Empty(method.ImplementationTypes);
+            Assert.Null(method.PrivateImplementationType);
+
+            Assert.Empty(method.ReturnTypeCustomAttributes);
+            Assert.Empty(method.TypeParameters);
+        }
+
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void ReturnType_Set_Get_ReturnsExpected(CodeTypeReference type)
+        {
+            var method = new CodeMemberMethod() { ReturnType = type };
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, method.ReturnType.BaseType);
+        }
+
+        [Fact]
+        public void Statements_AddMultiple_ReturnsExpected()
+        {
+            var method = new CodeMemberMethod();
+
+            CodeStatement statement1 = new CodeCommentStatement("Value1");
+            method.Statements.Add(statement1);
+            Assert.Equal(new CodeStatement[] { statement1 }, method.Statements.Cast<CodeStatement>());
+
+            CodeStatement statement2 = new CodeCommentStatement("Value2");
+            method.Statements.Add(statement2);
+            Assert.Equal(new CodeStatement[] { statement1, statement2 }, method.Statements.Cast<CodeStatement>());
+        }
+
+        [Fact]
+        public void Statements_Get_CallsPopulateStatementsOnce()
+        {
+            var method = new CodeMemberMethod();
+            bool calledPopulateStatements = false;
+            method.PopulateStatements += (object sender, EventArgs args) =>
+            {
+                calledPopulateStatements = true;
+                Assert.Same(method, sender);
+                Assert.Equal(EventArgs.Empty, args);
+            };
+
+            CodeStatement statement = new CodeMethodReturnStatement(new CodePrimitiveExpression("Value2"));
+            method.Statements.Add(statement);
+            Assert.Equal(new CodeStatement[] { statement }, method.Statements.Cast<CodeStatement>());
+            Assert.True(calledPopulateStatements);
+
+            // Only calls PopulateStatements once
+            calledPopulateStatements = false;
+            method.Statements.Add(statement);
+            Assert.False(calledPopulateStatements);
+        }
+
+        [Fact]
+        public void Parameters_AddMultiple_ReturnsExpected()
+        {
+            var method = new CodeMemberMethod();
+
+            CodeParameterDeclarationExpression parameter1 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name1");
+            method.Parameters.Add(parameter1);
+            Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1 }, method.Parameters.Cast<CodeParameterDeclarationExpression>());
+
+            CodeParameterDeclarationExpression parameter2 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name2");
+            method.Parameters.Add(parameter2);
+            Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1, parameter2 }, method.Parameters.Cast<CodeParameterDeclarationExpression>());
+        }
+
+        [Fact]
+        public void Parameters_Get_CallsPopulateParametersOnce()
+        {
+            var method = new CodeMemberMethod();
+            bool calledPopulateParameters = false;
+            method.PopulateParameters += (object sender, EventArgs args) =>
+            {
+                calledPopulateParameters = true;
+                Assert.Same(method, sender);
+                Assert.Equal(EventArgs.Empty, args);
+            };
+
+            CodeParameterDeclarationExpression parameter = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name1");
+            method.Parameters.Add(parameter);
+            Assert.Equal(new CodeParameterDeclarationExpression[] { parameter }, method.Parameters.Cast<CodeParameterDeclarationExpression>());
+            Assert.True(calledPopulateParameters);
+
+            // Only calls PopulateParameters once
+            calledPopulateParameters = false;
+            method.Parameters.Add(parameter);
+            Assert.False(calledPopulateParameters);
+        }
+
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void PrivateImplementationType_Set_Get_ReturnsExpected(CodeTypeReference type)
+        {
+            var method = new CodeMemberMethod() { PrivateImplementationType = type };
+            Assert.Equal(type, method.PrivateImplementationType);
+        }
+
+        [Fact]
+        public void ImplementationTypes_AddMultiple_ReturnsExpected()
+        {
+            var method = new CodeMemberMethod();
+
+            CodeTypeReference type1 = new CodeTypeReference(typeof(int));
+            method.ImplementationTypes.Add(type1);
+            Assert.Equal(new CodeTypeReference[] { type1 }, method.ImplementationTypes.Cast<CodeTypeReference>());
+
+            CodeTypeReference type2 = new CodeTypeReference(typeof(int));
+            method.ImplementationTypes.Add(type2);
+            Assert.Equal(new CodeTypeReference[] { type1, type2 }, method.ImplementationTypes.Cast<CodeTypeReference>());
+        }
+
+        [Fact]
+        public void ImplementationTypes_Get_CallsPopulateImplementationTypesOnce()
+        {
+            var method = new CodeMemberMethod();
+            bool calledImplementationTypes = false;
+            method.PopulateImplementationTypes += (object sender, EventArgs args) =>
+            {
+                calledImplementationTypes = true;
+                Assert.Same(method, sender);
+                Assert.Equal(EventArgs.Empty, args);
+            };
+
+            CodeTypeReference type = new CodeTypeReference(typeof(int));
+            method.ImplementationTypes.Add(type);
+            Assert.Equal(new CodeTypeReference[] { type }, method.ImplementationTypes.Cast<CodeTypeReference>());
+            Assert.True(calledImplementationTypes);
+
+            // Only calls PopulateImplementationTypes once
+            calledImplementationTypes = false;
+            method.ImplementationTypes.Add(type);
+            Assert.False(calledImplementationTypes);
+        }
+
+        [Fact]
+        public void ReturnTypeCustomAttributes_AddMultiple_ReturnsExpected()
+        {
+            var method = new CodeMemberMethod();
+
+            CodeAttributeDeclaration attribute1 = new CodeAttributeDeclaration("Name1");
+            method.ReturnTypeCustomAttributes.Add(attribute1);
+            Assert.Equal(new CodeAttributeDeclaration[] { attribute1 }, method.ReturnTypeCustomAttributes.Cast<CodeAttributeDeclaration>());
+
+            CodeAttributeDeclaration attribute2 = new CodeAttributeDeclaration("Name2");
+            method.ReturnTypeCustomAttributes.Add(attribute2);
+            Assert.Equal(new CodeAttributeDeclaration[] { attribute1, attribute2 }, method.ReturnTypeCustomAttributes.Cast<CodeAttributeDeclaration>());
+        }
+
+        [Fact]
+        public void TypeParameters_AddMultiple_ReturnsExpected()
+        {
+            var method = new CodeMemberMethod();
+
+            CodeTypeParameter parameter1 = new CodeTypeParameter("Name1");
+            method.TypeParameters.Add(parameter1);
+            Assert.Equal(new CodeTypeParameter[] { parameter1 }, method.TypeParameters.Cast<CodeTypeParameter>());
+
+            CodeTypeParameter parameter2 = new CodeTypeParameter("Name2");
+            method.TypeParameters.Add(parameter2);
+            Assert.Equal(new CodeTypeParameter[] { parameter1, parameter2 }, method.TypeParameters.Cast<CodeTypeParameter>());
+        }
+    }
 }
index 125400a..df85796 100644 (file)
@@ -7,142 +7,142 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeMemberPropertyTests : CodeTypeMemberTestBase<CodeMemberProperty>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var property = new CodeMemberProperty();
-                       Assert.Equal(typeof(void).FullName, property.Type.BaseType);
-                       Assert.Empty(property.ImplementationTypes);
-                       Assert.Null(property.PrivateImplementationType);
-
-                       Assert.False(property.HasGet);
-                       Assert.Empty(property.GetStatements);
-
-                       Assert.False(property.HasSet);
-                       Assert.Empty(property.SetStatements);
-
-                       Assert.Empty(property.Parameters);
-               }
-
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Type_Set_Get_ReturnsExpected(CodeTypeReference type)
-               {
-                       var property = new CodeMemberProperty() { Type = type };
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, property.Type.BaseType);
-               }
-
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void PrivateImplementationType_Set_Get_ReturnsExpected(CodeTypeReference type)
-               {
-                       var property = new CodeMemberProperty() { PrivateImplementationType = type };
-                       Assert.Equal(type, property.PrivateImplementationType);
-               }
-
-               [Fact]
-               public void HasGet_SetTrue_ReturnsTrue()
-               {
-                       var property = new CodeMemberProperty() { HasGet = true };
-                       Assert.True(property.HasGet);
-               }
-
-               [Fact]
-               public void HasGet_AddedGetStatements_ReturnsTrue()
-               {
-                       var property = new CodeMemberProperty();
-
-                       CodeStatement statement1 = new CodeMethodReturnStatement(new CodePrimitiveExpression("value1"));
-                       property.GetStatements.Add(statement1);
-                       Assert.True(property.HasGet);
-                       Assert.Equal(new CodeStatement[] { statement1 }, property.GetStatements.Cast<CodeStatement>());
-
-                       CodeStatement statement2 = new CodeMethodReturnStatement(new CodePrimitiveExpression("value2"));
-                       property.GetStatements.Add(statement2);
-                       Assert.True(property.HasGet);
-
-                       Assert.Equal(new CodeStatement[] { statement1, statement2 }, property.GetStatements.Cast<CodeStatement>());
-               }
-
-               [Fact]
-               public void HasGet_SetFalse_RemovesAllGetStatements()
-               {
-                       var property = new CodeMemberProperty();
-                       property.HasGet = false;
-                       Assert.False(property.HasGet);
-
-                       property.GetStatements.Add(new CodeMethodReturnStatement(new CodePrimitiveExpression("value")));
-
-                       property.HasGet = false;
-                       Assert.False(property.HasGet);
-                       Assert.Empty(property.GetStatements);
-               }
-
-               [Fact]
-               public void HasSet_SetTrue_ReturnsTrue()
-               {
-                       var property = new CodeMemberProperty() { HasSet = true };
-                       Assert.True(property.HasSet);
-               }
-
-               [Fact]
-               public void HasSet_AddedSetStatements_ReturnsTrue()
-               {
-                       var property = new CodeMemberProperty();
-
-                       CodeStatement statement1 = new CodeMethodReturnStatement(new CodePrimitiveExpression("value1"));
-                       property.SetStatements.Add(statement1);
-                       Assert.True(property.HasSet);
-                       Assert.Equal(new CodeStatement[] { statement1 }, property.SetStatements.Cast<CodeStatement>());
-
-                       CodeStatement statement2 = new CodeMethodReturnStatement(new CodePrimitiveExpression("value2"));
-                       property.SetStatements.Add(statement2);
-                       Assert.True(property.HasSet);
-
-                       Assert.Equal(new CodeStatement[] { statement1, statement2 }, property.SetStatements.Cast<CodeStatement>());
-               }
-
-               [Fact]
-               public void HasSet_SetFalse_RemovesAllSetStatements()
-               {
-                       var property = new CodeMemberProperty();
-                       property.HasSet = false;
-                       Assert.False(property.HasSet);
-
-                       property.SetStatements.Add(new CodeMethodReturnStatement(new CodePrimitiveExpression("value")));
-                       property.HasSet = false;
-                       Assert.False(property.HasSet);
-                       Assert.Empty(property.SetStatements);
-               }
-
-               [Fact]
-               public void Parameters_AddMultiple_ReturnsExpected()
-               {
-                       var property = new CodeMemberProperty();
-
-                       CodeParameterDeclarationExpression parameter1 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name1");
-                       property.Parameters.Add(parameter1);
-                       Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1 }, property.Parameters.Cast<CodeParameterDeclarationExpression>());
-
-                       CodeParameterDeclarationExpression parameter2 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name2");
-                       property.Parameters.Add(parameter2);
-                       Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1, parameter2 }, property.Parameters.Cast<CodeParameterDeclarationExpression>());
-               }
-
-               [Fact]
-               public void ImplementationTypes_AddMultiple_ReturnsExpected()
-               {
-                       var property = new CodeMemberProperty();
-
-                       CodeTypeReference type1 = new CodeTypeReference(typeof(int));
-                       property.ImplementationTypes.Add(type1);
-                       Assert.Equal(new CodeTypeReference[] { type1 }, property.ImplementationTypes.Cast<CodeTypeReference>());
-
-                       CodeTypeReference type2 = new CodeTypeReference(typeof(int));
-                       property.ImplementationTypes.Add(type2);
-                       Assert.Equal(new CodeTypeReference[] { type1, type2 }, property.ImplementationTypes.Cast<CodeTypeReference>());
-               }
-       }
+    public class CodeMemberPropertyTests : CodeTypeMemberTestBase<CodeMemberProperty>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var property = new CodeMemberProperty();
+            Assert.Equal(typeof(void).FullName, property.Type.BaseType);
+            Assert.Empty(property.ImplementationTypes);
+            Assert.Null(property.PrivateImplementationType);
+
+            Assert.False(property.HasGet);
+            Assert.Empty(property.GetStatements);
+
+            Assert.False(property.HasSet);
+            Assert.Empty(property.SetStatements);
+
+            Assert.Empty(property.Parameters);
+        }
+
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Type_Set_Get_ReturnsExpected(CodeTypeReference type)
+        {
+            var property = new CodeMemberProperty() { Type = type };
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, property.Type.BaseType);
+        }
+
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void PrivateImplementationType_Set_Get_ReturnsExpected(CodeTypeReference type)
+        {
+            var property = new CodeMemberProperty() { PrivateImplementationType = type };
+            Assert.Equal(type, property.PrivateImplementationType);
+        }
+
+        [Fact]
+        public void HasGet_SetTrue_ReturnsTrue()
+        {
+            var property = new CodeMemberProperty() { HasGet = true };
+            Assert.True(property.HasGet);
+        }
+
+        [Fact]
+        public void HasGet_AddedGetStatements_ReturnsTrue()
+        {
+            var property = new CodeMemberProperty();
+
+            CodeStatement statement1 = new CodeMethodReturnStatement(new CodePrimitiveExpression("value1"));
+            property.GetStatements.Add(statement1);
+            Assert.True(property.HasGet);
+            Assert.Equal(new CodeStatement[] { statement1 }, property.GetStatements.Cast<CodeStatement>());
+
+            CodeStatement statement2 = new CodeMethodReturnStatement(new CodePrimitiveExpression("value2"));
+            property.GetStatements.Add(statement2);
+            Assert.True(property.HasGet);
+
+            Assert.Equal(new CodeStatement[] { statement1, statement2 }, property.GetStatements.Cast<CodeStatement>());
+        }
+
+        [Fact]
+        public void HasGet_SetFalse_RemovesAllGetStatements()
+        {
+            var property = new CodeMemberProperty();
+            property.HasGet = false;
+            Assert.False(property.HasGet);
+
+            property.GetStatements.Add(new CodeMethodReturnStatement(new CodePrimitiveExpression("value")));
+
+            property.HasGet = false;
+            Assert.False(property.HasGet);
+            Assert.Empty(property.GetStatements);
+        }
+
+        [Fact]
+        public void HasSet_SetTrue_ReturnsTrue()
+        {
+            var property = new CodeMemberProperty() { HasSet = true };
+            Assert.True(property.HasSet);
+        }
+
+        [Fact]
+        public void HasSet_AddedSetStatements_ReturnsTrue()
+        {
+            var property = new CodeMemberProperty();
+
+            CodeStatement statement1 = new CodeMethodReturnStatement(new CodePrimitiveExpression("value1"));
+            property.SetStatements.Add(statement1);
+            Assert.True(property.HasSet);
+            Assert.Equal(new CodeStatement[] { statement1 }, property.SetStatements.Cast<CodeStatement>());
+
+            CodeStatement statement2 = new CodeMethodReturnStatement(new CodePrimitiveExpression("value2"));
+            property.SetStatements.Add(statement2);
+            Assert.True(property.HasSet);
+
+            Assert.Equal(new CodeStatement[] { statement1, statement2 }, property.SetStatements.Cast<CodeStatement>());
+        }
+
+        [Fact]
+        public void HasSet_SetFalse_RemovesAllSetStatements()
+        {
+            var property = new CodeMemberProperty();
+            property.HasSet = false;
+            Assert.False(property.HasSet);
+
+            property.SetStatements.Add(new CodeMethodReturnStatement(new CodePrimitiveExpression("value")));
+            property.HasSet = false;
+            Assert.False(property.HasSet);
+            Assert.Empty(property.SetStatements);
+        }
+
+        [Fact]
+        public void Parameters_AddMultiple_ReturnsExpected()
+        {
+            var property = new CodeMemberProperty();
+
+            CodeParameterDeclarationExpression parameter1 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name1");
+            property.Parameters.Add(parameter1);
+            Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1 }, property.Parameters.Cast<CodeParameterDeclarationExpression>());
+
+            CodeParameterDeclarationExpression parameter2 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name2");
+            property.Parameters.Add(parameter2);
+            Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1, parameter2 }, property.Parameters.Cast<CodeParameterDeclarationExpression>());
+        }
+
+        [Fact]
+        public void ImplementationTypes_AddMultiple_ReturnsExpected()
+        {
+            var property = new CodeMemberProperty();
+
+            CodeTypeReference type1 = new CodeTypeReference(typeof(int));
+            property.ImplementationTypes.Add(type1);
+            Assert.Equal(new CodeTypeReference[] { type1 }, property.ImplementationTypes.Cast<CodeTypeReference>());
+
+            CodeTypeReference type2 = new CodeTypeReference(typeof(int));
+            property.ImplementationTypes.Add(type2);
+            Assert.Equal(new CodeTypeReference[] { type1, type2 }, property.ImplementationTypes.Cast<CodeTypeReference>());
+        }
+    }
 }
index 9992b01..ffa1efd 100644 (file)
@@ -8,93 +8,93 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeMethodInvokeExpressionTests : CodeObjectTestBase<CodeMethodInvokeExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var methodInvoke = new CodeMethodInvokeExpression();
-                       Assert.Null(methodInvoke.Method.TargetObject);
-                       Assert.Empty(methodInvoke.Method.MethodName);
-                       Assert.Empty(methodInvoke.Parameters);
-               }
+    public class CodeMethodInvokeExpressionTests : CodeObjectTestBase<CodeMethodInvokeExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var methodInvoke = new CodeMethodInvokeExpression();
+            Assert.Null(methodInvoke.Method.TargetObject);
+            Assert.Empty(methodInvoke.Method.MethodName);
+            Assert.Empty(methodInvoke.Parameters);
+        }
 
-               public static IEnumerable<object[]> Ctor_CodeMethodReferenceExpression_ParamsCodeExpression_TestData()
-               {
-                       yield return new object[] { null, new CodeExpression[0] };
-                       yield return new object[] { new CodeMethodReferenceExpression(), new CodeExpression[0] };
-                       yield return new object[] { new CodeMethodReferenceExpression(new CodePrimitiveExpression("Value"), "Length"), new CodeExpression[] { new CodePrimitiveExpression("Value") } };
-               }
+        public static IEnumerable<object[]> Ctor_CodeMethodReferenceExpression_ParamsCodeExpression_TestData()
+        {
+            yield return new object[] { null, new CodeExpression[0] };
+            yield return new object[] { new CodeMethodReferenceExpression(), new CodeExpression[0] };
+            yield return new object[] { new CodeMethodReferenceExpression(new CodePrimitiveExpression("Value"), "Length"), new CodeExpression[] { new CodePrimitiveExpression("Value") } };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_CodeMethodReferenceExpression_ParamsCodeExpression_TestData))]
-               public void Ctor(CodeMethodReferenceExpression method, CodeExpression[] parameters)
-               {
-                       var methodInvoke = new CodeMethodInvokeExpression(method, parameters);
-                       Assert.Equal((method ?? new CodeMethodReferenceExpression()).TargetObject, methodInvoke.Method.TargetObject);
-                       Assert.Equal((method ?? new CodeMethodReferenceExpression()).MethodName, methodInvoke.Method.MethodName);
-                       Assert.Equal(parameters, methodInvoke.Parameters.Cast<CodeExpression>());
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_CodeMethodReferenceExpression_ParamsCodeExpression_TestData))]
+        public void Ctor(CodeMethodReferenceExpression method, CodeExpression[] parameters)
+        {
+            var methodInvoke = new CodeMethodInvokeExpression(method, parameters);
+            Assert.Equal((method ?? new CodeMethodReferenceExpression()).TargetObject, methodInvoke.Method.TargetObject);
+            Assert.Equal((method ?? new CodeMethodReferenceExpression()).MethodName, methodInvoke.Method.MethodName);
+            Assert.Equal(parameters, methodInvoke.Parameters.Cast<CodeExpression>());
+        }
 
-               public static IEnumerable<object[]> Ctor_CodeExpression_String_ParamsCodeExpression_TestData()
-               {
-                       yield return new object[] { null, null, new CodeExpression[0] };
-                       yield return new object[] { new CodeExpression(), "", new CodeExpression[0] };
-                       yield return new object[] { new CodePrimitiveExpression("Value"), "Length", new CodeExpression[] { new CodePrimitiveExpression("Value") } };
-               }
+        public static IEnumerable<object[]> Ctor_CodeExpression_String_ParamsCodeExpression_TestData()
+        {
+            yield return new object[] { null, null, new CodeExpression[0] };
+            yield return new object[] { new CodeExpression(), "", new CodeExpression[0] };
+            yield return new object[] { new CodePrimitiveExpression("Value"), "Length", new CodeExpression[] { new CodePrimitiveExpression("Value") } };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_CodeExpression_String_ParamsCodeExpression_TestData))]
-               public void Ctor(CodeExpression targetObject, string methodName, CodeExpression[] parameters)
-               {
-                       var methodInvoke = new CodeMethodInvokeExpression(targetObject, methodName, parameters);
-                       Assert.Equal(targetObject, methodInvoke.Method.TargetObject);
-                       Assert.Equal(methodName ?? string.Empty, methodInvoke.Method.MethodName);
-                       Assert.Equal(parameters, methodInvoke.Parameters.Cast<CodeExpression>());
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_CodeExpression_String_ParamsCodeExpression_TestData))]
+        public void Ctor(CodeExpression targetObject, string methodName, CodeExpression[] parameters)
+        {
+            var methodInvoke = new CodeMethodInvokeExpression(targetObject, methodName, parameters);
+            Assert.Equal(targetObject, methodInvoke.Method.TargetObject);
+            Assert.Equal(methodName ?? string.Empty, methodInvoke.Method.MethodName);
+            Assert.Equal(parameters, methodInvoke.Parameters.Cast<CodeExpression>());
+        }
 
-               [Fact]
-               public void Ctor_NullParameters_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeMethodInvokeExpression(new CodeMethodReferenceExpression(), null));
-               }
+        [Fact]
+        public void Ctor_NullParameters_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeMethodInvokeExpression(new CodeMethodReferenceExpression(), null));
+        }
 
-               [Fact]
-               public void Ctor_NullObjectInParameters_ThrowsArgumentNullException()
-               {
-                       CodeExpression[] parameters = new CodeExpression[] { null };
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeMethodInvokeExpression(new CodeMethodReferenceExpression(), parameters));
-               }
+        [Fact]
+        public void Ctor_NullObjectInParameters_ThrowsArgumentNullException()
+        {
+            CodeExpression[] parameters = new CodeExpression[] { null };
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeMethodInvokeExpression(new CodeMethodReferenceExpression(), parameters));
+        }
 
-               public static IEnumerable<object[]> CodeMethodReferenceExpression_TestData()
-               {
-                       yield return new object[] { null };
-                       yield return new object[] { new CodeMethodReferenceExpression() };
-                       yield return new object[] { new CodeMethodReferenceExpression(new CodePrimitiveExpression("Value"), "Length") };
-               }
+        public static IEnumerable<object[]> CodeMethodReferenceExpression_TestData()
+        {
+            yield return new object[] { null };
+            yield return new object[] { new CodeMethodReferenceExpression() };
+            yield return new object[] { new CodeMethodReferenceExpression(new CodePrimitiveExpression("Value"), "Length") };
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeMethodReferenceExpression_TestData))]
-               public void Method_Set_Get_ReturnsExpected(CodeMethodReferenceExpression value)
-               {
-                       var methodInvoke = new CodeMethodInvokeExpression();
-                       methodInvoke.Method = value;
-                       Assert.Equal(value?.MethodName ?? string.Empty, methodInvoke.Method.MethodName);
-                       Assert.Equal(value?.TargetObject, methodInvoke.Method.TargetObject);
-               }
+        [Theory]
+        [MemberData(nameof(CodeMethodReferenceExpression_TestData))]
+        public void Method_Set_Get_ReturnsExpected(CodeMethodReferenceExpression value)
+        {
+            var methodInvoke = new CodeMethodInvokeExpression();
+            methodInvoke.Method = value;
+            Assert.Equal(value?.MethodName ?? string.Empty, methodInvoke.Method.MethodName);
+            Assert.Equal(value?.TargetObject, methodInvoke.Method.TargetObject);
+        }
 
-               [Fact]
-               public void Parameters_AddMultiple_ReturnsExpected()
-               {
-                       var methodInvoke = new CodeMethodInvokeExpression();
+        [Fact]
+        public void Parameters_AddMultiple_ReturnsExpected()
+        {
+            var methodInvoke = new CodeMethodInvokeExpression();
 
-                       CodeExpression expression1 = new CodePrimitiveExpression("Value1");
-                       methodInvoke.Parameters.Add(expression1);
-                       Assert.Equal(new CodeExpression[] { expression1 }, methodInvoke.Parameters.Cast<CodeExpression>());
+            CodeExpression expression1 = new CodePrimitiveExpression("Value1");
+            methodInvoke.Parameters.Add(expression1);
+            Assert.Equal(new CodeExpression[] { expression1 }, methodInvoke.Parameters.Cast<CodeExpression>());
 
-                       CodeExpression expression2 = new CodePrimitiveExpression("Value2");
-                       methodInvoke.Parameters.Add(expression2);
-                       Assert.Equal(new CodeExpression[] { expression1, expression2 }, methodInvoke.Parameters.Cast<CodeExpression>());
-               }
-       }
+            CodeExpression expression2 = new CodePrimitiveExpression("Value2");
+            methodInvoke.Parameters.Add(expression2);
+            Assert.Equal(new CodeExpression[] { expression1, expression2 }, methodInvoke.Parameters.Cast<CodeExpression>());
+        }
+    }
 }
index 3398e64..db9b014 100644 (file)
@@ -8,87 +8,87 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeMethodReferenceExpressionTests : CodeObjectTestBase<CodeMethodReferenceExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var methodReference = new CodeMethodReferenceExpression();
-                       Assert.Empty(methodReference.MethodName);
-                       Assert.Null(methodReference.TargetObject);
-                       Assert.Empty(methodReference.TypeArguments);
-               }
+    public class CodeMethodReferenceExpressionTests : CodeObjectTestBase<CodeMethodReferenceExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var methodReference = new CodeMethodReferenceExpression();
+            Assert.Empty(methodReference.MethodName);
+            Assert.Null(methodReference.TargetObject);
+            Assert.Empty(methodReference.TypeArguments);
+        }
 
-               public static IEnumerable<object[]> Ctor_CodeExpression_String_TestData()
-               {
-                       yield return new object[] { null, null };
-                       yield return new object[] { new CodePrimitiveExpression(), "" };
-                       yield return new object[] { new CodePrimitiveExpression("Value"), "Length" };
-               }
+        public static IEnumerable<object[]> Ctor_CodeExpression_String_TestData()
+        {
+            yield return new object[] { null, null };
+            yield return new object[] { new CodePrimitiveExpression(), "" };
+            yield return new object[] { new CodePrimitiveExpression("Value"), "Length" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_CodeExpression_String_TestData))]
-               public void Ctor(CodeExpression targetObject, string methodName)
-               {
-                       var methodReference = new CodeMethodReferenceExpression(targetObject, methodName);
-                       Assert.Equal(targetObject, methodReference.TargetObject);
-                       Assert.Equal(methodName ?? string.Empty, methodReference.MethodName);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_CodeExpression_String_TestData))]
+        public void Ctor(CodeExpression targetObject, string methodName)
+        {
+            var methodReference = new CodeMethodReferenceExpression(targetObject, methodName);
+            Assert.Equal(targetObject, methodReference.TargetObject);
+            Assert.Equal(methodName ?? string.Empty, methodReference.MethodName);
+        }
 
-               public static IEnumerable<object[]> Ctor_CodeExpression_String_ParamsCodeExpression_TestData()
-               {
-                       yield return new object[] { null, null, null };
-                       yield return new object[] { new CodePrimitiveExpression(), "", new CodeTypeReference[0] };
-                       yield return new object[] { new CodePrimitiveExpression("Value"), "Length", new CodeTypeReference[] { new CodeTypeReference(typeof(void)) } };
-               }
+        public static IEnumerable<object[]> Ctor_CodeExpression_String_ParamsCodeExpression_TestData()
+        {
+            yield return new object[] { null, null, null };
+            yield return new object[] { new CodePrimitiveExpression(), "", new CodeTypeReference[0] };
+            yield return new object[] { new CodePrimitiveExpression("Value"), "Length", new CodeTypeReference[] { new CodeTypeReference(typeof(void)) } };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_CodeExpression_String_ParamsCodeExpression_TestData))]
-               public void Ctor(CodeExpression targetObject, string methodName, CodeTypeReference[] typeArguments)
-               {
-                       var methodReference = new CodeMethodReferenceExpression(targetObject, methodName, typeArguments);
-                       Assert.Equal(targetObject, methodReference.TargetObject);
-                       Assert.Equal(methodName ?? string.Empty, methodReference.MethodName);
-                       Assert.Equal(typeArguments ?? new CodeTypeReference[0], methodReference.TypeArguments.Cast<CodeTypeReference>());
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_CodeExpression_String_ParamsCodeExpression_TestData))]
+        public void Ctor(CodeExpression targetObject, string methodName, CodeTypeReference[] typeArguments)
+        {
+            var methodReference = new CodeMethodReferenceExpression(targetObject, methodName, typeArguments);
+            Assert.Equal(targetObject, methodReference.TargetObject);
+            Assert.Equal(methodName ?? string.Empty, methodReference.MethodName);
+            Assert.Equal(typeArguments ?? new CodeTypeReference[0], methodReference.TypeArguments.Cast<CodeTypeReference>());
+        }
 
-               [Fact]
-               public void Ctor_NullObjectInParameters_ThrowsArgumentNullException()
-               {
-                       CodeTypeReference[] parameters = new CodeTypeReference[] { null };
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeMethodReferenceExpression(new CodePrimitiveExpression(), "", parameters));
-               }
+        [Fact]
+        public void Ctor_NullObjectInParameters_ThrowsArgumentNullException()
+        {
+            CodeTypeReference[] parameters = new CodeTypeReference[] { null };
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeMethodReferenceExpression(new CodePrimitiveExpression(), "", parameters));
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var methodReference = new CodeMethodReferenceExpression();
-                       methodReference.TargetObject = value;
-                       Assert.Equal(value, methodReference.TargetObject);
-               }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var methodReference = new CodeMethodReferenceExpression();
+            methodReference.TargetObject = value;
+            Assert.Equal(value, methodReference.TargetObject);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void MethodName_Set_Get_ReturnsExpected(string value)
-               {
-                       var methodReference = new CodeMethodReferenceExpression();
-                       methodReference.MethodName = value;
-                       Assert.Equal(value ?? string.Empty, methodReference.MethodName);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void MethodName_Set_Get_ReturnsExpected(string value)
+        {
+            var methodReference = new CodeMethodReferenceExpression();
+            methodReference.MethodName = value;
+            Assert.Equal(value ?? string.Empty, methodReference.MethodName);
+        }
 
-               [Fact]
-               public void TypeArguments_AddMultiple_ReturnsExpected()
-               {
-                       var methodReference = new CodeMethodReferenceExpression();
+        [Fact]
+        public void TypeArguments_AddMultiple_ReturnsExpected()
+        {
+            var methodReference = new CodeMethodReferenceExpression();
 
-                       CodeTypeReference type1 = new CodeTypeReference(typeof(int));
-                       methodReference.TypeArguments.Add(type1);
-                       Assert.Equal(new CodeTypeReference[] { type1 }, methodReference.TypeArguments.Cast<CodeTypeReference>());
+            CodeTypeReference type1 = new CodeTypeReference(typeof(int));
+            methodReference.TypeArguments.Add(type1);
+            Assert.Equal(new CodeTypeReference[] { type1 }, methodReference.TypeArguments.Cast<CodeTypeReference>());
 
-                       CodeTypeReference type2 = new CodeTypeReference(typeof(char));
-                       methodReference.TypeArguments.Add(type2);
-                       Assert.Equal(new CodeTypeReference[] { type1, type2 }, methodReference.TypeArguments.Cast<CodeTypeReference>());
-               }
-       }
+            CodeTypeReference type2 = new CodeTypeReference(typeof(char));
+            methodReference.TypeArguments.Add(type2);
+            Assert.Equal(new CodeTypeReference[] { type1, type2 }, methodReference.TypeArguments.Cast<CodeTypeReference>());
+        }
+    }
 }
index 4a30637..978ee1b 100644 (file)
@@ -6,30 +6,30 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeMethodReturnStatementTests : CodeStatementTestBase<CodeMethodReturnStatement>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var methodReturn = new CodeMethodReturnStatement();
-                       Assert.Null(methodReturn.Expression);
-               }
+    public class CodeMethodReturnStatementTests : CodeStatementTestBase<CodeMethodReturnStatement>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var methodReturn = new CodeMethodReturnStatement();
+            Assert.Null(methodReturn.Expression);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Ctor_CodeExpression(CodeExpression expression)
-               {
-                       var methodReturn = new CodeMethodReturnStatement(expression);
-                       Assert.Equal(expression, methodReturn.Expression);
-               }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Ctor_CodeExpression(CodeExpression expression)
+        {
+            var methodReturn = new CodeMethodReturnStatement(expression);
+            Assert.Equal(expression, methodReturn.Expression);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Expression_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var methodReturn = new CodeMethodReturnStatement();
-                       methodReturn.Expression = value;
-                       Assert.Equal(value, methodReturn.Expression);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Expression_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var methodReturn = new CodeMethodReturnStatement();
+            methodReturn.Expression = value;
+            Assert.Equal(value, methodReturn.Expression);
+        }
+    }
 }
index ab12426..e426b6e 100644 (file)
@@ -6,41 +6,41 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeNamespaceImportTests : CodeObjectTestBase<CodeNamespaceImport>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var import = new CodeNamespaceImport();
-                       Assert.Empty(import.Namespace);
-                       Assert.Null(import.LinePragma);
-               }
+    public class CodeNamespaceImportTests : CodeObjectTestBase<CodeNamespaceImport>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var import = new CodeNamespaceImport();
+            Assert.Empty(import.Namespace);
+            Assert.Null(import.LinePragma);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Ctor_String(string nameSpace)
-               {
-                       var import = new CodeNamespaceImport(nameSpace);
-                       Assert.Equal(nameSpace ?? string.Empty, import.Namespace);
-                       Assert.Null(import.LinePragma);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Ctor_String(string nameSpace)
+        {
+            var import = new CodeNamespaceImport(nameSpace);
+            Assert.Equal(nameSpace ?? string.Empty, import.Namespace);
+            Assert.Null(import.LinePragma);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Namespace_Set_Get_ReturnsExpected(string value)
-               {
-                       var import = new CodeNamespaceImport();
-                       import.Namespace = value;
-                       Assert.Equal(value ?? string.Empty, import.Namespace);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Namespace_Set_Get_ReturnsExpected(string value)
+        {
+            var import = new CodeNamespaceImport();
+            import.Namespace = value;
+            Assert.Equal(value ?? string.Empty, import.Namespace);
+        }
 
-               [Theory]
-               [MemberData(nameof(LinePragma_TestData))]
-               public void LinePragma_Set_Get_ReturnsExpected(CodeLinePragma value)
-               {
-                       var import = new CodeNamespaceImport();
-                       import.LinePragma = value;
-                       Assert.Equal(value, import.LinePragma);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(LinePragma_TestData))]
+        public void LinePragma_Set_Get_ReturnsExpected(CodeLinePragma value)
+        {
+            var import = new CodeNamespaceImport();
+            import.LinePragma = value;
+            Assert.Equal(value, import.LinePragma);
+        }
+    }
 }
index 53341aa..c3b67b3 100644 (file)
@@ -7,149 +7,149 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeNamespaceTests : CodeObjectTestBase<CodeNamespace>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var codeNamespace = new CodeNamespace();
-                       Assert.Empty(codeNamespace.Name);
-                       Assert.Empty(codeNamespace.Types);
-                       Assert.Empty(codeNamespace.Imports);
-                       Assert.Empty(codeNamespace.Comments);
-               }
-
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Ctor_String(string name)
-               {
-                       var codeNamespace = new CodeNamespace(name);
-                       Assert.Equal(name ?? string.Empty, codeNamespace.Name);
-                       Assert.Empty(codeNamespace.Types);
-                       Assert.Empty(codeNamespace.Imports);
-                       Assert.Empty(codeNamespace.Comments);
-               }
-
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Name_Set_Get_ReturnsExpected(string value)
-               {
-                       var codeNamespace = new CodeNamespace();
-                       codeNamespace.Name = value;
-                       Assert.Equal(value ?? string.Empty, codeNamespace.Name);
-               }
-
-               [Fact]
-               public void Types_AddMultiple_ReturnsExpected()
-               {
-                       var codeNamespace = new CodeNamespace();
-
-                       CodeTypeDeclaration type1 = new CodeTypeDeclaration("Name1");
-                       codeNamespace.Types.Add(type1);
-                       Assert.Equal(new CodeTypeDeclaration[] { type1 }, codeNamespace.Types.Cast<CodeTypeDeclaration>());
-
-                       CodeTypeDeclaration type2 = new CodeTypeDeclaration("Name2");
-                       codeNamespace.Types.Add(type2);
-                       Assert.Equal(new CodeTypeDeclaration[] { type1, type2 }, codeNamespace.Types.Cast<CodeTypeDeclaration>());
-               }
-
-               [Fact]
-               public void Types_Get_CallsPopulateTypesOnce()
-               {
-                       var codeNamespace = new CodeNamespace();
-                       bool calledPopulateTypes = false;
-                       codeNamespace.PopulateTypes += (object sender, EventArgs args) =>
-                       {
-                               calledPopulateTypes = true;
-                               Assert.Same(codeNamespace, sender);
-                               Assert.Equal(EventArgs.Empty, args);
-                       };
-
-                       codeNamespace.Types.Add(new CodeTypeDeclaration("Name1"));
-                       Assert.True(calledPopulateTypes);
-
-                       // Only calls PopulateTypes once
-                       calledPopulateTypes = false;
-                       codeNamespace.Types.Add(new CodeTypeDeclaration("Name2"));
-                       Assert.False(calledPopulateTypes);
-               }
-
-               [Fact]
-               public void Imports_AddMultiple_ReturnsExpected()
-               {
-                       var codeNamespace = new CodeNamespace();
-
-                       CodeNamespaceImport type1 = new CodeNamespaceImport("Namespace1");
-                       codeNamespace.Imports.Add(type1);
-                       Assert.Equal(new CodeNamespaceImport[] { type1 }, codeNamespace.Imports.Cast<CodeNamespaceImport>());
-
-                       CodeNamespaceImport type2 = new CodeNamespaceImport("Namespace2");
-                       codeNamespace.Imports.Add(type2);
-                       Assert.Equal(new CodeNamespaceImport[] { type1, type2 }, codeNamespace.Imports.Cast<CodeNamespaceImport>());
-               }
-
-               [Fact]
-               public void Imports_Get_CallsPopulateImportsOnce()
-               {
-                       var codeNamespace = new CodeNamespace();
-                       bool calledPopulateImports = false;
-                       codeNamespace.PopulateImports += (object sender, EventArgs args) =>
-                       {
-                               calledPopulateImports = true;
-                               Assert.Same(codeNamespace, sender);
-                               Assert.Equal(EventArgs.Empty, args);
-                       };
-
-                       CodeNamespaceImport type1 = new CodeNamespaceImport("Namespace1");
-                       codeNamespace.Imports.Add(type1);
-                       Assert.Equal(new CodeNamespaceImport[] { type1 }, codeNamespace.Imports.Cast<CodeNamespaceImport>());
-                       Assert.True(calledPopulateImports);
-
-                       // Only calls PopulateImports once
-                       calledPopulateImports = false;
-                       CodeNamespaceImport type2 = new CodeNamespaceImport("Namespace2");
-                       codeNamespace.Imports.Add(type2);
-                       Assert.Equal(new CodeNamespaceImport[] { type1, type2 }, codeNamespace.Imports.Cast<CodeNamespaceImport>());
-                       Assert.False(calledPopulateImports);
-               }
-
-               [Fact]
-               public void Comments_AddMultiple_ReturnsExpected()
-               {
-                       var codeNamespace = new CodeNamespace();
-
-                       CodeCommentStatement comment1 = new CodeCommentStatement("Comment1");
-                       codeNamespace.Comments.Add(comment1);
-                       Assert.Equal(new CodeCommentStatement[] { comment1 }, codeNamespace.Comments.Cast<CodeCommentStatement>());
-
-                       CodeCommentStatement comment2 = new CodeCommentStatement("Comment2");
-                       codeNamespace.Comments.Add(comment2);
-                       Assert.Equal(new CodeCommentStatement[] { comment1, comment2 }, codeNamespace.Comments.Cast<CodeCommentStatement>());
-               }
-
-               [Fact]
-               public void Comments_Get_CallsPopulateImportsONce()
-               {
-                       var codeNamespace = new CodeNamespace();
-                       bool calledPopulateComments = false;
-                       codeNamespace.PopulateComments += (object sender, EventArgs args) =>
-                       {
-                               calledPopulateComments = true;
-                               Assert.Same(codeNamespace, sender);
-                               Assert.Equal(EventArgs.Empty, args);
-                       };
-
-                       CodeCommentStatement comment1 = new CodeCommentStatement("Comment1");
-                       codeNamespace.Comments.Add(comment1);
-                       Assert.Equal(new CodeCommentStatement[] { comment1 }, codeNamespace.Comments.Cast<CodeCommentStatement>());
-                       Assert.True(calledPopulateComments);
-
-                       // Only calls PopulateComments once
-                       calledPopulateComments = false;
-                       CodeCommentStatement comment2 = new CodeCommentStatement("Comment2");
-                       codeNamespace.Comments.Add(comment2);
-                       Assert.Equal(new CodeCommentStatement[] { comment1, comment2 }, codeNamespace.Comments.Cast<CodeCommentStatement>());
-                       Assert.False(calledPopulateComments);
-               }
-       }
+    public class CodeNamespaceTests : CodeObjectTestBase<CodeNamespace>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var codeNamespace = new CodeNamespace();
+            Assert.Empty(codeNamespace.Name);
+            Assert.Empty(codeNamespace.Types);
+            Assert.Empty(codeNamespace.Imports);
+            Assert.Empty(codeNamespace.Comments);
+        }
+
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Ctor_String(string name)
+        {
+            var codeNamespace = new CodeNamespace(name);
+            Assert.Equal(name ?? string.Empty, codeNamespace.Name);
+            Assert.Empty(codeNamespace.Types);
+            Assert.Empty(codeNamespace.Imports);
+            Assert.Empty(codeNamespace.Comments);
+        }
+
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Name_Set_Get_ReturnsExpected(string value)
+        {
+            var codeNamespace = new CodeNamespace();
+            codeNamespace.Name = value;
+            Assert.Equal(value ?? string.Empty, codeNamespace.Name);
+        }
+
+        [Fact]
+        public void Types_AddMultiple_ReturnsExpected()
+        {
+            var codeNamespace = new CodeNamespace();
+
+            CodeTypeDeclaration type1 = new CodeTypeDeclaration("Name1");
+            codeNamespace.Types.Add(type1);
+            Assert.Equal(new CodeTypeDeclaration[] { type1 }, codeNamespace.Types.Cast<CodeTypeDeclaration>());
+
+            CodeTypeDeclaration type2 = new CodeTypeDeclaration("Name2");
+            codeNamespace.Types.Add(type2);
+            Assert.Equal(new CodeTypeDeclaration[] { type1, type2 }, codeNamespace.Types.Cast<CodeTypeDeclaration>());
+        }
+
+        [Fact]
+        public void Types_Get_CallsPopulateTypesOnce()
+        {
+            var codeNamespace = new CodeNamespace();
+            bool calledPopulateTypes = false;
+            codeNamespace.PopulateTypes += (object sender, EventArgs args) =>
+            {
+                calledPopulateTypes = true;
+                Assert.Same(codeNamespace, sender);
+                Assert.Equal(EventArgs.Empty, args);
+            };
+
+            codeNamespace.Types.Add(new CodeTypeDeclaration("Name1"));
+            Assert.True(calledPopulateTypes);
+
+            // Only calls PopulateTypes once
+            calledPopulateTypes = false;
+            codeNamespace.Types.Add(new CodeTypeDeclaration("Name2"));
+            Assert.False(calledPopulateTypes);
+        }
+
+        [Fact]
+        public void Imports_AddMultiple_ReturnsExpected()
+        {
+            var codeNamespace = new CodeNamespace();
+
+            CodeNamespaceImport type1 = new CodeNamespaceImport("Namespace1");
+            codeNamespace.Imports.Add(type1);
+            Assert.Equal(new CodeNamespaceImport[] { type1 }, codeNamespace.Imports.Cast<CodeNamespaceImport>());
+
+            CodeNamespaceImport type2 = new CodeNamespaceImport("Namespace2");
+            codeNamespace.Imports.Add(type2);
+            Assert.Equal(new CodeNamespaceImport[] { type1, type2 }, codeNamespace.Imports.Cast<CodeNamespaceImport>());
+        }
+
+        [Fact]
+        public void Imports_Get_CallsPopulateImportsOnce()
+        {
+            var codeNamespace = new CodeNamespace();
+            bool calledPopulateImports = false;
+            codeNamespace.PopulateImports += (object sender, EventArgs args) =>
+            {
+                calledPopulateImports = true;
+                Assert.Same(codeNamespace, sender);
+                Assert.Equal(EventArgs.Empty, args);
+            };
+
+            CodeNamespaceImport type1 = new CodeNamespaceImport("Namespace1");
+            codeNamespace.Imports.Add(type1);
+            Assert.Equal(new CodeNamespaceImport[] { type1 }, codeNamespace.Imports.Cast<CodeNamespaceImport>());
+            Assert.True(calledPopulateImports);
+
+            // Only calls PopulateImports once
+            calledPopulateImports = false;
+            CodeNamespaceImport type2 = new CodeNamespaceImport("Namespace2");
+            codeNamespace.Imports.Add(type2);
+            Assert.Equal(new CodeNamespaceImport[] { type1, type2 }, codeNamespace.Imports.Cast<CodeNamespaceImport>());
+            Assert.False(calledPopulateImports);
+        }
+
+        [Fact]
+        public void Comments_AddMultiple_ReturnsExpected()
+        {
+            var codeNamespace = new CodeNamespace();
+
+            CodeCommentStatement comment1 = new CodeCommentStatement("Comment1");
+            codeNamespace.Comments.Add(comment1);
+            Assert.Equal(new CodeCommentStatement[] { comment1 }, codeNamespace.Comments.Cast<CodeCommentStatement>());
+
+            CodeCommentStatement comment2 = new CodeCommentStatement("Comment2");
+            codeNamespace.Comments.Add(comment2);
+            Assert.Equal(new CodeCommentStatement[] { comment1, comment2 }, codeNamespace.Comments.Cast<CodeCommentStatement>());
+        }
+
+        [Fact]
+        public void Comments_Get_CallsPopulateImportsONce()
+        {
+            var codeNamespace = new CodeNamespace();
+            bool calledPopulateComments = false;
+            codeNamespace.PopulateComments += (object sender, EventArgs args) =>
+            {
+                calledPopulateComments = true;
+                Assert.Same(codeNamespace, sender);
+                Assert.Equal(EventArgs.Empty, args);
+            };
+
+            CodeCommentStatement comment1 = new CodeCommentStatement("Comment1");
+            codeNamespace.Comments.Add(comment1);
+            Assert.Equal(new CodeCommentStatement[] { comment1 }, codeNamespace.Comments.Cast<CodeCommentStatement>());
+            Assert.True(calledPopulateComments);
+
+            // Only calls PopulateComments once
+            calledPopulateComments = false;
+            CodeCommentStatement comment2 = new CodeCommentStatement("Comment2");
+            codeNamespace.Comments.Add(comment2);
+            Assert.Equal(new CodeCommentStatement[] { comment1, comment2 }, codeNamespace.Comments.Cast<CodeCommentStatement>());
+            Assert.False(calledPopulateComments);
+        }
+    }
 }
index dae170a..8a7a160 100644 (file)
@@ -8,103 +8,103 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeObjectCreateExpressionTests : CodeObjectTestBase<CodeObjectCreateExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var objectCreate = new CodeObjectCreateExpression();
-                       Assert.Equal(typeof(void).FullName, objectCreate.CreateType.BaseType);
-                       Assert.Empty(objectCreate.Parameters);
-               }
+    public class CodeObjectCreateExpressionTests : CodeObjectTestBase<CodeObjectCreateExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var objectCreate = new CodeObjectCreateExpression();
+            Assert.Equal(typeof(void).FullName, objectCreate.CreateType.BaseType);
+            Assert.Empty(objectCreate.Parameters);
+        }
 
-               public static IEnumerable<object[]> Ctor_CodeTypeReference_ParamsCodeExpression_TestData()
-               {
-                       yield return new object[] { null, new CodeExpression[0] };
-                       yield return new object[] { new CodeTypeReference(), new CodeExpression[] { new CodePrimitiveExpression() } };
-                       yield return new object[] { new CodeTypeReference(typeof(int)), new CodeExpression[] { new CodePrimitiveExpression("Value") } };
-               }
+        public static IEnumerable<object[]> Ctor_CodeTypeReference_ParamsCodeExpression_TestData()
+        {
+            yield return new object[] { null, new CodeExpression[0] };
+            yield return new object[] { new CodeTypeReference(), new CodeExpression[] { new CodePrimitiveExpression() } };
+            yield return new object[] { new CodeTypeReference(typeof(int)), new CodeExpression[] { new CodePrimitiveExpression("Value") } };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_CodeTypeReference_ParamsCodeExpression_TestData))]
-               public void Ctor(CodeTypeReference type, CodeExpression[] parameters)
-               {
-                       var objectCreate = new CodeObjectCreateExpression(type, parameters);
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, objectCreate.CreateType.BaseType);
-                       Assert.Equal(parameters, objectCreate.Parameters.Cast<CodeExpression>());
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_CodeTypeReference_ParamsCodeExpression_TestData))]
+        public void Ctor(CodeTypeReference type, CodeExpression[] parameters)
+        {
+            var objectCreate = new CodeObjectCreateExpression(type, parameters);
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, objectCreate.CreateType.BaseType);
+            Assert.Equal(parameters, objectCreate.Parameters.Cast<CodeExpression>());
+        }
 
-               public static IEnumerable<object[]> Ctor_String_ParamsCodeExpression_TestData()
-               {
-                       yield return new object[] { null, new CodeExpression[0], "System.Void" };
-                       yield return new object[] { "", new CodeExpression[] { new CodePrimitiveExpression() }, "System.Void" };
-                       yield return new object[] { "Int32", new CodeExpression[] { new CodePrimitiveExpression("Value") }, "Int32" };
-               }
+        public static IEnumerable<object[]> Ctor_String_ParamsCodeExpression_TestData()
+        {
+            yield return new object[] { null, new CodeExpression[0], "System.Void" };
+            yield return new object[] { "", new CodeExpression[] { new CodePrimitiveExpression() }, "System.Void" };
+            yield return new object[] { "Int32", new CodeExpression[] { new CodePrimitiveExpression("Value") }, "Int32" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_String_ParamsCodeExpression_TestData))]
-               public void Ctor(string type, CodeExpression[] parameters, string expectedBaseType)
-               {
-                       var objectCreate = new CodeObjectCreateExpression(type, parameters);
-                       Assert.Equal(expectedBaseType, objectCreate.CreateType.BaseType);
-                       Assert.Equal(parameters, objectCreate.Parameters.Cast<CodeExpression>());
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_String_ParamsCodeExpression_TestData))]
+        public void Ctor(string type, CodeExpression[] parameters, string expectedBaseType)
+        {
+            var objectCreate = new CodeObjectCreateExpression(type, parameters);
+            Assert.Equal(expectedBaseType, objectCreate.CreateType.BaseType);
+            Assert.Equal(parameters, objectCreate.Parameters.Cast<CodeExpression>());
+        }
 
-               public static IEnumerable<object[]> Ctor_Type_ParamsCodeExpression_TestData()
-               {
-                       yield return new object[] { typeof(int), new CodeExpression[0], "System.Int32" };
-                       yield return new object[] { typeof(List<>), new CodeExpression[] { new CodePrimitiveExpression() }, "System.Collections.Generic.List`1" };
-                       yield return new object[] { typeof(void), new CodeExpression[] { new CodePrimitiveExpression("Value") }, "System.Void" };
-               }
+        public static IEnumerable<object[]> Ctor_Type_ParamsCodeExpression_TestData()
+        {
+            yield return new object[] { typeof(int), new CodeExpression[0], "System.Int32" };
+            yield return new object[] { typeof(List<>), new CodeExpression[] { new CodePrimitiveExpression() }, "System.Collections.Generic.List`1" };
+            yield return new object[] { typeof(void), new CodeExpression[] { new CodePrimitiveExpression("Value") }, "System.Void" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_Type_ParamsCodeExpression_TestData))]
-               public void Ctor_Type_String(Type type, CodeExpression[] parameters, string expectedBaseType)
-               {
-                       var objectCreate = new CodeObjectCreateExpression(type, parameters);
-                       Assert.Equal(expectedBaseType, objectCreate.CreateType.BaseType);
-                       Assert.Equal(parameters, objectCreate.Parameters.Cast<CodeExpression>());
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_Type_ParamsCodeExpression_TestData))]
+        public void Ctor_Type_String(Type type, CodeExpression[] parameters, string expectedBaseType)
+        {
+            var objectCreate = new CodeObjectCreateExpression(type, parameters);
+            Assert.Equal(expectedBaseType, objectCreate.CreateType.BaseType);
+            Assert.Equal(parameters, objectCreate.Parameters.Cast<CodeExpression>());
+        }
 
-               [Fact]
-               public void Ctor_NullParameters_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeObjectCreateExpression(new CodeTypeReference(), null));
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeObjectCreateExpression("System.Int32", null));
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeObjectCreateExpression(typeof(int), null));
-               }
+        [Fact]
+        public void Ctor_NullParameters_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeObjectCreateExpression(new CodeTypeReference(), null));
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeObjectCreateExpression("System.Int32", null));
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeObjectCreateExpression(typeof(int), null));
+        }
 
-               [Fact]
-               public void Ctor_NullObjectInParameters_ThrowsArgumentNullException()
-               {
-                       CodeExpression[] parameters = new CodeExpression[] { null };
+        [Fact]
+        public void Ctor_NullObjectInParameters_ThrowsArgumentNullException()
+        {
+            CodeExpression[] parameters = new CodeExpression[] { null };
 
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeObjectCreateExpression(new CodeTypeReference(), parameters));
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeObjectCreateExpression("System.Int32", parameters));
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeObjectCreateExpression(typeof(int), parameters));
-               }
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeObjectCreateExpression(new CodeTypeReference(), parameters));
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeObjectCreateExpression("System.Int32", parameters));
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeObjectCreateExpression(typeof(int), parameters));
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void CreateType_Set_Get_ReturnsExpected(CodeTypeReference value)
-               {
-                       var objectCreate = new CodeObjectCreateExpression();
-                       objectCreate.CreateType = value;
-                       Assert.Equal((value ?? new CodeTypeReference("")).BaseType, objectCreate.CreateType.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void CreateType_Set_Get_ReturnsExpected(CodeTypeReference value)
+        {
+            var objectCreate = new CodeObjectCreateExpression();
+            objectCreate.CreateType = value;
+            Assert.Equal((value ?? new CodeTypeReference("")).BaseType, objectCreate.CreateType.BaseType);
+        }
 
-               [Fact]
-               public void Parameters_AddMultiple_ReturnsExpected()
-               {
-                       var objectCreate = new CodeObjectCreateExpression();
+        [Fact]
+        public void Parameters_AddMultiple_ReturnsExpected()
+        {
+            var objectCreate = new CodeObjectCreateExpression();
 
-                       CodeExpression expression1 = new CodePrimitiveExpression("Value1");
-                       objectCreate.Parameters.Add(expression1);
-                       Assert.Equal(new CodeExpression[] { expression1 }, objectCreate.Parameters.Cast<CodeExpression>());
+            CodeExpression expression1 = new CodePrimitiveExpression("Value1");
+            objectCreate.Parameters.Add(expression1);
+            Assert.Equal(new CodeExpression[] { expression1 }, objectCreate.Parameters.Cast<CodeExpression>());
 
-                       CodeExpression expression2 = new CodePrimitiveExpression("Value2");
-                       objectCreate.Parameters.Add(expression2);
-                       Assert.Equal(new CodeExpression[] { expression1, expression2 }, objectCreate.Parameters.Cast<CodeExpression>());
-               }
-       }
+            CodeExpression expression2 = new CodePrimitiveExpression("Value2");
+            objectCreate.Parameters.Add(expression2);
+            Assert.Equal(new CodeExpression[] { expression1, expression2 }, objectCreate.Parameters.Cast<CodeExpression>());
+        }
+    }
 }
index 332e147..a4553c7 100644 (file)
@@ -8,62 +8,62 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public abstract class CodeObjectTestBase<T> : CodeDomTestBase where T : CodeObject, new()
-       {
-               [Fact]
-               public void Ctor_Default_ObjectBase()
-               {
-                       CodeObject codeObject = new T();
-                       Assert.Empty(codeObject.UserData);
-               }
+    public abstract class CodeObjectTestBase<T> : CodeDomTestBase where T : CodeObject, new()
+    {
+        [Fact]
+        public void Ctor_Default_ObjectBase()
+        {
+            CodeObject codeObject = new T();
+            Assert.Empty(codeObject.UserData);
+        }
 
-               [Fact]
-               public void UserData_AddMultiple_ReturnsExpected()
-               {
-                       CodeObject codeObject = new T();
-                       codeObject.UserData.Add("key1", "value");
-                       Assert.Equal(new ListDictionary() { ["key1"] = "value" }, codeObject.UserData);
+        [Fact]
+        public void UserData_AddMultiple_ReturnsExpected()
+        {
+            CodeObject codeObject = new T();
+            codeObject.UserData.Add("key1", "value");
+            Assert.Equal(new ListDictionary() { ["key1"] = "value" }, codeObject.UserData);
 
-                       codeObject.UserData.Add("key2", "value");
-                       Assert.Equal(new ListDictionary() { ["key1"] = "value", ["key2"] = "value" }, codeObject.UserData);
-               }
-       }
+            codeObject.UserData.Add("key2", "value");
+            Assert.Equal(new ListDictionary() { ["key1"] = "value", ["key2"] = "value" }, codeObject.UserData);
+        }
+    }
 
-       public abstract class CodeDomTestBase
-       {
-               public static IEnumerable<object[]> CodeExpression_TestData()
-               {
-                       yield return new object[] { null };
-                       yield return new object[] { new CodePrimitiveExpression("Value") };
-               }
+    public abstract class CodeDomTestBase
+    {
+        public static IEnumerable<object[]> CodeExpression_TestData()
+        {
+            yield return new object[] { null };
+            yield return new object[] { new CodePrimitiveExpression("Value") };
+        }
 
-               public static IEnumerable<object[]> CodeTypeReference_TestData()
-               {
-                       yield return new object[] { null };
-                       yield return new object[] { new CodeTypeReference(typeof(int)) };
-                       yield return new object[] { new CodeTypeReference(typeof(int).MakePointerType()) };
-                       yield return new object[] { new CodeTypeReference(typeof(int).MakeByRefType()) };
-                       yield return new object[] { new CodeTypeReference(typeof(List<>)) };
-                       yield return new object[] { new CodeTypeReference(typeof(List<string>)) };
-               }
+        public static IEnumerable<object[]> CodeTypeReference_TestData()
+        {
+            yield return new object[] { null };
+            yield return new object[] { new CodeTypeReference(typeof(int)) };
+            yield return new object[] { new CodeTypeReference(typeof(int).MakePointerType()) };
+            yield return new object[] { new CodeTypeReference(typeof(int).MakeByRefType()) };
+            yield return new object[] { new CodeTypeReference(typeof(List<>)) };
+            yield return new object[] { new CodeTypeReference(typeof(List<string>)) };
+        }
 
-               public static IEnumerable<object[]> CodeStatement_TestData()
-               {
-                       yield return new object[] { null };
-                       yield return new object[] { new CodeCommentStatement("Text") };
-               }
+        public static IEnumerable<object[]> CodeStatement_TestData()
+        {
+            yield return new object[] { null };
+            yield return new object[] { new CodeCommentStatement("Text") };
+        }
 
-               public static IEnumerable<object[]> String_TestData()
-               {
-                       yield return new object[] { null };
-                       yield return new object[] { "" };
-                       yield return new object[] { "Value" };
-               }
+        public static IEnumerable<object[]> String_TestData()
+        {
+            yield return new object[] { null };
+            yield return new object[] { "" };
+            yield return new object[] { "Value" };
+        }
 
-               public static IEnumerable<object[]> LinePragma_TestData()
-               {
-                       yield return new object[] { null };
-                       yield return new object[] { new CodeLinePragma("FileName", 1) };
-               }
-       }
+        public static IEnumerable<object[]> LinePragma_TestData()
+        {
+            yield return new object[] { null };
+            yield return new object[] { new CodeLinePragma("FileName", 1) };
+        }
+    }
 }
index a7197e0..31539da 100644 (file)
@@ -8,133 +8,133 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeParameterDeclarationExpressionTests : CodeObjectTestBase<CodeParameterDeclarationExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var parameter = new CodeParameterDeclarationExpression();
-                       Assert.Empty(parameter.CustomAttributes);
-                       Assert.Equal(FieldDirection.In, parameter.Direction);
-                       Assert.Equal(typeof(void).FullName, parameter.Type.BaseType);
-                       Assert.Empty(parameter.Name);
-               }
-
-               public static IEnumerable<object[]> Ctor_CodeTypeReference_String_TestData()
-               {
-                       yield return new object[] { null, null };
-                       yield return new object[] { new CodeTypeReference(), "" };
-                       yield return new object[] { new CodeTypeReference(typeof(int)), "Name" };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_CodeTypeReference_String_TestData))]
-               public void Ctor_CodeTypeReference_String(CodeTypeReference type, string name)
-               {
-                       var parameter = new CodeParameterDeclarationExpression(type, name);
-                       Assert.Empty(parameter.CustomAttributes);
-                       Assert.Equal(FieldDirection.In, parameter.Direction);
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, parameter.Type.BaseType);
-                       Assert.Equal(name ?? string.Empty, parameter.Name);
-               }
-
-               public static IEnumerable<object[]> Ctor_String_String_TestData()
-               {
-                       yield return new object[] { null, null, "System.Void" };
-                       yield return new object[] { "", "", "System.Void" };
-                       yield return new object[] { "Int32", "Name", "Int32" };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_String_String_TestData))]
-               public void Ctor_String_String(string type, string name, string expectedBaseType)
-               {
-                       var parameter = new CodeParameterDeclarationExpression(type, name);
-                       Assert.Empty(parameter.CustomAttributes);
-                       Assert.Equal(FieldDirection.In, parameter.Direction);
-                       Assert.Equal(expectedBaseType, parameter.Type.BaseType);
-                       Assert.Equal(name ?? string.Empty, parameter.Name);
-               }
-
-               public static IEnumerable<object[]> Ctor_Type_String_TestData()
-               {
-                       yield return new object[] { typeof(int), null, "System.Int32" };
-                       yield return new object[] { typeof(List<>), "", "System.Collections.Generic.List`1" };
-                       yield return new object[] { typeof(void), "Name", "System.Void" };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_Type_String_TestData))]
-               public void Ctor_Type_String(Type type, string name, string expectedBaseType)
-               {
-                       var parameter = new CodeParameterDeclarationExpression(type, name);
-                       Assert.Empty(parameter.CustomAttributes);
-                       Assert.Equal(FieldDirection.In, parameter.Direction);
-                       Assert.Equal(expectedBaseType, parameter.Type.BaseType);
-                       Assert.Equal(name ?? string.Empty, parameter.Name);
-               }
-
-               [Fact]
-               public void CustomAttributes_SetNull_Get_ReturnsEmpty()
-               {
-                       var parameter = new CodeParameterDeclarationExpression() { CustomAttributes = null };
-                       Assert.Empty(parameter.CustomAttributes);
-               }
-
-               [Fact]
-               public void CustomAttributes_SetNonNull_Get_ReturnsExpected()
-               {
-                       var parameter = new CodeParameterDeclarationExpression() { CustomAttributes = null };
-                       CodeAttributeDeclarationCollection value = new CodeAttributeDeclarationCollection();
-                       value.Add(new CodeAttributeDeclaration("Name1"));
-                       value.Add(new CodeAttributeDeclaration("Name2"));
-
-                       parameter.CustomAttributes = value;
-                       Assert.Equal(value, parameter.CustomAttributes);
-               }
-
-               [Fact]
-               public void CustomAttributes_AddMultiple_ReturnsExpected()
-               {
-                       var parameter = new CodeParameterDeclarationExpression();
-
-                       CodeAttributeDeclaration attribute1 = new CodeAttributeDeclaration("Name1");
-                       parameter.CustomAttributes.Add(attribute1);
-                       Assert.Equal(new CodeAttributeDeclaration[] { attribute1 }, parameter.CustomAttributes.Cast<CodeAttributeDeclaration>());
-
-                       CodeAttributeDeclaration attribute2 = new CodeAttributeDeclaration("Name2");
-                       parameter.CustomAttributes.Add(attribute2);
-                       Assert.Equal(new CodeAttributeDeclaration[] { attribute1, attribute2 }, parameter.CustomAttributes.Cast<CodeAttributeDeclaration>());
-               }
-
-               [Theory]
-               [InlineData(FieldDirection.In - 1)]
-               [InlineData(FieldDirection.In)]
-               [InlineData(FieldDirection.In | FieldDirection.Out)]
-               [InlineData(FieldDirection.Ref + 1)]
-               public void Direction_Set_Get_ReturnsExpected(FieldDirection value)
-               {
-                       var parameter = new CodeParameterDeclarationExpression();
-                       parameter.Direction = value;
-                       Assert.Equal(value, parameter.Direction);
-               }
-
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Type_Set_Get_ReturnsExpected(CodeTypeReference value)
-               {
-                       var parameter = new CodeParameterDeclarationExpression();
-                       parameter.Type = value;
-                       Assert.Equal((value ?? new CodeTypeReference("")).BaseType, parameter.Type.BaseType);
-               }
-
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Name_Set_Get_ReturnsExpected(string value)
-               {
-                       var parameter = new CodeParameterDeclarationExpression();
-                       parameter.Name = value;
-                       Assert.Equal(value ?? string.Empty, parameter.Name);
-               }
-       }
+    public class CodeParameterDeclarationExpressionTests : CodeObjectTestBase<CodeParameterDeclarationExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var parameter = new CodeParameterDeclarationExpression();
+            Assert.Empty(parameter.CustomAttributes);
+            Assert.Equal(FieldDirection.In, parameter.Direction);
+            Assert.Equal(typeof(void).FullName, parameter.Type.BaseType);
+            Assert.Empty(parameter.Name);
+        }
+
+        public static IEnumerable<object[]> Ctor_CodeTypeReference_String_TestData()
+        {
+            yield return new object[] { null, null };
+            yield return new object[] { new CodeTypeReference(), "" };
+            yield return new object[] { new CodeTypeReference(typeof(int)), "Name" };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_CodeTypeReference_String_TestData))]
+        public void Ctor_CodeTypeReference_String(CodeTypeReference type, string name)
+        {
+            var parameter = new CodeParameterDeclarationExpression(type, name);
+            Assert.Empty(parameter.CustomAttributes);
+            Assert.Equal(FieldDirection.In, parameter.Direction);
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, parameter.Type.BaseType);
+            Assert.Equal(name ?? string.Empty, parameter.Name);
+        }
+
+        public static IEnumerable<object[]> Ctor_String_String_TestData()
+        {
+            yield return new object[] { null, null, "System.Void" };
+            yield return new object[] { "", "", "System.Void" };
+            yield return new object[] { "Int32", "Name", "Int32" };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_String_String_TestData))]
+        public void Ctor_String_String(string type, string name, string expectedBaseType)
+        {
+            var parameter = new CodeParameterDeclarationExpression(type, name);
+            Assert.Empty(parameter.CustomAttributes);
+            Assert.Equal(FieldDirection.In, parameter.Direction);
+            Assert.Equal(expectedBaseType, parameter.Type.BaseType);
+            Assert.Equal(name ?? string.Empty, parameter.Name);
+        }
+
+        public static IEnumerable<object[]> Ctor_Type_String_TestData()
+        {
+            yield return new object[] { typeof(int), null, "System.Int32" };
+            yield return new object[] { typeof(List<>), "", "System.Collections.Generic.List`1" };
+            yield return new object[] { typeof(void), "Name", "System.Void" };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_Type_String_TestData))]
+        public void Ctor_Type_String(Type type, string name, string expectedBaseType)
+        {
+            var parameter = new CodeParameterDeclarationExpression(type, name);
+            Assert.Empty(parameter.CustomAttributes);
+            Assert.Equal(FieldDirection.In, parameter.Direction);
+            Assert.Equal(expectedBaseType, parameter.Type.BaseType);
+            Assert.Equal(name ?? string.Empty, parameter.Name);
+        }
+
+        [Fact]
+        public void CustomAttributes_SetNull_Get_ReturnsEmpty()
+        {
+            var parameter = new CodeParameterDeclarationExpression() { CustomAttributes = null };
+            Assert.Empty(parameter.CustomAttributes);
+        }
+
+        [Fact]
+        public void CustomAttributes_SetNonNull_Get_ReturnsExpected()
+        {
+            var parameter = new CodeParameterDeclarationExpression() { CustomAttributes = null };
+            CodeAttributeDeclarationCollection value = new CodeAttributeDeclarationCollection();
+            value.Add(new CodeAttributeDeclaration("Name1"));
+            value.Add(new CodeAttributeDeclaration("Name2"));
+
+            parameter.CustomAttributes = value;
+            Assert.Equal(value, parameter.CustomAttributes);
+        }
+
+        [Fact]
+        public void CustomAttributes_AddMultiple_ReturnsExpected()
+        {
+            var parameter = new CodeParameterDeclarationExpression();
+
+            CodeAttributeDeclaration attribute1 = new CodeAttributeDeclaration("Name1");
+            parameter.CustomAttributes.Add(attribute1);
+            Assert.Equal(new CodeAttributeDeclaration[] { attribute1 }, parameter.CustomAttributes.Cast<CodeAttributeDeclaration>());
+
+            CodeAttributeDeclaration attribute2 = new CodeAttributeDeclaration("Name2");
+            parameter.CustomAttributes.Add(attribute2);
+            Assert.Equal(new CodeAttributeDeclaration[] { attribute1, attribute2 }, parameter.CustomAttributes.Cast<CodeAttributeDeclaration>());
+        }
+
+        [Theory]
+        [InlineData(FieldDirection.In - 1)]
+        [InlineData(FieldDirection.In)]
+        [InlineData(FieldDirection.In | FieldDirection.Out)]
+        [InlineData(FieldDirection.Ref + 1)]
+        public void Direction_Set_Get_ReturnsExpected(FieldDirection value)
+        {
+            var parameter = new CodeParameterDeclarationExpression();
+            parameter.Direction = value;
+            Assert.Equal(value, parameter.Direction);
+        }
+
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Type_Set_Get_ReturnsExpected(CodeTypeReference value)
+        {
+            var parameter = new CodeParameterDeclarationExpression();
+            parameter.Type = value;
+            Assert.Equal((value ?? new CodeTypeReference("")).BaseType, parameter.Type.BaseType);
+        }
+
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Name_Set_Get_ReturnsExpected(string value)
+        {
+            var parameter = new CodeParameterDeclarationExpression();
+            parameter.Name = value;
+            Assert.Equal(value ?? string.Empty, parameter.Name);
+        }
+    }
 }
index 147afbc..e372301 100644 (file)
@@ -7,37 +7,37 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodePrimitiveExpressionTests : CodeObjectTestBase<CodePrimitiveExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var primitive = new CodePrimitiveExpression();
-                       Assert.Null(primitive.Value);
-               }
+    public class CodePrimitiveExpressionTests : CodeObjectTestBase<CodePrimitiveExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var primitive = new CodePrimitiveExpression();
+            Assert.Null(primitive.Value);
+        }
 
-               public static IEnumerable<object[]> Object_TestData()
-               {
-                       yield return new object[] { null };
-                       yield return new object[] { 1 };
-                       yield return new object[] { "2" };
-               }
+        public static IEnumerable<object[]> Object_TestData()
+        {
+            yield return new object[] { null };
+            yield return new object[] { 1 };
+            yield return new object[] { "2" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Object_TestData))]
-               public void Ctor_Object(object value)
-               {
-                       var primitive = new CodePrimitiveExpression(value);
-                       Assert.Equal(value, primitive.Value);
-               }
+        [Theory]
+        [MemberData(nameof(Object_TestData))]
+        public void Ctor_Object(object value)
+        {
+            var primitive = new CodePrimitiveExpression(value);
+            Assert.Equal(value, primitive.Value);
+        }
 
-               [Theory]
-               [MemberData(nameof(Object_TestData))]
-               public void Value_Set_Get_ReturnsExpected(object value)
-               {
-                       var primitive = new CodePrimitiveExpression();
-                       primitive.Value = value;
-                       Assert.Equal(value, primitive.Value);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(Object_TestData))]
+        public void Value_Set_Get_ReturnsExpected(object value)
+        {
+            var primitive = new CodePrimitiveExpression();
+            primitive.Value = value;
+            Assert.Equal(value, primitive.Value);
+        }
+    }
 }
index e55ddeb..cd9fbb2 100644 (file)
@@ -7,50 +7,50 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodePropertyReferenceExpressionTests : CodeObjectTestBase<CodePropertyReferenceExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var propertyReference = new CodePropertyReferenceExpression();
-                       Assert.Null(propertyReference.TargetObject);
-                       Assert.Empty(propertyReference.PropertyName);
-               }
+    public class CodePropertyReferenceExpressionTests : CodeObjectTestBase<CodePropertyReferenceExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var propertyReference = new CodePropertyReferenceExpression();
+            Assert.Null(propertyReference.TargetObject);
+            Assert.Empty(propertyReference.PropertyName);
+        }
 
-               public static IEnumerable<object[]> Ctor_TestData()
-               {
-                       yield return new object[] { null, null };
-                       yield return new object[] { new CodePrimitiveExpression(""), "" };
-                       yield return new object[] { new CodePrimitiveExpression("Value"), "PropertyName" };
-               }
+        public static IEnumerable<object[]> Ctor_TestData()
+        {
+            yield return new object[] { null, null };
+            yield return new object[] { new CodePrimitiveExpression(""), "" };
+            yield return new object[] { new CodePrimitiveExpression("Value"), "PropertyName" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TestData))]
-               public void Ctor(CodeExpression targetObject, string PropertyName)
-               {
-                       var propertyReference = new CodePropertyReferenceExpression(targetObject, PropertyName);
-                       Assert.Equal(targetObject, propertyReference.TargetObject);
-                       Assert.Equal(PropertyName ?? string.Empty, propertyReference.PropertyName);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TestData))]
+        public void Ctor(CodeExpression targetObject, string PropertyName)
+        {
+            var propertyReference = new CodePropertyReferenceExpression(targetObject, PropertyName);
+            Assert.Equal(targetObject, propertyReference.TargetObject);
+            Assert.Equal(PropertyName ?? string.Empty, propertyReference.PropertyName);
+        }
 
-               [Theory]
-               [InlineData(null)]
-               [InlineData("")]
-               [InlineData("PropertyName")]
-               public void EventName_Set_Get_ReturnsExpected(string value)
-               {
-                       var propertyReference = new CodePropertyReferenceExpression();
-                       propertyReference.PropertyName = value;
-                       Assert.Equal(value ?? string.Empty, propertyReference.PropertyName);
-               }
+        [Theory]
+        [InlineData(null)]
+        [InlineData("")]
+        [InlineData("PropertyName")]
+        public void EventName_Set_Get_ReturnsExpected(string value)
+        {
+            var propertyReference = new CodePropertyReferenceExpression();
+            propertyReference.PropertyName = value;
+            Assert.Equal(value ?? string.Empty, propertyReference.PropertyName);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var propertyReference = new CodePropertyReferenceExpression();
-                       propertyReference.TargetObject = value;
-                       Assert.Equal(value, propertyReference.TargetObject);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void TargetObject_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var propertyReference = new CodePropertyReferenceExpression();
+            propertyReference.TargetObject = value;
+            Assert.Equal(value, propertyReference.TargetObject);
+        }
+    }
 }
index b4b9560..319083d 100644 (file)
@@ -7,50 +7,50 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeRegionDirectiveTests : CodeDomTestBase
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var region = new CodeRegionDirective();
-                       Assert.Equal(CodeRegionMode.None, region.RegionMode);
-                       Assert.Empty(region.RegionText);
-               }
+    public class CodeRegionDirectiveTests : CodeDomTestBase
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var region = new CodeRegionDirective();
+            Assert.Equal(CodeRegionMode.None, region.RegionMode);
+            Assert.Empty(region.RegionText);
+        }
 
-               public static IEnumerable<object[]> Ctor_TestData()
-               {
-                       yield return new object[] { CodeRegionMode.None - 1, null };
-                       yield return new object[] { CodeRegionMode.None, "" };
-                       yield return new object[] { CodeRegionMode.End + 1, "RegionText" };
-               }
+        public static IEnumerable<object[]> Ctor_TestData()
+        {
+            yield return new object[] { CodeRegionMode.None - 1, null };
+            yield return new object[] { CodeRegionMode.None, "" };
+            yield return new object[] { CodeRegionMode.End + 1, "RegionText" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TestData))]
-               public void Ctor_CodeRegionMode_String(CodeRegionMode regionMode, string regionText)
-               {
-                       var region = new CodeRegionDirective(regionMode, regionText);
-                       Assert.Equal(regionMode, region.RegionMode);
-                       Assert.Equal(regionText ?? string.Empty, region.RegionText);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TestData))]
+        public void Ctor_CodeRegionMode_String(CodeRegionMode regionMode, string regionText)
+        {
+            var region = new CodeRegionDirective(regionMode, regionText);
+            Assert.Equal(regionMode, region.RegionMode);
+            Assert.Equal(regionText ?? string.Empty, region.RegionText);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void RegionText_Set_Get_ReturnsExpected(string value)
-               {
-                       var region = new CodeRegionDirective();
-                       region.RegionText = value;
-                       Assert.Equal(value ?? string.Empty, region.RegionText);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void RegionText_Set_Get_ReturnsExpected(string value)
+        {
+            var region = new CodeRegionDirective();
+            region.RegionText = value;
+            Assert.Equal(value ?? string.Empty, region.RegionText);
+        }
 
-               [Theory]
-               [InlineData(CodeRegionMode.None - 1)]
-               [InlineData(CodeRegionMode.None)]
-               [InlineData(CodeRegionMode.Start | CodeRegionMode.End)]
-               public void Value_Set_Get_ReturnsExpected(CodeRegionMode value)
-               {
-                       var region = new CodeRegionDirective();
-                       region.RegionMode = value;
-                       Assert.Equal(value, region.RegionMode);
-               }
-       }
+        [Theory]
+        [InlineData(CodeRegionMode.None - 1)]
+        [InlineData(CodeRegionMode.None)]
+        [InlineData(CodeRegionMode.Start | CodeRegionMode.End)]
+        public void Value_Set_Get_ReturnsExpected(CodeRegionMode value)
+        {
+            var region = new CodeRegionDirective();
+            region.RegionMode = value;
+            Assert.Equal(value, region.RegionMode);
+        }
+    }
 }
index fa0f9a0..a09d468 100644 (file)
@@ -7,67 +7,67 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeRemoveEventStatementTests : CodeStatementTestBase<CodeRemoveEventStatement>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var removeEvent = new CodeRemoveEventStatement();
-                       Assert.Empty(removeEvent.Event.EventName);
-                       Assert.Null(removeEvent.Event.TargetObject);
-                       Assert.Null(removeEvent.Listener);
-               }
+    public class CodeRemoveEventStatementTests : CodeStatementTestBase<CodeRemoveEventStatement>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var removeEvent = new CodeRemoveEventStatement();
+            Assert.Empty(removeEvent.Event.EventName);
+            Assert.Null(removeEvent.Event.TargetObject);
+            Assert.Null(removeEvent.Listener);
+        }
 
-               public static IEnumerable<object[]> Ctor_CodeExpression_String_CodeExpression_TestData()
-               {
-                       yield return new object[] { null, null, null };
-                       yield return new object[] { new CodePrimitiveExpression("Value1"), "EventName", new CodePrimitiveExpression("Value2") };
-               }
+        public static IEnumerable<object[]> Ctor_CodeExpression_String_CodeExpression_TestData()
+        {
+            yield return new object[] { null, null, null };
+            yield return new object[] { new CodePrimitiveExpression("Value1"), "EventName", new CodePrimitiveExpression("Value2") };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_CodeExpression_String_CodeExpression_TestData))]
-               public void Ctor_CodeExpression_String_CodeExpression(CodeExpression targetObject, string eventName, CodeExpression listener)
-               {
-                       var removeEvent = new CodeRemoveEventStatement(targetObject, eventName, listener);
-                       Assert.Equal(targetObject, removeEvent.Event.TargetObject);
-                       Assert.Equal(eventName ?? string.Empty, removeEvent.Event.EventName);
-                       Assert.Equal(listener, removeEvent.Listener);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_CodeExpression_String_CodeExpression_TestData))]
+        public void Ctor_CodeExpression_String_CodeExpression(CodeExpression targetObject, string eventName, CodeExpression listener)
+        {
+            var removeEvent = new CodeRemoveEventStatement(targetObject, eventName, listener);
+            Assert.Equal(targetObject, removeEvent.Event.TargetObject);
+            Assert.Equal(eventName ?? string.Empty, removeEvent.Event.EventName);
+            Assert.Equal(listener, removeEvent.Listener);
+        }
 
-               public static IEnumerable<object[]> CodeEventReferenceExpression_CodeExpression_TestData()
-               {
-                       yield return new object[] { null, null };
-                       yield return new object[] { new CodeEventReferenceExpression(null, null), null };
-                       yield return new object[] { new CodeEventReferenceExpression(new CodePrimitiveExpression("Value1"), "EventName"), new CodePrimitiveExpression("Value2") };
-               }
+        public static IEnumerable<object[]> CodeEventReferenceExpression_CodeExpression_TestData()
+        {
+            yield return new object[] { null, null };
+            yield return new object[] { new CodeEventReferenceExpression(null, null), null };
+            yield return new object[] { new CodeEventReferenceExpression(new CodePrimitiveExpression("Value1"), "EventName"), new CodePrimitiveExpression("Value2") };
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeEventReferenceExpression_CodeExpression_TestData))]
-               public void Ctor_CodeEventReferenceExpression_CodeExpression(CodeEventReferenceExpression eventExpresion, CodeExpression listener)
-               {
-                       var removeEvent = new CodeRemoveEventStatement(eventExpresion, listener);
-                       Assert.Equal((eventExpresion ?? new CodeEventReferenceExpression()).TargetObject, removeEvent.Event.TargetObject);
-                       Assert.Equal((eventExpresion ?? new CodeEventReferenceExpression()).EventName, removeEvent.Event.EventName);
-                       Assert.Equal(listener, removeEvent.Listener);
-               }
+        [Theory]
+        [MemberData(nameof(CodeEventReferenceExpression_CodeExpression_TestData))]
+        public void Ctor_CodeEventReferenceExpression_CodeExpression(CodeEventReferenceExpression eventExpresion, CodeExpression listener)
+        {
+            var removeEvent = new CodeRemoveEventStatement(eventExpresion, listener);
+            Assert.Equal((eventExpresion ?? new CodeEventReferenceExpression()).TargetObject, removeEvent.Event.TargetObject);
+            Assert.Equal((eventExpresion ?? new CodeEventReferenceExpression()).EventName, removeEvent.Event.EventName);
+            Assert.Equal(listener, removeEvent.Listener);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeEventReferenceExpression_CodeExpression_TestData))]
-               public void Event_Set_Get_ReturnsExpected(CodeEventReferenceExpression value, CodeExpression _)
-               {
-                       var removeEvent = new CodeRemoveEventStatement();
-                       removeEvent.Event = value;
-                       Assert.Equal((value ?? new CodeEventReferenceExpression()).TargetObject, removeEvent.Event.TargetObject);
-                       Assert.Equal((value ?? new CodeEventReferenceExpression()).EventName, removeEvent.Event.EventName);
-               }
+        [Theory]
+        [MemberData(nameof(CodeEventReferenceExpression_CodeExpression_TestData))]
+        public void Event_Set_Get_ReturnsExpected(CodeEventReferenceExpression value, CodeExpression _)
+        {
+            var removeEvent = new CodeRemoveEventStatement();
+            removeEvent.Event = value;
+            Assert.Equal((value ?? new CodeEventReferenceExpression()).TargetObject, removeEvent.Event.TargetObject);
+            Assert.Equal((value ?? new CodeEventReferenceExpression()).EventName, removeEvent.Event.EventName);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Listener_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var removeEvent = new CodeRemoveEventStatement();
-                       removeEvent.Listener = value;
-                       Assert.Equal(value, removeEvent.Listener);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Listener_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var removeEvent = new CodeRemoveEventStatement();
+            removeEvent.Listener = value;
+            Assert.Equal(value, removeEvent.Listener);
+        }
+    }
 }
index 7611c9d..a0e6891 100644 (file)
@@ -6,40 +6,40 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeSnippetCompileUnitTests : CodeObjectTestBase<CodeSnippetCompileUnit>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var compileUnit = new CodeSnippetCompileUnit();
-                       Assert.Empty(compileUnit.Value);
-                       Assert.Null(compileUnit.LinePragma);
-               }
+    public class CodeSnippetCompileUnitTests : CodeObjectTestBase<CodeSnippetCompileUnit>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var compileUnit = new CodeSnippetCompileUnit();
+            Assert.Empty(compileUnit.Value);
+            Assert.Null(compileUnit.LinePragma);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Ctor_String(string value)
-               {
-                       var compileUnit = new CodeSnippetCompileUnit(value);
-                       Assert.Equal(value ?? string.Empty, compileUnit.Value);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Ctor_String(string value)
+        {
+            var compileUnit = new CodeSnippetCompileUnit(value);
+            Assert.Equal(value ?? string.Empty, compileUnit.Value);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Value_Set_Get_ReturnsExpected(string value)
-               {
-                       var compileUnit = new CodeSnippetCompileUnit();
-                       compileUnit.Value = value;
-                       Assert.Equal(value ?? string.Empty, compileUnit.Value);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Value_Set_Get_ReturnsExpected(string value)
+        {
+            var compileUnit = new CodeSnippetCompileUnit();
+            compileUnit.Value = value;
+            Assert.Equal(value ?? string.Empty, compileUnit.Value);
+        }
 
-               [Theory]
-               [MemberData(nameof(LinePragma_TestData))]
-               public void LinePragma_Set_Get_ReturnsExpected(CodeLinePragma value)
-               {
-                       var compileUnit = new CodeSnippetCompileUnit();
-                       compileUnit.LinePragma = value;
-                       Assert.Equal(value, compileUnit.LinePragma);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(LinePragma_TestData))]
+        public void LinePragma_Set_Get_ReturnsExpected(CodeLinePragma value)
+        {
+            var compileUnit = new CodeSnippetCompileUnit();
+            compileUnit.LinePragma = value;
+            Assert.Equal(value, compileUnit.LinePragma);
+        }
+    }
 }
index 0e13f23..23609a8 100644 (file)
@@ -6,30 +6,30 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeSnippetExpressionTests : CodeObjectTestBase<CodeSnippetExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var snippet = new CodeSnippetExpression();
-                       Assert.Empty(snippet.Value);
-               }
+    public class CodeSnippetExpressionTests : CodeObjectTestBase<CodeSnippetExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var snippet = new CodeSnippetExpression();
+            Assert.Empty(snippet.Value);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Ctor_String(string value)
-               {
-                       var snippet = new CodeSnippetExpression(value);
-                       Assert.Equal(value ?? string.Empty, snippet.Value);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Ctor_String(string value)
+        {
+            var snippet = new CodeSnippetExpression(value);
+            Assert.Equal(value ?? string.Empty, snippet.Value);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Value_Set_Get_ReturnsExpected(string value)
-               {
-                       var snippet = new CodeSnippetExpression();
-                       snippet.Value = value;
-                       Assert.Equal(value ?? string.Empty, snippet.Value);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Value_Set_Get_ReturnsExpected(string value)
+        {
+            var snippet = new CodeSnippetExpression();
+            snippet.Value = value;
+            Assert.Equal(value ?? string.Empty, snippet.Value);
+        }
+    }
 }
index 4396e2d..87596e0 100644 (file)
@@ -6,30 +6,30 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeSnippetStatementTests : CodeStatementTestBase<CodeSnippetStatement>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var snippet = new CodeSnippetStatement();
-                       Assert.Empty(snippet.Value);
-               }
+    public class CodeSnippetStatementTests : CodeStatementTestBase<CodeSnippetStatement>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var snippet = new CodeSnippetStatement();
+            Assert.Empty(snippet.Value);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Ctor_String(string value)
-               {
-                       var snippet = new CodeSnippetStatement(value);
-                       Assert.Equal(value ?? string.Empty, snippet.Value);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Ctor_String(string value)
+        {
+            var snippet = new CodeSnippetStatement(value);
+            Assert.Equal(value ?? string.Empty, snippet.Value);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Value_Set_Get_ReturnsExpected(string value)
-               {
-                       var snippet = new CodeSnippetStatement();
-                       snippet.Value = value;
-                       Assert.Equal(value ?? string.Empty, snippet.Value);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Value_Set_Get_ReturnsExpected(string value)
+        {
+            var snippet = new CodeSnippetStatement();
+            snippet.Value = value;
+            Assert.Equal(value ?? string.Empty, snippet.Value);
+        }
+    }
 }
index 94fa373..c48e2f4 100644 (file)
@@ -6,34 +6,34 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeSnippetTypeMemberTests : CodeTypeMemberTestBase<CodeSnippetTypeMember>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var snippet = new CodeSnippetTypeMember();
-                       Assert.Empty(snippet.Name);
-               }
+    public class CodeSnippetTypeMemberTests : CodeTypeMemberTestBase<CodeSnippetTypeMember>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var snippet = new CodeSnippetTypeMember();
+            Assert.Empty(snippet.Name);
+        }
 
-               [Theory]
-               [InlineData(null)]
-               [InlineData("")]
-               [InlineData("Text")]
-               public void Ctor_String(string value)
-               {
-                       var snippet = new CodeSnippetTypeMember(value);
-                       Assert.Equal(value ?? string.Empty, snippet.Text);
-               }
+        [Theory]
+        [InlineData(null)]
+        [InlineData("")]
+        [InlineData("Text")]
+        public void Ctor_String(string value)
+        {
+            var snippet = new CodeSnippetTypeMember(value);
+            Assert.Equal(value ?? string.Empty, snippet.Text);
+        }
 
-               [Theory]
-               [InlineData(null)]
-               [InlineData("")]
-               [InlineData("Text")]
-               public void Text_Set_Get_ReturnsExpected(string value)
-               {
-                       var snippet = new CodeSnippetTypeMember();
-                       snippet.Text = value;
-                       Assert.Equal(value ?? string.Empty, snippet.Text);
-               }
-       }
+        [Theory]
+        [InlineData(null)]
+        [InlineData("")]
+        [InlineData("Text")]
+        public void Text_Set_Get_ReturnsExpected(string value)
+        {
+            var snippet = new CodeSnippetTypeMember();
+            snippet.Text = value;
+            Assert.Equal(value ?? string.Empty, snippet.Text);
+        }
+    }
 }
index 5d1baa7..f02f7f5 100644 (file)
@@ -7,52 +7,52 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public abstract class CodeStatementTestBase<T> : CodeObjectTestBase<T> where T : CodeStatement, new()
-       {
-               [Fact]
-               public void Ctor_Default_StatementBase()
-               {
-                       CodeStatement statement = new T();
-                       Assert.Null(statement.LinePragma);
-
-                       Assert.Empty(statement.StartDirectives);
-                       Assert.Empty(statement.EndDirectives);
-               }
-
-               [Theory]
-               [MemberData(nameof(LinePragma_TestData))]
-               public void LinePragma_Set_Get_ReturnsExpected(CodeLinePragma value)
-               {
-                       CodeStatement statement = new T() { LinePragma = value };
-                       Assert.Equal(value, statement.LinePragma);
-               }
-
-               [Fact]
-               public void StartDirectives_AddMultiple_ReturnsExpected()
-               {
-                       CodeStatement statement = new T();
-
-                       CodeRegionDirective directive1 = new CodeRegionDirective(CodeRegionMode.None, "Region1");
-                       statement.StartDirectives.Add(directive1);
-                       Assert.Equal(new CodeRegionDirective[] { directive1 }, statement.StartDirectives.Cast<CodeDirective>());
-
-                       CodeRegionDirective directive2 = new CodeRegionDirective(CodeRegionMode.None, "Region2");
-                       statement.StartDirectives.Add(directive2);
-                       Assert.Equal(new CodeRegionDirective[] { directive1, directive2 }, statement.StartDirectives.Cast<CodeDirective>());
-               }
-
-               [Fact]
-               public void EndDirectives_AddMultiple_ReturnsExpected()
-               {
-                       CodeStatement statement = new T();
-
-                       CodeRegionDirective directive1 = new CodeRegionDirective(CodeRegionMode.None, "Region1");
-                       statement.EndDirectives.Add(directive1);
-                       Assert.Equal(new CodeRegionDirective[] { directive1 }, statement.EndDirectives.Cast<CodeDirective>());
-
-                       CodeRegionDirective directive2 = new CodeRegionDirective(CodeRegionMode.None, "Region2");
-                       statement.EndDirectives.Add(directive2);
-                       Assert.Equal(new CodeRegionDirective[] { directive1, directive2 }, statement.EndDirectives.Cast<CodeDirective>());
-               }
-       }
+    public abstract class CodeStatementTestBase<T> : CodeObjectTestBase<T> where T : CodeStatement, new()
+    {
+        [Fact]
+        public void Ctor_Default_StatementBase()
+        {
+            CodeStatement statement = new T();
+            Assert.Null(statement.LinePragma);
+
+            Assert.Empty(statement.StartDirectives);
+            Assert.Empty(statement.EndDirectives);
+        }
+
+        [Theory]
+        [MemberData(nameof(LinePragma_TestData))]
+        public void LinePragma_Set_Get_ReturnsExpected(CodeLinePragma value)
+        {
+            CodeStatement statement = new T() { LinePragma = value };
+            Assert.Equal(value, statement.LinePragma);
+        }
+
+        [Fact]
+        public void StartDirectives_AddMultiple_ReturnsExpected()
+        {
+            CodeStatement statement = new T();
+
+            CodeRegionDirective directive1 = new CodeRegionDirective(CodeRegionMode.None, "Region1");
+            statement.StartDirectives.Add(directive1);
+            Assert.Equal(new CodeRegionDirective[] { directive1 }, statement.StartDirectives.Cast<CodeDirective>());
+
+            CodeRegionDirective directive2 = new CodeRegionDirective(CodeRegionMode.None, "Region2");
+            statement.StartDirectives.Add(directive2);
+            Assert.Equal(new CodeRegionDirective[] { directive1, directive2 }, statement.StartDirectives.Cast<CodeDirective>());
+        }
+
+        [Fact]
+        public void EndDirectives_AddMultiple_ReturnsExpected()
+        {
+            CodeStatement statement = new T();
+
+            CodeRegionDirective directive1 = new CodeRegionDirective(CodeRegionMode.None, "Region1");
+            statement.EndDirectives.Add(directive1);
+            Assert.Equal(new CodeRegionDirective[] { directive1 }, statement.EndDirectives.Cast<CodeDirective>());
+
+            CodeRegionDirective directive2 = new CodeRegionDirective(CodeRegionMode.None, "Region2");
+            statement.EndDirectives.Add(directive2);
+            Assert.Equal(new CodeRegionDirective[] { directive1, directive2 }, statement.EndDirectives.Cast<CodeDirective>());
+        }
+    }
 }
index ed9b3d0..1e134ee 100644 (file)
@@ -6,30 +6,30 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeThrowExceptionStatementTests : CodeStatementTestBase<CodeThrowExceptionStatement>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var throwException = new CodeThrowExceptionStatement();
-                       Assert.Null(throwException.ToThrow);
-               }
+    public class CodeThrowExceptionStatementTests : CodeStatementTestBase<CodeThrowExceptionStatement>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var throwException = new CodeThrowExceptionStatement();
+            Assert.Null(throwException.ToThrow);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Ctor_CodeExpression(CodeExpression expression)
-               {
-                       var throwException = new CodeThrowExceptionStatement(expression);
-                       Assert.Equal(expression, throwException.ToThrow);
-               }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Ctor_CodeExpression(CodeExpression expression)
+        {
+            var throwException = new CodeThrowExceptionStatement(expression);
+            Assert.Equal(expression, throwException.ToThrow);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void Expression_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var throwException = new CodeThrowExceptionStatement();
-                       throwException.ToThrow = value;
-                       Assert.Equal(value, throwException.ToThrow);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void Expression_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var throwException = new CodeThrowExceptionStatement();
+            throwException.ToThrow = value;
+            Assert.Equal(value, throwException.ToThrow);
+        }
+    }
 }
index 57c0810..22c1f96 100644 (file)
@@ -8,137 +8,137 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeTryCatchFinallyStatementTests : CodeStatementTestBase<CodeTryCatchFinallyStatement>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var tryCatchFinally = new CodeTryCatchFinallyStatement();
-                       Assert.Empty(tryCatchFinally.TryStatements);
-                       Assert.Empty(tryCatchFinally.CatchClauses);
-                       Assert.Empty(tryCatchFinally.FinallyStatements);
-               }
-
-               public static IEnumerable<object[]> Ctor_CodeStatementArray_CodeCatchClauseArray_TestData()
-               {
-                       yield return new object[] { new CodeStatement[0], new CodeCatchClause[0] };
-                       yield return new object[] { new CodeStatement[] { new CodeCommentStatement("Comment") }, new CodeCatchClause[0] };
-                       yield return new object[] { new CodeStatement[0], new CodeCatchClause[] { new CodeCatchClause("Local") } };
-                       yield return new object[] { new CodeStatement[] { new CodeCommentStatement("Comment") }, new CodeCatchClause[] { new CodeCatchClause("Local") } };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_CodeStatementArray_CodeCatchClauseArray_TestData))]
-               public void Ctor_CodeStatementArray_CodeCatchClauseArray(CodeStatement[] tryStatements, CodeCatchClause[] catchClauses)
-               {
-                       var tryCatchFinally = new CodeTryCatchFinallyStatement(tryStatements, catchClauses);
-                       Assert.Equal(tryStatements, tryCatchFinally.TryStatements.Cast<CodeStatement>());
-                       Assert.Equal(catchClauses, tryCatchFinally.CatchClauses.Cast<CodeCatchClause>());
-                       Assert.Empty(tryCatchFinally.FinallyStatements);
-               }
-
-               public static IEnumerable<object[]> Ctor_CodeStatementArray_CodeCatchClauseArray_CodeStatementArray_TestData()
-               {
-                       yield return new object[] { new CodeStatement[0], new CodeCatchClause[0], new CodeStatement[0] };
-                       yield return new object[] { new CodeStatement[] { new CodeCommentStatement("Comment") }, new CodeCatchClause[0], new CodeStatement[0] };
-                       yield return new object[] { new CodeStatement[0], new CodeCatchClause[] { new CodeCatchClause("Local") }, new CodeStatement[0] };
-                       yield return new object[] { new CodeStatement[0], new CodeCatchClause[0], new CodeStatement[] { new CodeCommentStatement("Comment") } };
-                       yield return new object[] { new CodeStatement[] { new CodeCommentStatement("Comment") }, new CodeCatchClause[] { new CodeCatchClause("Local") }, new CodeStatement[] { new CodeCommentStatement("Comment") } };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_CodeStatementArray_CodeCatchClauseArray_CodeStatementArray_TestData))]
-               public void Ctor_CodeStatementArray_CodeCatchClauseArray_CodeStatementArray(CodeStatement[] tryStatements, CodeCatchClause[] catchClauses, CodeStatement[] finallyStatements)
-               {
-                       var tryCatchFinally = new CodeTryCatchFinallyStatement(tryStatements, catchClauses, finallyStatements);
-                       Assert.Equal(tryStatements, tryCatchFinally.TryStatements.Cast<CodeStatement>());
-                       Assert.Equal(catchClauses, tryCatchFinally.CatchClauses.Cast<CodeCatchClause>());
-                       Assert.Equal(finallyStatements, tryCatchFinally.FinallyStatements.Cast<CodeStatement>());
-               }
-
-               [Fact]
-               public void Ctor_NullTryStatements_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(null, new CodeCatchClause[0]));
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(null, new CodeCatchClause[0], new CodeStatement[0]));
-               }
-
-               [Fact]
-               public void Ctor_NullObjectInTryStatements_ThrowsArgumentNullException()
-               {
-                       CodeStatement[] tryStatements = new CodeStatement[] { null };
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(tryStatements, new CodeCatchClause[0]));
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(tryStatements, new CodeCatchClause[0], new CodeStatement[0]));
-               }
-
-               [Fact]
-               public void Ctor_NullCodeCatchClauses_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(new CodeStatement[0], null));
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(new CodeStatement[0], null, new CodeStatement[0]));
-               }
-
-               [Fact]
-               public void Ctor_NullObjectInCodeCatchClauses_ThrowsArgumentNullException()
-               {
-                       CodeCatchClause[] catchClauses = new CodeCatchClause[] { null };
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(new CodeStatement[0], catchClauses));
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(new CodeStatement[0], catchClauses, new CodeStatement[0]));
-               }
-
-               [Fact]
-               public void Ctor_NullFinallyStatements_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(new CodeStatement[0], new CodeCatchClause[0], null));
-               }
-
-               [Fact]
-               public void Ctor_NullObjectInFinallyStatements_ThrowsArgumentNullException()
-               {
-                       CodeStatement[] finallyStatements = new CodeStatement[] { null };
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(new CodeStatement[0], new CodeCatchClause[0], finallyStatements));
-               }
-
-               [Fact]
-               public void TryStatements_AddMultiple_ReturnsExpected()
-               {
-                       var tryCatchFinally = new CodeTryCatchFinallyStatement();
-
-                       CodeStatement statement1 = new CodeCommentStatement("Value1");
-                       tryCatchFinally.TryStatements.Add(statement1);
-                       Assert.Equal(new CodeStatement[] { statement1 }, tryCatchFinally.TryStatements.Cast<CodeStatement>());
-
-                       CodeStatement statement2 = new CodeCommentStatement("Value1");
-                       tryCatchFinally.TryStatements.Add(statement2);
-                       Assert.Equal(new CodeStatement[] { statement1, statement2 }, tryCatchFinally.TryStatements.Cast<CodeStatement>());
-               }
-
-               [Fact]
-               public void CatchClauses_AddMultiple_ReturnsExpected()
-               {
-                       var tryCatchFinally = new CodeTryCatchFinallyStatement();
-
-                       CodeCatchClause catchClause1 = new CodeCatchClause("Local1");
-                       tryCatchFinally.CatchClauses.Add(catchClause1);
-                       Assert.Equal(new CodeCatchClause[] { catchClause1 }, tryCatchFinally.CatchClauses.Cast<CodeCatchClause>());
-
-                       CodeCatchClause catchClause2 = new CodeCatchClause("Local2");
-                       tryCatchFinally.CatchClauses.Add(catchClause2);
-                       Assert.Equal(new CodeCatchClause[] { catchClause1, catchClause2 }, tryCatchFinally.CatchClauses.Cast<CodeCatchClause>());
-               }
-
-               [Fact]
-               public void FinallyStatements_AddMultiple_ReturnsExpected()
-               {
-                       var tryCatchFinally = new CodeTryCatchFinallyStatement();
-
-                       CodeStatement statement1 = new CodeCommentStatement("Value1");
-                       tryCatchFinally.FinallyStatements.Add(statement1);
-                       Assert.Equal(new CodeStatement[] { statement1 }, tryCatchFinally.FinallyStatements.Cast<CodeStatement>());
-
-                       CodeStatement statement2 = new CodeCommentStatement("Value1");
-                       tryCatchFinally.FinallyStatements.Add(statement2);
-                       Assert.Equal(new CodeStatement[] { statement1, statement2 }, tryCatchFinally.FinallyStatements.Cast<CodeStatement>());
-               }
-       }
+    public class CodeTryCatchFinallyStatementTests : CodeStatementTestBase<CodeTryCatchFinallyStatement>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var tryCatchFinally = new CodeTryCatchFinallyStatement();
+            Assert.Empty(tryCatchFinally.TryStatements);
+            Assert.Empty(tryCatchFinally.CatchClauses);
+            Assert.Empty(tryCatchFinally.FinallyStatements);
+        }
+
+        public static IEnumerable<object[]> Ctor_CodeStatementArray_CodeCatchClauseArray_TestData()
+        {
+            yield return new object[] { new CodeStatement[0], new CodeCatchClause[0] };
+            yield return new object[] { new CodeStatement[] { new CodeCommentStatement("Comment") }, new CodeCatchClause[0] };
+            yield return new object[] { new CodeStatement[0], new CodeCatchClause[] { new CodeCatchClause("Local") } };
+            yield return new object[] { new CodeStatement[] { new CodeCommentStatement("Comment") }, new CodeCatchClause[] { new CodeCatchClause("Local") } };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_CodeStatementArray_CodeCatchClauseArray_TestData))]
+        public void Ctor_CodeStatementArray_CodeCatchClauseArray(CodeStatement[] tryStatements, CodeCatchClause[] catchClauses)
+        {
+            var tryCatchFinally = new CodeTryCatchFinallyStatement(tryStatements, catchClauses);
+            Assert.Equal(tryStatements, tryCatchFinally.TryStatements.Cast<CodeStatement>());
+            Assert.Equal(catchClauses, tryCatchFinally.CatchClauses.Cast<CodeCatchClause>());
+            Assert.Empty(tryCatchFinally.FinallyStatements);
+        }
+
+        public static IEnumerable<object[]> Ctor_CodeStatementArray_CodeCatchClauseArray_CodeStatementArray_TestData()
+        {
+            yield return new object[] { new CodeStatement[0], new CodeCatchClause[0], new CodeStatement[0] };
+            yield return new object[] { new CodeStatement[] { new CodeCommentStatement("Comment") }, new CodeCatchClause[0], new CodeStatement[0] };
+            yield return new object[] { new CodeStatement[0], new CodeCatchClause[] { new CodeCatchClause("Local") }, new CodeStatement[0] };
+            yield return new object[] { new CodeStatement[0], new CodeCatchClause[0], new CodeStatement[] { new CodeCommentStatement("Comment") } };
+            yield return new object[] { new CodeStatement[] { new CodeCommentStatement("Comment") }, new CodeCatchClause[] { new CodeCatchClause("Local") }, new CodeStatement[] { new CodeCommentStatement("Comment") } };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_CodeStatementArray_CodeCatchClauseArray_CodeStatementArray_TestData))]
+        public void Ctor_CodeStatementArray_CodeCatchClauseArray_CodeStatementArray(CodeStatement[] tryStatements, CodeCatchClause[] catchClauses, CodeStatement[] finallyStatements)
+        {
+            var tryCatchFinally = new CodeTryCatchFinallyStatement(tryStatements, catchClauses, finallyStatements);
+            Assert.Equal(tryStatements, tryCatchFinally.TryStatements.Cast<CodeStatement>());
+            Assert.Equal(catchClauses, tryCatchFinally.CatchClauses.Cast<CodeCatchClause>());
+            Assert.Equal(finallyStatements, tryCatchFinally.FinallyStatements.Cast<CodeStatement>());
+        }
+
+        [Fact]
+        public void Ctor_NullTryStatements_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(null, new CodeCatchClause[0]));
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(null, new CodeCatchClause[0], new CodeStatement[0]));
+        }
+
+        [Fact]
+        public void Ctor_NullObjectInTryStatements_ThrowsArgumentNullException()
+        {
+            CodeStatement[] tryStatements = new CodeStatement[] { null };
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(tryStatements, new CodeCatchClause[0]));
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(tryStatements, new CodeCatchClause[0], new CodeStatement[0]));
+        }
+
+        [Fact]
+        public void Ctor_NullCodeCatchClauses_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(new CodeStatement[0], null));
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(new CodeStatement[0], null, new CodeStatement[0]));
+        }
+
+        [Fact]
+        public void Ctor_NullObjectInCodeCatchClauses_ThrowsArgumentNullException()
+        {
+            CodeCatchClause[] catchClauses = new CodeCatchClause[] { null };
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(new CodeStatement[0], catchClauses));
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(new CodeStatement[0], catchClauses, new CodeStatement[0]));
+        }
+
+        [Fact]
+        public void Ctor_NullFinallyStatements_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(new CodeStatement[0], new CodeCatchClause[0], null));
+        }
+
+        [Fact]
+        public void Ctor_NullObjectInFinallyStatements_ThrowsArgumentNullException()
+        {
+            CodeStatement[] finallyStatements = new CodeStatement[] { null };
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTryCatchFinallyStatement(new CodeStatement[0], new CodeCatchClause[0], finallyStatements));
+        }
+
+        [Fact]
+        public void TryStatements_AddMultiple_ReturnsExpected()
+        {
+            var tryCatchFinally = new CodeTryCatchFinallyStatement();
+
+            CodeStatement statement1 = new CodeCommentStatement("Value1");
+            tryCatchFinally.TryStatements.Add(statement1);
+            Assert.Equal(new CodeStatement[] { statement1 }, tryCatchFinally.TryStatements.Cast<CodeStatement>());
+
+            CodeStatement statement2 = new CodeCommentStatement("Value1");
+            tryCatchFinally.TryStatements.Add(statement2);
+            Assert.Equal(new CodeStatement[] { statement1, statement2 }, tryCatchFinally.TryStatements.Cast<CodeStatement>());
+        }
+
+        [Fact]
+        public void CatchClauses_AddMultiple_ReturnsExpected()
+        {
+            var tryCatchFinally = new CodeTryCatchFinallyStatement();
+
+            CodeCatchClause catchClause1 = new CodeCatchClause("Local1");
+            tryCatchFinally.CatchClauses.Add(catchClause1);
+            Assert.Equal(new CodeCatchClause[] { catchClause1 }, tryCatchFinally.CatchClauses.Cast<CodeCatchClause>());
+
+            CodeCatchClause catchClause2 = new CodeCatchClause("Local2");
+            tryCatchFinally.CatchClauses.Add(catchClause2);
+            Assert.Equal(new CodeCatchClause[] { catchClause1, catchClause2 }, tryCatchFinally.CatchClauses.Cast<CodeCatchClause>());
+        }
+
+        [Fact]
+        public void FinallyStatements_AddMultiple_ReturnsExpected()
+        {
+            var tryCatchFinally = new CodeTryCatchFinallyStatement();
+
+            CodeStatement statement1 = new CodeCommentStatement("Value1");
+            tryCatchFinally.FinallyStatements.Add(statement1);
+            Assert.Equal(new CodeStatement[] { statement1 }, tryCatchFinally.FinallyStatements.Cast<CodeStatement>());
+
+            CodeStatement statement2 = new CodeCommentStatement("Value1");
+            tryCatchFinally.FinallyStatements.Add(statement2);
+            Assert.Equal(new CodeStatement[] { statement1, statement2 }, tryCatchFinally.FinallyStatements.Cast<CodeStatement>());
+        }
+    }
 }
index 737e6c6..37d4635 100644 (file)
@@ -6,13 +6,13 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeTypeConstructorTests : CodeObjectTestBase<CodeTypeConstructor>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var constructor = new CodeTypeConstructor();
-                       Assert.Equal(".cctor", constructor.Name);
-               }
-       }
+    public class CodeTypeConstructorTests : CodeObjectTestBase<CodeTypeConstructor>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var constructor = new CodeTypeConstructor();
+            Assert.Equal(".cctor", constructor.Name);
+        }
+    }
 }
index dd3e387..26d3673 100644 (file)
@@ -8,194 +8,194 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeTypeDeclarationTests : CodeTypeMemberTestBase<CodeTypeDeclaration>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var declaration = new CodeTypeDeclaration();
-                       Assert.Empty(declaration.Name);
-                       Assert.True(declaration.IsClass);
-                       Assert.False(declaration.IsStruct);
-                       Assert.False(declaration.IsEnum);
-                       Assert.False(declaration.IsInterface);
-                       Assert.False(declaration.IsPartial);
-               }
-
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Ctor_String(string name)
-               {
-                       var declaration = new CodeTypeDeclaration(name);
-                       Assert.Equal(name ?? string.Empty, declaration.Name);
-               }
-
-               [Theory]
-               [InlineData(true)]
-               [InlineData(false)]
-               public void IsClass_Set_Get_ReturnsTrue(bool value)
-               {
-                       var declaration = new CodeTypeDeclaration();
-                       declaration.IsClass = value;
-                       Assert.True(declaration.IsClass);
-                       Assert.False(declaration.IsStruct);
-                       Assert.False(declaration.IsEnum);
-                       Assert.False(declaration.IsInterface);
-               }
-
-               [Fact]
-               public void IsClass_SetTrue_WasStruct_ReturnsTrue()
-               {
-                       var declaration = new CodeTypeDeclaration() { IsStruct = true };
-                       declaration.IsClass = true;
-                       Assert.False(declaration.IsStruct);
-                       Assert.False(declaration.IsEnum);
-                       Assert.False(declaration.IsInterface);
-               }
-
-               [Theory]
-               [InlineData(true)]
-               [InlineData(false)]
-               public void IsStruct_Set_Get_ReturnsExpected(bool value)
-               {
-                       var declaration = new CodeTypeDeclaration();
-                       declaration.IsStruct = value;
-                       Assert.Equal(value, declaration.IsStruct);
-                       Assert.Equal(!value, declaration.IsClass);
-                       Assert.False(declaration.IsEnum);
-                       Assert.False(declaration.IsInterface);
-               }
-
-               [Theory]
-               [InlineData(true)]
-               [InlineData(false)]
-               public void IsEnum_Set_Get_ReturnsExpected(bool value)
-               {
-                       var declaration = new CodeTypeDeclaration();
-                       declaration.IsEnum = value;
-                       Assert.Equal(value, declaration.IsEnum);
-                       Assert.Equal(!value, declaration.IsClass);
-                       Assert.False(declaration.IsStruct);
-                       Assert.False(declaration.IsInterface);
-               }
-
-               [Theory]
-               [InlineData(true)]
-               [InlineData(false)]
-               public void IsInterface_Set_Get_ReturnsExpected(bool value)
-               {
-                       var declaration = new CodeTypeDeclaration();
-                       declaration.IsInterface = value;
-                       Assert.Equal(value, declaration.IsInterface);
-                       Assert.Equal(!value, declaration.IsClass);
-                       Assert.False(declaration.IsStruct);
-                       Assert.False(declaration.IsEnum);
-               }
-
-               [Theory]
-               [InlineData(true)]
-               [InlineData(false)]
-               public void IsPartial_Set_Get_ReturnsExpected(bool value)
-               {
-                       var declaration = new CodeTypeDeclaration();
-                       declaration.IsPartial = value;
-                       Assert.Equal(value, declaration.IsPartial);
-               }
-
-               [Theory]
-               [InlineData(TypeAttributes.Class - 1)]
-               [InlineData(TypeAttributes.Class)]
-               [InlineData(TypeAttributes.NotPublic | TypeAttributes.Public)]
-               [InlineData((TypeAttributes)int.MaxValue)]
-               public void TypeAttributes_Set_Get_ReturnExpected(TypeAttributes value)
-               {
-                       var declaration = new CodeTypeDeclaration();
-                       declaration.TypeAttributes = value;
-                       Assert.Equal(value, declaration.TypeAttributes);
-               }
-
-               [Fact]
-               public void BaseTypes_AddMultiple_ReturnsExpected()
-               {
-                       var declaration = new CodeTypeDeclaration();
-
-                       CodeTypeReference type1 = new CodeTypeReference(typeof(int));
-                       declaration.BaseTypes.Add(type1);
-                       Assert.Equal(new CodeTypeReference[] { type1 }, declaration.BaseTypes.Cast<CodeTypeReference>());
-
-                       CodeTypeReference type2 = new CodeTypeReference(typeof(char));
-                       declaration.BaseTypes.Add(type2);
-                       Assert.Equal(new CodeTypeReference[] { type1, type2 }, declaration.BaseTypes.Cast<CodeTypeReference>());
-               }
-
-               [Fact]
-               public void BaseTypes_Get_CallsPopulateBaseTypesOnce()
-               {
-                       var declaration = new CodeTypeDeclaration();
-                       bool calledPopulateBaseTypes = false;
-                       declaration.PopulateBaseTypes += (object sender, EventArgs args) =>
-                       {
-                               calledPopulateBaseTypes = true;
-                               Assert.Same(declaration, sender);
-                               Assert.Equal(EventArgs.Empty, args);
-                       };
-
-                       declaration.BaseTypes.Add(new CodeTypeReference(typeof(int)));
-                       Assert.True(calledPopulateBaseTypes);
-
-                       // Only calls PopulateBaseTypes once
-                       calledPopulateBaseTypes = false;
-                       declaration.BaseTypes.Add(new CodeTypeReference(typeof(char)));
-                       Assert.False(calledPopulateBaseTypes);
-               }
-
-               [Fact]
-               public void Members_AddMultiple_ReturnsExpected()
-               {
-                       var declaration = new CodeTypeDeclaration();
-
-                       CodeTypeMember member1 = new CodeMemberField("Type", "Name1");
-                       declaration.Members.Add(member1);
-                       Assert.Equal(new CodeTypeMember[] { member1 }, declaration.Members.Cast<CodeTypeMember>());
-
-                       CodeTypeMember member2 = new CodeMemberField("Type", "Name1");
-                       declaration.Members.Add(member2);
-                       Assert.Equal(new CodeTypeMember[] { member1, member2 }, declaration.Members.Cast<CodeTypeMember>());
-               }
-
-               [Fact]
-               public void Members_Get_CallsPopulateMembersOnce()
-               {
-                       var declaration = new CodeTypeDeclaration();
-                       bool calledPopulateMembers = false;
-                       declaration.PopulateMembers += (object sender, EventArgs args) =>
-                       {
-                               calledPopulateMembers = true;
-                               Assert.Same(declaration, sender);
-                               Assert.Equal(EventArgs.Empty, args);
-                       };
-
-                       declaration.Members.Add(new CodeMemberField("Type", "Name1"));
-                       Assert.True(calledPopulateMembers);
-
-                       // Only calls PopulateMembers once
-                       calledPopulateMembers = false;
-                       declaration.Members.Add(new CodeMemberField("Type", "Name2"));
-                       Assert.False(calledPopulateMembers);
-               }
-
-               [Fact]
-               public void TypeParameters_AddMultiple_ReturnsExpected()
-               {
-                       var declaration = new CodeTypeDeclaration();
-
-                       CodeTypeParameter parameter1 = new CodeTypeParameter("Name1");
-                       declaration.TypeParameters.Add(parameter1);
-                       Assert.Equal(new CodeTypeParameter[] { parameter1 }, declaration.TypeParameters.Cast<CodeTypeParameter>());
-
-                       CodeTypeParameter parameter2 = new CodeTypeParameter("Name2");
-                       declaration.TypeParameters.Add(parameter2);
-                       Assert.Equal(new CodeTypeParameter[] { parameter1, parameter2 }, declaration.TypeParameters.Cast<CodeTypeParameter>());
-               }
-       }
+    public class CodeTypeDeclarationTests : CodeTypeMemberTestBase<CodeTypeDeclaration>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var declaration = new CodeTypeDeclaration();
+            Assert.Empty(declaration.Name);
+            Assert.True(declaration.IsClass);
+            Assert.False(declaration.IsStruct);
+            Assert.False(declaration.IsEnum);
+            Assert.False(declaration.IsInterface);
+            Assert.False(declaration.IsPartial);
+        }
+
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Ctor_String(string name)
+        {
+            var declaration = new CodeTypeDeclaration(name);
+            Assert.Equal(name ?? string.Empty, declaration.Name);
+        }
+
+        [Theory]
+        [InlineData(true)]
+        [InlineData(false)]
+        public void IsClass_Set_Get_ReturnsTrue(bool value)
+        {
+            var declaration = new CodeTypeDeclaration();
+            declaration.IsClass = value;
+            Assert.True(declaration.IsClass);
+            Assert.False(declaration.IsStruct);
+            Assert.False(declaration.IsEnum);
+            Assert.False(declaration.IsInterface);
+        }
+
+        [Fact]
+        public void IsClass_SetTrue_WasStruct_ReturnsTrue()
+        {
+            var declaration = new CodeTypeDeclaration() { IsStruct = true };
+            declaration.IsClass = true;
+            Assert.False(declaration.IsStruct);
+            Assert.False(declaration.IsEnum);
+            Assert.False(declaration.IsInterface);
+        }
+
+        [Theory]
+        [InlineData(true)]
+        [InlineData(false)]
+        public void IsStruct_Set_Get_ReturnsExpected(bool value)
+        {
+            var declaration = new CodeTypeDeclaration();
+            declaration.IsStruct = value;
+            Assert.Equal(value, declaration.IsStruct);
+            Assert.Equal(!value, declaration.IsClass);
+            Assert.False(declaration.IsEnum);
+            Assert.False(declaration.IsInterface);
+        }
+
+        [Theory]
+        [InlineData(true)]
+        [InlineData(false)]
+        public void IsEnum_Set_Get_ReturnsExpected(bool value)
+        {
+            var declaration = new CodeTypeDeclaration();
+            declaration.IsEnum = value;
+            Assert.Equal(value, declaration.IsEnum);
+            Assert.Equal(!value, declaration.IsClass);
+            Assert.False(declaration.IsStruct);
+            Assert.False(declaration.IsInterface);
+        }
+
+        [Theory]
+        [InlineData(true)]
+        [InlineData(false)]
+        public void IsInterface_Set_Get_ReturnsExpected(bool value)
+        {
+            var declaration = new CodeTypeDeclaration();
+            declaration.IsInterface = value;
+            Assert.Equal(value, declaration.IsInterface);
+            Assert.Equal(!value, declaration.IsClass);
+            Assert.False(declaration.IsStruct);
+            Assert.False(declaration.IsEnum);
+        }
+
+        [Theory]
+        [InlineData(true)]
+        [InlineData(false)]
+        public void IsPartial_Set_Get_ReturnsExpected(bool value)
+        {
+            var declaration = new CodeTypeDeclaration();
+            declaration.IsPartial = value;
+            Assert.Equal(value, declaration.IsPartial);
+        }
+
+        [Theory]
+        [InlineData(TypeAttributes.Class - 1)]
+        [InlineData(TypeAttributes.Class)]
+        [InlineData(TypeAttributes.NotPublic | TypeAttributes.Public)]
+        [InlineData((TypeAttributes)int.MaxValue)]
+        public void TypeAttributes_Set_Get_ReturnExpected(TypeAttributes value)
+        {
+            var declaration = new CodeTypeDeclaration();
+            declaration.TypeAttributes = value;
+            Assert.Equal(value, declaration.TypeAttributes);
+        }
+
+        [Fact]
+        public void BaseTypes_AddMultiple_ReturnsExpected()
+        {
+            var declaration = new CodeTypeDeclaration();
+
+            CodeTypeReference type1 = new CodeTypeReference(typeof(int));
+            declaration.BaseTypes.Add(type1);
+            Assert.Equal(new CodeTypeReference[] { type1 }, declaration.BaseTypes.Cast<CodeTypeReference>());
+
+            CodeTypeReference type2 = new CodeTypeReference(typeof(char));
+            declaration.BaseTypes.Add(type2);
+            Assert.Equal(new CodeTypeReference[] { type1, type2 }, declaration.BaseTypes.Cast<CodeTypeReference>());
+        }
+
+        [Fact]
+        public void BaseTypes_Get_CallsPopulateBaseTypesOnce()
+        {
+            var declaration = new CodeTypeDeclaration();
+            bool calledPopulateBaseTypes = false;
+            declaration.PopulateBaseTypes += (object sender, EventArgs args) =>
+            {
+                calledPopulateBaseTypes = true;
+                Assert.Same(declaration, sender);
+                Assert.Equal(EventArgs.Empty, args);
+            };
+
+            declaration.BaseTypes.Add(new CodeTypeReference(typeof(int)));
+            Assert.True(calledPopulateBaseTypes);
+
+            // Only calls PopulateBaseTypes once
+            calledPopulateBaseTypes = false;
+            declaration.BaseTypes.Add(new CodeTypeReference(typeof(char)));
+            Assert.False(calledPopulateBaseTypes);
+        }
+
+        [Fact]
+        public void Members_AddMultiple_ReturnsExpected()
+        {
+            var declaration = new CodeTypeDeclaration();
+
+            CodeTypeMember member1 = new CodeMemberField("Type", "Name1");
+            declaration.Members.Add(member1);
+            Assert.Equal(new CodeTypeMember[] { member1 }, declaration.Members.Cast<CodeTypeMember>());
+
+            CodeTypeMember member2 = new CodeMemberField("Type", "Name1");
+            declaration.Members.Add(member2);
+            Assert.Equal(new CodeTypeMember[] { member1, member2 }, declaration.Members.Cast<CodeTypeMember>());
+        }
+
+        [Fact]
+        public void Members_Get_CallsPopulateMembersOnce()
+        {
+            var declaration = new CodeTypeDeclaration();
+            bool calledPopulateMembers = false;
+            declaration.PopulateMembers += (object sender, EventArgs args) =>
+            {
+                calledPopulateMembers = true;
+                Assert.Same(declaration, sender);
+                Assert.Equal(EventArgs.Empty, args);
+            };
+
+            declaration.Members.Add(new CodeMemberField("Type", "Name1"));
+            Assert.True(calledPopulateMembers);
+
+            // Only calls PopulateMembers once
+            calledPopulateMembers = false;
+            declaration.Members.Add(new CodeMemberField("Type", "Name2"));
+            Assert.False(calledPopulateMembers);
+        }
+
+        [Fact]
+        public void TypeParameters_AddMultiple_ReturnsExpected()
+        {
+            var declaration = new CodeTypeDeclaration();
+
+            CodeTypeParameter parameter1 = new CodeTypeParameter("Name1");
+            declaration.TypeParameters.Add(parameter1);
+            Assert.Equal(new CodeTypeParameter[] { parameter1 }, declaration.TypeParameters.Cast<CodeTypeParameter>());
+
+            CodeTypeParameter parameter2 = new CodeTypeParameter("Name2");
+            declaration.TypeParameters.Add(parameter2);
+            Assert.Equal(new CodeTypeParameter[] { parameter1, parameter2 }, declaration.TypeParameters.Cast<CodeTypeParameter>());
+        }
+    }
 }
index 4680315..a8a9643 100644 (file)
@@ -7,60 +7,60 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeTypeDelegateTests : CodeObjectTestBase<CodeTypeDelegate>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var typeDelegate = new CodeTypeDelegate();
-                       Assert.Empty(typeDelegate.Name);
+    public class CodeTypeDelegateTests : CodeObjectTestBase<CodeTypeDelegate>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var typeDelegate = new CodeTypeDelegate();
+            Assert.Empty(typeDelegate.Name);
 
-                       Assert.Equal(1, typeDelegate.BaseTypes.Count);
-                       Assert.Equal(typeof(Delegate).FullName, typeDelegate.BaseTypes[0].BaseType);
+            Assert.Equal(1, typeDelegate.BaseTypes.Count);
+            Assert.Equal(typeof(Delegate).FullName, typeDelegate.BaseTypes[0].BaseType);
 
-                       Assert.True(typeDelegate.IsClass);
+            Assert.True(typeDelegate.IsClass);
 
-                       Assert.Equal(typeof(void).FullName, typeDelegate.ReturnType.BaseType);
-                       Assert.Empty(typeDelegate.Parameters);
-               }
+            Assert.Equal(typeof(void).FullName, typeDelegate.ReturnType.BaseType);
+            Assert.Empty(typeDelegate.Parameters);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Ctor_String(string name)
-               {
-                       var typeDelegate = new CodeTypeDelegate(name);
-                       Assert.Equal(name ?? string.Empty, typeDelegate.Name);
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Ctor_String(string name)
+        {
+            var typeDelegate = new CodeTypeDelegate(name);
+            Assert.Equal(name ?? string.Empty, typeDelegate.Name);
 
-                       Assert.Equal(1, typeDelegate.BaseTypes.Count);
-                       Assert.Equal(typeof(Delegate).FullName, typeDelegate.BaseTypes[0].BaseType);
+            Assert.Equal(1, typeDelegate.BaseTypes.Count);
+            Assert.Equal(typeof(Delegate).FullName, typeDelegate.BaseTypes[0].BaseType);
 
-                       Assert.True(typeDelegate.IsClass);
+            Assert.True(typeDelegate.IsClass);
 
-                       Assert.Equal(typeof(void).FullName, typeDelegate.ReturnType.BaseType);
-                       Assert.Empty(typeDelegate.Parameters);
-               }
+            Assert.Equal(typeof(void).FullName, typeDelegate.ReturnType.BaseType);
+            Assert.Empty(typeDelegate.Parameters);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void ReturnType_Set_Get_ReturnsExpected(CodeTypeReference value)
-               {
-                       var typeDelegate = new CodeTypeDelegate();
-                       typeDelegate.ReturnType = value;
-                       Assert.Equal((value ?? new CodeTypeReference("")).BaseType, typeDelegate.ReturnType.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void ReturnType_Set_Get_ReturnsExpected(CodeTypeReference value)
+        {
+            var typeDelegate = new CodeTypeDelegate();
+            typeDelegate.ReturnType = value;
+            Assert.Equal((value ?? new CodeTypeReference("")).BaseType, typeDelegate.ReturnType.BaseType);
+        }
 
-               [Fact]
-               public void Parameters_AddMultiple_ReturnsExpected()
-               {
-                       var typeDelegate = new CodeTypeDelegate();
+        [Fact]
+        public void Parameters_AddMultiple_ReturnsExpected()
+        {
+            var typeDelegate = new CodeTypeDelegate();
 
-                       CodeParameterDeclarationExpression parameter1 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name1");
-                       typeDelegate.Parameters.Add(parameter1);
-                       Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1 }, typeDelegate.Parameters.Cast<CodeParameterDeclarationExpression>());
+            CodeParameterDeclarationExpression parameter1 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name1");
+            typeDelegate.Parameters.Add(parameter1);
+            Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1 }, typeDelegate.Parameters.Cast<CodeParameterDeclarationExpression>());
 
-                       CodeParameterDeclarationExpression parameter2 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name2");
-                       typeDelegate.Parameters.Add(parameter2);
-                       Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1, parameter2 }, typeDelegate.Parameters.Cast<CodeParameterDeclarationExpression>());
-               }
-       }
+            CodeParameterDeclarationExpression parameter2 = new CodeParameterDeclarationExpression(new CodeTypeReference(typeof(int)), "name2");
+            typeDelegate.Parameters.Add(parameter2);
+            Assert.Equal(new CodeParameterDeclarationExpression[] { parameter1, parameter2 }, typeDelegate.Parameters.Cast<CodeParameterDeclarationExpression>());
+        }
+    }
 }
index d787dc2..9c15d36 100644 (file)
@@ -7,133 +7,133 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public abstract class CodeTypeMemberTestBase<T> : CodeObjectTestBase<T> where T : CodeTypeMember, new()
-       {
-               [Fact]
-               public void Ctor_Default_MemberBase()
-               {
-                       CodeTypeMember member = new T();
-                       Assert.Empty(member.Name);
-
-                       Assert.Equal(MemberAttributes.Private | MemberAttributes.Final, member.Attributes);
-                       Assert.Empty(member.CustomAttributes);
-
-                       Assert.Empty(member.Comments);
-                       Assert.Null(member.LinePragma);
-
-                       Assert.Empty(member.StartDirectives);
-                       Assert.Empty(member.EndDirectives);
-               }
-
-               [Theory]
-               [InlineData("Name")]
-               [InlineData("")]
-               [InlineData(null)]
-               public void Name_Set_Get_ReturnsExpected(string value)
-               {
-                       CodeTypeMember member = new T() { Name = value };
-                       Assert.Equal(value ?? string.Empty, member.Name);
-               }
-
-               [Theory]
-               [InlineData(MemberAttributes.Abstract)]
-               [InlineData(MemberAttributes.Public)]
-               [InlineData((MemberAttributes)0)]
-               [InlineData((MemberAttributes)int.MaxValue)]
-               public void Attrributes_Set_Get_ReturnsExpected(MemberAttributes value)
-               {
-                       CodeTypeMember member = new T() { Attributes = value };
-                       Assert.Equal(value, member.Attributes);
-               }
-
-               [Fact]
-               public void LinePragma_SetNull_Get_ReturnsNull()
-               {
-                       CodeTypeMember member = new T() { LinePragma = null };
-                       Assert.Null(member.LinePragma);
-               }
-
-               [Fact]
-               public void LinePragma_SetNonNull_Get_ReturnsExpected()
-               {
-                       CodeLinePragma pragma = new CodeLinePragma("FileName", 1);
-                       CodeTypeMember member = new T() { LinePragma = pragma };
-                       Assert.Equal(pragma, member.LinePragma);
-               }
-
-               [Fact]
-               public void CustomAttributes_SetNull_Get_ReturnsEmpty()
-               {
-                       CodeTypeMember member = new T() { CustomAttributes = null };
-                       Assert.Empty(member.CustomAttributes);
-               }
-
-               [Fact]
-               public void CustomAttributes_SetNonNull_Get_ReturnsExpected()
-               {
-                       CodeTypeMember member = new T() { CustomAttributes = null };
-                       CodeAttributeDeclarationCollection value = new CodeAttributeDeclarationCollection();
-                       value.Add(new CodeAttributeDeclaration("Name1"));
-                       value.Add(new CodeAttributeDeclaration("Name2"));
-
-                       member.CustomAttributes = value;
-                       Assert.Equal(value, member.CustomAttributes);
-               }
-
-               [Fact]
-               public void CustomAttributes_AddMultiple_ReturnsExpected()
-               {
-                       CodeTypeMember member = new T();
-
-                       CodeAttributeDeclaration attribute1 = new CodeAttributeDeclaration("Name1");
-                       member.CustomAttributes.Add(attribute1);
-                       Assert.Equal(new CodeAttributeDeclaration[] { attribute1 }, member.CustomAttributes.Cast<CodeAttributeDeclaration>());
-
-                       CodeAttributeDeclaration attribute2 = new CodeAttributeDeclaration("Name2");
-                       member.CustomAttributes.Add(attribute2);
-                       Assert.Equal(new CodeAttributeDeclaration[] { attribute1, attribute2 }, member.CustomAttributes.Cast<CodeAttributeDeclaration>());
-               }
-
-               [Fact]
-               public void Comments_AddMultiple_ReturnsExpected()
-               {
-                       CodeTypeMember member = new T();
-
-                       CodeCommentStatement comment1 = new CodeCommentStatement("Comment1");
-                       member.Comments.Add(comment1);
-                       Assert.Equal(new CodeCommentStatement[] { comment1 }, member.Comments.Cast<CodeCommentStatement>());
-
-                       CodeCommentStatement comment2 = new CodeCommentStatement("Comment2");
-                       member.Comments.Add(comment2);
-                       Assert.Equal(new CodeCommentStatement[] { comment1, comment2 }, member.Comments.Cast<CodeCommentStatement>());
-               }
-
-               [Fact]
-               public void StartDirectives_AddMultiple_ReturnsExpected()
-               {
-                       CodeTypeMember member = new T();
-
-                       CodeRegionDirective directive1 = new CodeRegionDirective(CodeRegionMode.None, "Region1");
-                       member.StartDirectives.Add(directive1);
-                       Assert.Equal(new CodeRegionDirective[] { directive1 }, member.StartDirectives.Cast<CodeDirective>());
-
-                       CodeRegionDirective directive2 = new CodeRegionDirective(CodeRegionMode.None, "Region2");
-                       member.StartDirectives.Add(directive2);
-                       Assert.Equal(new CodeRegionDirective[] { directive1, directive2 }, member.StartDirectives.Cast<CodeDirective>());
-               }
-
-               [Fact]
-               public void EndDirectives_AddMultiple_ReturnsExpected()
-               {
-                       CodeTypeMember member = new T();
-
-                       CodeRegionDirective directive1 = new CodeRegionDirective(CodeRegionMode.None, "Region1");
-                       member.EndDirectives.Add(directive1);
-                       Assert.Equal(new CodeRegionDirective[] { directive1 }, member.EndDirectives.Cast<CodeDirective>());
-
-                       CodeRegionDirective directive2 = new CodeRegionDirective(CodeRegionMode.None, "Region2");
-                       member.EndDirectives.Add(directive2);
-                       Assert.Equal(new CodeRegionDirective[] { directive1, directive2 }, member.EndDirectives.Cast<CodeDirective>());
-               }
-       }
+    public abstract class CodeTypeMemberTestBase<T> : CodeObjectTestBase<T> where T : CodeTypeMember, new()
+    {
+        [Fact]
+        public void Ctor_Default_MemberBase()
+        {
+            CodeTypeMember member = new T();
+            Assert.Empty(member.Name);
+
+            Assert.Equal(MemberAttributes.Private | MemberAttributes.Final, member.Attributes);
+            Assert.Empty(member.CustomAttributes);
+
+            Assert.Empty(member.Comments);
+            Assert.Null(member.LinePragma);
+
+            Assert.Empty(member.StartDirectives);
+            Assert.Empty(member.EndDirectives);
+        }
+
+        [Theory]
+        [InlineData("Name")]
+        [InlineData("")]
+        [InlineData(null)]
+        public void Name_Set_Get_ReturnsExpected(string value)
+        {
+            CodeTypeMember member = new T() { Name = value };
+            Assert.Equal(value ?? string.Empty, member.Name);
+        }
+
+        [Theory]
+        [InlineData(MemberAttributes.Abstract)]
+        [InlineData(MemberAttributes.Public)]
+        [InlineData((MemberAttributes)0)]
+        [InlineData((MemberAttributes)int.MaxValue)]
+        public void Attrributes_Set_Get_ReturnsExpected(MemberAttributes value)
+        {
+            CodeTypeMember member = new T() { Attributes = value };
+            Assert.Equal(value, member.Attributes);
+        }
+
+        [Fact]
+        public void LinePragma_SetNull_Get_ReturnsNull()
+        {
+            CodeTypeMember member = new T() { LinePragma = null };
+            Assert.Null(member.LinePragma);
+        }
+
+        [Fact]
+        public void LinePragma_SetNonNull_Get_ReturnsExpected()
+        {
+            CodeLinePragma pragma = new CodeLinePragma("FileName", 1);
+            CodeTypeMember member = new T() { LinePragma = pragma };
+            Assert.Equal(pragma, member.LinePragma);
+        }
+
+        [Fact]
+        public void CustomAttributes_SetNull_Get_ReturnsEmpty()
+        {
+            CodeTypeMember member = new T() { CustomAttributes = null };
+            Assert.Empty(member.CustomAttributes);
+        }
+
+        [Fact]
+        public void CustomAttributes_SetNonNull_Get_ReturnsExpected()
+        {
+            CodeTypeMember member = new T() { CustomAttributes = null };
+            CodeAttributeDeclarationCollection value = new CodeAttributeDeclarationCollection();
+            value.Add(new CodeAttributeDeclaration("Name1"));
+            value.Add(new CodeAttributeDeclaration("Name2"));
+
+            member.CustomAttributes = value;
+            Assert.Equal(value, member.CustomAttributes);
+        }
+
+        [Fact]
+        public void CustomAttributes_AddMultiple_ReturnsExpected()
+        {
+            CodeTypeMember member = new T();
+
+            CodeAttributeDeclaration attribute1 = new CodeAttributeDeclaration("Name1");
+            member.CustomAttributes.Add(attribute1);
+            Assert.Equal(new CodeAttributeDeclaration[] { attribute1 }, member.CustomAttributes.Cast<CodeAttributeDeclaration>());
+
+            CodeAttributeDeclaration attribute2 = new CodeAttributeDeclaration("Name2");
+            member.CustomAttributes.Add(attribute2);
+            Assert.Equal(new CodeAttributeDeclaration[] { attribute1, attribute2 }, member.CustomAttributes.Cast<CodeAttributeDeclaration>());
+        }
+
+        [Fact]
+        public void Comments_AddMultiple_ReturnsExpected()
+        {
+            CodeTypeMember member = new T();
+
+            CodeCommentStatement comment1 = new CodeCommentStatement("Comment1");
+            member.Comments.Add(comment1);
+            Assert.Equal(new CodeCommentStatement[] { comment1 }, member.Comments.Cast<CodeCommentStatement>());
+
+            CodeCommentStatement comment2 = new CodeCommentStatement("Comment2");
+            member.Comments.Add(comment2);
+            Assert.Equal(new CodeCommentStatement[] { comment1, comment2 }, member.Comments.Cast<CodeCommentStatement>());
+        }
+
+        [Fact]
+        public void StartDirectives_AddMultiple_ReturnsExpected()
+        {
+            CodeTypeMember member = new T();
+
+            CodeRegionDirective directive1 = new CodeRegionDirective(CodeRegionMode.None, "Region1");
+            member.StartDirectives.Add(directive1);
+            Assert.Equal(new CodeRegionDirective[] { directive1 }, member.StartDirectives.Cast<CodeDirective>());
+
+            CodeRegionDirective directive2 = new CodeRegionDirective(CodeRegionMode.None, "Region2");
+            member.StartDirectives.Add(directive2);
+            Assert.Equal(new CodeRegionDirective[] { directive1, directive2 }, member.StartDirectives.Cast<CodeDirective>());
+        }
+
+        [Fact]
+        public void EndDirectives_AddMultiple_ReturnsExpected()
+        {
+            CodeTypeMember member = new T();
+
+            CodeRegionDirective directive1 = new CodeRegionDirective(CodeRegionMode.None, "Region1");
+            member.EndDirectives.Add(directive1);
+            Assert.Equal(new CodeRegionDirective[] { directive1 }, member.EndDirectives.Cast<CodeDirective>());
+
+            CodeRegionDirective directive2 = new CodeRegionDirective(CodeRegionMode.None, "Region2");
+            member.EndDirectives.Add(directive2);
+            Assert.Equal(new CodeRegionDirective[] { directive1, directive2 }, member.EndDirectives.Cast<CodeDirective>());
+        }
+    }
 }
index 4adc63a..7272fe5 100644 (file)
@@ -7,66 +7,66 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeTypeOfExpressionTests : CodeObjectTestBase<CodeTypeOfExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var typeofExpression = new CodeTypeOfExpression();
-                       Assert.Equal(typeof(void).FullName, typeofExpression.Type.BaseType);
-               }
+    public class CodeTypeOfExpressionTests : CodeObjectTestBase<CodeTypeOfExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var typeofExpression = new CodeTypeOfExpression();
+            Assert.Equal(typeof(void).FullName, typeofExpression.Type.BaseType);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Ctor_CodeTypeReference_CodeExpression(CodeTypeReference type)
-               {
-                       var typeofExpression = new CodeTypeOfExpression(type);
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, typeofExpression.Type.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Ctor_CodeTypeReference_CodeExpression(CodeTypeReference type)
+        {
+            var typeofExpression = new CodeTypeOfExpression(type);
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, typeofExpression.Type.BaseType);
+        }
 
-               public static IEnumerable<object[]> Ctor_TypeString_TestData()
-               {
-                       yield return new object[] { null, "System.Void" };
-                       yield return new object[] { "", "System.Void" };
-                       yield return new object[] { "Int32", "Int32" };
-               }
+        public static IEnumerable<object[]> Ctor_TypeString_TestData()
+        {
+            yield return new object[] { null, "System.Void" };
+            yield return new object[] { "", "System.Void" };
+            yield return new object[] { "Int32", "Int32" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TypeString_TestData))]
-               public void Ctor_String_CodeExpression(string type, string expectedBaseType)
-               {
-                       var typeofExpression = new CodeTypeOfExpression(type);
-                       Assert.Equal(expectedBaseType, typeofExpression.Type.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TypeString_TestData))]
+        public void Ctor_String_CodeExpression(string type, string expectedBaseType)
+        {
+            var typeofExpression = new CodeTypeOfExpression(type);
+            Assert.Equal(expectedBaseType, typeofExpression.Type.BaseType);
+        }
 
-               public static IEnumerable<object[]> Ctor_Type_TestData()
-               {
-                       yield return new object[] { typeof(int), "System.Int32" };
-                       yield return new object[] { typeof(List<>), "System.Collections.Generic.List`1" };
-                       yield return new object[] { typeof(void), "System.Void" };
-               }
+        public static IEnumerable<object[]> Ctor_Type_TestData()
+        {
+            yield return new object[] { typeof(int), "System.Int32" };
+            yield return new object[] { typeof(List<>), "System.Collections.Generic.List`1" };
+            yield return new object[] { typeof(void), "System.Void" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_Type_TestData))]
-               public void Ctor_Type_CodeExpression(Type type, string expectedBaseType)
-               {
-                       var typeofExpression = new CodeTypeOfExpression(type);
-                       Assert.Equal(expectedBaseType, typeofExpression.Type.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_Type_TestData))]
+        public void Ctor_Type_CodeExpression(Type type, string expectedBaseType)
+        {
+            var typeofExpression = new CodeTypeOfExpression(type);
+            Assert.Equal(expectedBaseType, typeofExpression.Type.BaseType);
+        }
 
-               [Fact]
-               public void Ctor_NullType_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeTypeOfExpression((Type)null));
-               }
+        [Fact]
+        public void Ctor_NullType_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeTypeOfExpression((Type)null));
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Type_Set_Get_ReturnsExpected(CodeTypeReference value)
-               {
-                       var typeofExpression = new CodeTypeOfExpression();
-                       typeofExpression.Type = value;
-                       Assert.Equal((value ?? new CodeTypeReference("")).BaseType, typeofExpression.Type.BaseType);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Type_Set_Get_ReturnsExpected(CodeTypeReference value)
+        {
+            var typeofExpression = new CodeTypeOfExpression();
+            typeofExpression.Type = value;
+            Assert.Equal((value ?? new CodeTypeReference("")).BaseType, typeofExpression.Type.BaseType);
+        }
+    }
 }
index 6e03e68..4146d7e 100644 (file)
@@ -7,74 +7,74 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeTypeParameterTests : CodeObjectTestBase<CodeTypeParameter>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var typeParameter = new CodeTypeParameter();
-                       Assert.Empty(typeParameter.Name);
-                       Assert.Empty(typeParameter.Constraints);
-                       Assert.Empty(typeParameter.CustomAttributes);
-                       Assert.False(typeParameter.HasConstructorConstraint);
-               }
+    public class CodeTypeParameterTests : CodeObjectTestBase<CodeTypeParameter>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var typeParameter = new CodeTypeParameter();
+            Assert.Empty(typeParameter.Name);
+            Assert.Empty(typeParameter.Constraints);
+            Assert.Empty(typeParameter.CustomAttributes);
+            Assert.False(typeParameter.HasConstructorConstraint);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Ctor_String(string name)
-               {
-                       var typeParameter = new CodeTypeParameter(name);
-                       Assert.Equal(name ?? string.Empty, typeParameter.Name);
-                       Assert.Empty(typeParameter.Constraints);
-                       Assert.Empty(typeParameter.CustomAttributes);
-                       Assert.False(typeParameter.HasConstructorConstraint);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Ctor_String(string name)
+        {
+            var typeParameter = new CodeTypeParameter(name);
+            Assert.Equal(name ?? string.Empty, typeParameter.Name);
+            Assert.Empty(typeParameter.Constraints);
+            Assert.Empty(typeParameter.CustomAttributes);
+            Assert.False(typeParameter.HasConstructorConstraint);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Name_Set_Get_ReturnsExpected(string value)
-               {
-                       var typeParameter = new CodeTypeParameter();
-                       typeParameter.Name = value;
-                       Assert.Equal(value ?? string.Empty, typeParameter.Name);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Name_Set_Get_ReturnsExpected(string value)
+        {
+            var typeParameter = new CodeTypeParameter();
+            typeParameter.Name = value;
+            Assert.Equal(value ?? string.Empty, typeParameter.Name);
+        }
 
-               [Fact]
-               public void Constraints_AddMultiple_ReturnsExpected()
-               {
-                       var typeParameter = new CodeTypeParameter();
+        [Fact]
+        public void Constraints_AddMultiple_ReturnsExpected()
+        {
+            var typeParameter = new CodeTypeParameter();
 
-                       CodeTypeReference type1 = new CodeTypeReference(typeof(int));
-                       typeParameter.Constraints.Add(type1);
-                       Assert.Equal(new CodeTypeReference[] { type1 }, typeParameter.Constraints.Cast<CodeTypeReference>());
+            CodeTypeReference type1 = new CodeTypeReference(typeof(int));
+            typeParameter.Constraints.Add(type1);
+            Assert.Equal(new CodeTypeReference[] { type1 }, typeParameter.Constraints.Cast<CodeTypeReference>());
 
-                       CodeTypeReference type2 = new CodeTypeReference(typeof(int));
-                       typeParameter.Constraints.Add(type2);
-                       Assert.Equal(new CodeTypeReference[] { type1, type2 }, typeParameter.Constraints.Cast<CodeTypeReference>());
-               }
+            CodeTypeReference type2 = new CodeTypeReference(typeof(int));
+            typeParameter.Constraints.Add(type2);
+            Assert.Equal(new CodeTypeReference[] { type1, type2 }, typeParameter.Constraints.Cast<CodeTypeReference>());
+        }
 
-               [Fact]
-               public void CustomAttributes_AddMultiple_ReturnsExpected()
-               {
-                       var typeParameter = new CodeTypeParameter();
+        [Fact]
+        public void CustomAttributes_AddMultiple_ReturnsExpected()
+        {
+            var typeParameter = new CodeTypeParameter();
 
-                       CodeAttributeDeclaration attribute1 = new CodeAttributeDeclaration("Name1");
-                       typeParameter.CustomAttributes.Add(attribute1);
-                       Assert.Equal(new CodeAttributeDeclaration[] { attribute1 }, typeParameter.CustomAttributes.Cast<CodeAttributeDeclaration>());
+            CodeAttributeDeclaration attribute1 = new CodeAttributeDeclaration("Name1");
+            typeParameter.CustomAttributes.Add(attribute1);
+            Assert.Equal(new CodeAttributeDeclaration[] { attribute1 }, typeParameter.CustomAttributes.Cast<CodeAttributeDeclaration>());
 
-                       CodeAttributeDeclaration attribute2 = new CodeAttributeDeclaration("Name2");
-                       typeParameter.CustomAttributes.Add(attribute2);
-                       Assert.Equal(new CodeAttributeDeclaration[] { attribute1, attribute2 }, typeParameter.CustomAttributes.Cast<CodeAttributeDeclaration>());
-               }
+            CodeAttributeDeclaration attribute2 = new CodeAttributeDeclaration("Name2");
+            typeParameter.CustomAttributes.Add(attribute2);
+            Assert.Equal(new CodeAttributeDeclaration[] { attribute1, attribute2 }, typeParameter.CustomAttributes.Cast<CodeAttributeDeclaration>());
+        }
 
-               [Theory]
-               [InlineData(true)]
-               [InlineData(false)]
-               public void HasConstructorConstraint_Get_Set_ReturnsExpected(bool value)
-               {
-                       var typeParameter = new CodeTypeParameter();
-                       typeParameter.HasConstructorConstraint = value;
-                       Assert.Equal(value, typeParameter.HasConstructorConstraint);
-               }
-       }
+        [Theory]
+        [InlineData(true)]
+        [InlineData(false)]
+        public void HasConstructorConstraint_Get_Set_ReturnsExpected(bool value)
+        {
+            var typeParameter = new CodeTypeParameter();
+            typeParameter.HasConstructorConstraint = value;
+            Assert.Equal(value, typeParameter.HasConstructorConstraint);
+        }
+    }
 }
index b81b2a1..73f4750 100644 (file)
@@ -7,66 +7,66 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeTypeReferenceExpressionTests : CodeObjectTestBase<CodeTypeReferenceExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var typeReference = new CodeTypeReferenceExpression();
-                       Assert.Equal(typeof(void).FullName, typeReference.Type.BaseType);
-               }
+    public class CodeTypeReferenceExpressionTests : CodeObjectTestBase<CodeTypeReferenceExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var typeReference = new CodeTypeReferenceExpression();
+            Assert.Equal(typeof(void).FullName, typeReference.Type.BaseType);
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Ctor_CodeTypeReference_CodeExpression(CodeTypeReference type)
-               {
-                       var typeReference = new CodeTypeReferenceExpression(type);
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, typeReference.Type.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Ctor_CodeTypeReference_CodeExpression(CodeTypeReference type)
+        {
+            var typeReference = new CodeTypeReferenceExpression(type);
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, typeReference.Type.BaseType);
+        }
 
-               public static IEnumerable<object[]> Ctor_TypeString_TestData()
-               {
-                       yield return new object[] { null, "System.Void" };
-                       yield return new object[] { "", "System.Void" };
-                       yield return new object[] { "Int32", "Int32" };
-               }
+        public static IEnumerable<object[]> Ctor_TypeString_TestData()
+        {
+            yield return new object[] { null, "System.Void" };
+            yield return new object[] { "", "System.Void" };
+            yield return new object[] { "Int32", "Int32" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_TypeString_TestData))]
-               public void Ctor_String_CodeExpression(string type, string expectedBaseType)
-               {
-                       var typeReference = new CodeTypeReferenceExpression(type);
-                       Assert.Equal(expectedBaseType, typeReference.Type.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_TypeString_TestData))]
+        public void Ctor_String_CodeExpression(string type, string expectedBaseType)
+        {
+            var typeReference = new CodeTypeReferenceExpression(type);
+            Assert.Equal(expectedBaseType, typeReference.Type.BaseType);
+        }
 
-               public static IEnumerable<object[]> Ctor_Type_TestData()
-               {
-                       yield return new object[] { typeof(int), "System.Int32" };
-                       yield return new object[] { typeof(List<>), "System.Collections.Generic.List`1" };
-                       yield return new object[] { typeof(void), "System.Void" };
-               }
+        public static IEnumerable<object[]> Ctor_Type_TestData()
+        {
+            yield return new object[] { typeof(int), "System.Int32" };
+            yield return new object[] { typeof(List<>), "System.Collections.Generic.List`1" };
+            yield return new object[] { typeof(void), "System.Void" };
+        }
 
-               [Theory]
-               [MemberData(nameof(Ctor_Type_TestData))]
-               public void Ctor_Type_CodeExpression(Type type, string expectedBaseType)
-               {
-                       var typeReference = new CodeTypeReferenceExpression(type);
-                       Assert.Equal(expectedBaseType, typeReference.Type.BaseType);
-               }
+        [Theory]
+        [MemberData(nameof(Ctor_Type_TestData))]
+        public void Ctor_Type_CodeExpression(Type type, string expectedBaseType)
+        {
+            var typeReference = new CodeTypeReferenceExpression(type);
+            Assert.Equal(expectedBaseType, typeReference.Type.BaseType);
+        }
 
-               [Fact]
-               public void Ctor_NullType_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeTypeReferenceExpression((Type)null));
-               }
+        [Fact]
+        public void Ctor_NullType_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeTypeReferenceExpression((Type)null));
+        }
 
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Type_Set_Get_ReturnsExpected(CodeTypeReference value)
-               {
-                       var typeReference = new CodeTypeReferenceExpression();
-                       typeReference.Type = value;
-                       Assert.Equal((value ?? new CodeTypeReference("")).BaseType, typeReference.Type.BaseType);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Type_Set_Get_ReturnsExpected(CodeTypeReference value)
+        {
+            var typeReference = new CodeTypeReferenceExpression();
+            typeReference.Type = value;
+            Assert.Equal((value ?? new CodeTypeReference("")).BaseType, typeReference.Type.BaseType);
+        }
+    }
 }
index 8ae1dd5..cc26c8b 100644 (file)
@@ -8,261 +8,261 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeTypeReferenceTests : CodeObjectTestBase<CodeTypeReference>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var type = new CodeTypeReference();
-                       Assert.Null(type.ArrayElementType);
-                       Assert.Equal(0, type.ArrayRank);
-                       Assert.Empty(type.BaseType);
-                       Assert.Equal((CodeTypeReferenceOptions)0, type.Options);
-                       Assert.Empty(type.TypeArguments);
-               }
-
-               public static IEnumerable<object[]> Ctor_Type_TestData()
-               {
-                       yield return new object[] { typeof(int), typeof(int).FullName };
-                       yield return new object[] { typeof(int[]), typeof(int).FullName };
-                       yield return new object[] { typeof(int[,]), typeof(int).FullName };
-                       yield return new object[] { typeof(int).MakeByRefType(), typeof(int).MakeByRefType().FullName };
-                       yield return new object[] { typeof(int).MakePointerType(), typeof(int).MakePointerType().FullName };
-                       yield return new object[] { typeof(List<int>), typeof(List<>).FullName };
-                       yield return new object[] { typeof(List<>), typeof(List<>).FullName };
-                       yield return new object[] { typeof(List<>).GetGenericArguments()[0], "T" };
-                       yield return new object[] { typeof(void), typeof(void).FullName };
-                       yield return new object[] { typeof(NestedClass), typeof(NestedClass).FullName };
-                       yield return new object[] { typeof(ClassWithoutNamespace), typeof(ClassWithoutNamespace).FullName };
-                       yield return new object[] { typeof(Nullable), typeof(Nullable).FullName };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_Type_TestData))]
-               public void Ctor_Type(Type type, string expectedBaseType)
-               {
-                       var typeReference = new CodeTypeReference(type);
-                       string expectedArrayElementType = type.IsArray ? type.GetElementType().FullName : null;
-                       int expectedArrayRank = type.IsArray ? type.GetArrayRank() : 0;
-                       string[] expectedTypeArguments = type.GenericTypeArguments.Select(arg => arg.IsGenericType ? arg.GetGenericTypeDefinition().FullName : arg.FullName).ToArray();
-                       VerifyCodeTypeReference(typeReference, expectedBaseType, expectedArrayElementType, expectedArrayRank, expectedTypeArguments);
-               }
-
-               [Theory]
-               [InlineData(typeof(int), (CodeTypeReferenceOptions)(-1))]
-               [InlineData(typeof(object), (CodeTypeReferenceOptions)0)]
-               [InlineData(typeof(void), CodeTypeReferenceOptions.GenericTypeParameter)]
-               [InlineData(typeof(string), CodeTypeReferenceOptions.GenericTypeParameter + 1)]
-               public void Ctor_Type_CodeReferenceTypeOptions_TestData(Type type, CodeTypeReferenceOptions options)
-               {
-                       var typeReference = new CodeTypeReference(type, options);
-                       Assert.Equal(type.FullName, typeReference.BaseType);
-                       Assert.Equal(options, typeReference.Options);
-               }
-
-               [Fact]
-               public void Ctor_NullType_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeTypeReference((Type)null));
-                       AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeTypeReference((Type)null, CodeTypeReferenceOptions.GenericTypeParameter));
-               }
-
-               public static IEnumerable<object[]> Ctor_String_TestData()
-               {
-                       // Basic
-                       yield return new object[] { "System.Int32", typeof(int).FullName, null, 0, new string[0] };
-                       yield return new object[] { "System.Int32*", typeof(int).MakePointerType().FullName, null, 0, new string[0] };
-                       yield return new object[] { "System.Int32&", typeof(int).MakeByRefType().FullName, null, 0, new string[0] };
-                       yield return new object[] { "NoSuchType", "NoSuchType", null, 0, new string[0] };
-
-                       // Arrays
-                       yield return new object[] { "System.Int32[]", typeof(int).FullName, typeof(int).FullName, 1, new string[0] };
-                       yield return new object[] { "System.Int32[,]", typeof(int).FullName, typeof(int).FullName, 2, new string[0] };
-                       yield return new object[] { "System.Int32[][]", typeof(int).FullName, typeof(int).FullName, 1, new string[0] };
-
-                       // Generic
-                       yield return new object[] { "System.Collections.Generic.Dictionary`2[[System.String, mscorlib, Version = 2.0.0.0, Culture = neutral, PublicKeyToken = b77a5c561934e089], [System.Collections.Generic.List`1[[System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]], mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]]", typeof(Dictionary<,>).FullName, null, 0, new string[] { "System.String", "System.Collections.Generic.List`1" } };
-                       yield return new object[] { "[System.Collections.Generic.List[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral,PublicKeyToken=b77a5c561934e089]], mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]", "System.Collections.Generic.List", null, 0, new string[] { "System.String" } };
-
-                       // Empty
-                       yield return new object[] { null, typeof(void).FullName, null, 0, new string[0] };
-                       yield return new object[] { "", typeof(void).FullName, null, 0, new string[0] };
-                       yield return new object[] { " \r \t \n ", " \r \t \n ", null, 0, new string[0] };
-
-                       // Invalid assembly qualified name
-                       yield return new object[] { "[]", "[]", null, 0, new string[0] };
-                       yield return new object[] { "[]]", "[]]", null, 0, new string[0] };
-                       yield return new object[] { "[[]", "[", "[", 1, new string[0] };
-                       yield return new object[] { "[[]]", "[[]]", null, 0, new string[0] };
-                       yield return new object[] { "]", "]", null, 0, new string[0] };
-                       yield return new object[] { "[", "[", null, 0, new string[0] };
-                       yield return new object[] { "[,,,,]", "", null, 0, new string[0] };
-                       yield return new object[] { "[a,b,c,d,e]", "a", null, 0, new string[0] };
-                       yield return new object[] { "[System.Int32,b,c,d,e]", typeof(int).FullName, null, 0, new string[0] };
-
-                       // Invalid generic
-                       yield return new object[] { "System.Collections.Generic.Dictionary`2", "System.Collections.Generic.Dictionary`2", null, 0, new string[0] };
-                       yield return new object[] { "System.Collections.Generic.Dictionary`2[System.String]", "System.Collections.Generic.Dictionary`2", null, 0, new string[] { "System.String" } };
-                       yield return new object[] { "System.Collections.Generic.Dictionary`2[System.String,", "System.Collections.Generic.Dictionary`2[System.String,", null, 0, new string[0] };
-                       yield return new object[] { "System.Collections.Generic.Dictionary`2[System.String,]", "System.Collections.Generic.Dictionary`2", null, 0, new string[] { "System.String" } };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_String_TestData))]
-               public void Ctor_String(string type, string expectedBaseType, string expectedArrayElementType, int expectedArrayRank, string[] expectedTypeArguments)
-               {
-                       var typeReference = new CodeTypeReference(type);
-                       VerifyCodeTypeReference(typeReference, expectedBaseType, expectedArrayElementType, expectedArrayRank, expectedTypeArguments);
-               }
-
-               [Theory]
-               [InlineData("System.Int32", (CodeTypeReferenceOptions)(-1))]
-               [InlineData("System.Object", (CodeTypeReferenceOptions)0)]
-               [InlineData("System.Void", CodeTypeReferenceOptions.GenericTypeParameter)]
-               [InlineData("System.String", CodeTypeReferenceOptions.GenericTypeParameter + 1)]
-               public void Ctor_String_CodeReferenceTypeOptions(string type, CodeTypeReferenceOptions options)
-               {
-                       var typeReference = new CodeTypeReference(type, options);
-                       Assert.Equal(type, typeReference.BaseType);
-                       Assert.Equal(options, typeReference.Options);
-               }
-
-               public static IEnumerable<object[]> Ctor_CodeTypeReference_Int_TestData()
-               {
-                       yield return new object[] { new CodeTypeReference(typeof(int)), -1, "" };
-                       yield return new object[] { new CodeTypeReference(typeof(void)), 0, "" };
-                       yield return new object[] { new CodeTypeReference(typeof(string)), 1, "System.String" };
-                       yield return new object[] { null, 1, "" };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_CodeTypeReference_Int_TestData))]
-               public void Ctor_CodeTypeReference_Int(CodeTypeReference type, int rank, string expectedBaseType)
-               {
-                       var typeReference = new CodeTypeReference(type, rank);
-                       Assert.Equal(expectedBaseType, typeReference.BaseType);
-                       Assert.Equal(type?.BaseType, typeReference.ArrayElementType?.BaseType);
-                       Assert.Equal(rank, typeReference.ArrayRank);
-               }
-
-               [Theory]
-               [InlineData("System.Int32", -1, "")]
-               [InlineData("System.Void", 0, "")]
-               [InlineData("System.String", 1, "System.String")]
-               public void Ctor_String_Int(string type, int rank, string expectedBaseType)
-               {
-                       var typeReference = new CodeTypeReference(type, rank);
-                       Assert.Equal(expectedBaseType, typeReference.BaseType);
-                       Assert.Equal(type, typeReference.ArrayElementType.BaseType);
-                       Assert.Equal(rank, typeReference.ArrayRank);
-               }
-
-               public static IEnumerable<object[]> Ctor_String_ParamsCodeTypeReference_TestData()
-               {
-                       yield return new object[] { "System.String", null, "System.String" };
-                       yield return new object[] { "System.Void", new CodeTypeReference[0], "System.Void" };
-                       yield return new object[] { "System.Int32", new CodeTypeReference[] { new CodeTypeReference("System.String") }, "System.Int32`1" };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_String_ParamsCodeTypeReference_TestData))]
-               public void Ctor_String_ParamsCodeTypeReference(string name, CodeTypeReference[] typeArguments, string expectedBaseType)
-               {
-                       var typeReference = new CodeTypeReference(name, typeArguments);
-                       Assert.Equal(expectedBaseType, typeReference.BaseType);
-                       Assert.Equal(typeArguments ?? new CodeTypeReference[0], typeReference.TypeArguments.Cast<CodeTypeReference>());
-               }
-
-               [Fact]
-               public void Ctor_NullObjectInTypeArguments_ThrowsArgumentNullException()
-               {
-                       CodeTypeReference[] typeArguments = new CodeTypeReference[] { null };
-                       AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTypeReference("System.Int32", typeArguments));
-               }
-
-               public static IEnumerable<object[]> Ctor_CodeTypeParameter_TestData()
-               {
-                       yield return new object[] { null };
-                       yield return new object[] { new CodeTypeParameter() };
-                       yield return new object[] { new CodeTypeParameter("T") };
-                       yield return new object[] { new CodeTypeParameter("System.Int32") };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_CodeTypeParameter_TestData))]
-               public void Ctor_CodeTypeParameter(CodeTypeParameter parameter)
-               {
-                       var typeReference = new CodeTypeReference(parameter);
-                       Assert.Equal(string.IsNullOrEmpty(parameter?.Name) ? "System.Void" : parameter.Name, typeReference.BaseType);
-                       Assert.Equal(CodeTypeReferenceOptions.GenericTypeParameter, typeReference.Options);
-               }
-
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void ArrayElementType_Set_Get_ReturnsExpected(CodeTypeReference value)
-               {
-                       var codeTypeReference = new CodeTypeReference();
-                       codeTypeReference.ArrayElementType = value;
-                       Assert.Equal(value, codeTypeReference.ArrayElementType);
-               }
-
-               [Theory]
-               [InlineData(-1)]
-               [InlineData(0)]
-               [InlineData(1)]
-               public void ArrayRank_Set_Get_ReturnsExpected(int value)
-               {
-                       var codeTypeReference = new CodeTypeReference();
-                       codeTypeReference.ArrayRank = value;
-                       Assert.Equal(value, codeTypeReference.ArrayRank);
-               }
-
-               [Theory]
-               [InlineData(null, "System.Void")]
-               [InlineData("", "System.Void")]
-               [InlineData("System.Int32", "System.Int32")]
-               public void BaseType_Set_Get_ReturnsExpected(string value, string expected)
-               {
-                       var codeTypeReference = new CodeTypeReference();
-                       codeTypeReference.BaseType = value;
-                       Assert.Equal(expected, codeTypeReference.BaseType);
-               }
-
-               [Fact]
-               public void TypeArguments_AddMultiple_ReturnsExpected()
-               {
-                       var codeTypeReference = new CodeTypeReference();
-
-                       CodeTypeReference type1 = new CodeTypeReference(typeof(int));
-                       codeTypeReference.TypeArguments.Add(type1);
-                       Assert.Equal(new CodeTypeReference[] { type1 }, codeTypeReference.TypeArguments.Cast<CodeTypeReference>());
-
-                       CodeTypeReference type2 = new CodeTypeReference(typeof(char));
-                       codeTypeReference.TypeArguments.Add(type2);
-                       Assert.Equal(new CodeTypeReference[] { type1, type2 }, codeTypeReference.TypeArguments.Cast<CodeTypeReference>());
-               }
-
-               private static void VerifyCodeTypeReference(CodeTypeReference typeReference, string expectedBaseType, string expectedArrayElementType, int expectedArrayRank, string[] expectedTypeArguments)
-               {
-                       Assert.Equal(expectedBaseType, typeReference.BaseType);
-
-                       Assert.Equal(expectedArrayElementType, typeReference.ArrayElementType?.BaseType);
-
-                       Assert.Equal(expectedArrayRank, typeReference.ArrayRank);
-
-                       Assert.Equal((CodeTypeReferenceOptions)0, typeReference.Options);
-
-                       CodeTypeReference[] actualTypeArguments = typeReference.TypeArguments.Cast<CodeTypeReference>().ToArray();
-                       Assert.Equal(expectedTypeArguments.Length, actualTypeArguments.Length);
-                       for (int i = 0; i < expectedTypeArguments.Length; i++)
-                       {
-                               Assert.Equal(expectedTypeArguments[i], actualTypeArguments[i].BaseType);
-                               Assert.Equal((CodeTypeReferenceOptions)0, actualTypeArguments[i].Options);
-                       }
-               }
-
-               public class NestedClass { }
-       }
+    public class CodeTypeReferenceTests : CodeObjectTestBase<CodeTypeReference>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var type = new CodeTypeReference();
+            Assert.Null(type.ArrayElementType);
+            Assert.Equal(0, type.ArrayRank);
+            Assert.Empty(type.BaseType);
+            Assert.Equal((CodeTypeReferenceOptions)0, type.Options);
+            Assert.Empty(type.TypeArguments);
+        }
+
+        public static IEnumerable<object[]> Ctor_Type_TestData()
+        {
+            yield return new object[] { typeof(int), typeof(int).FullName };
+            yield return new object[] { typeof(int[]), typeof(int).FullName };
+            yield return new object[] { typeof(int[,]), typeof(int).FullName };
+            yield return new object[] { typeof(int).MakeByRefType(), typeof(int).MakeByRefType().FullName };
+            yield return new object[] { typeof(int).MakePointerType(), typeof(int).MakePointerType().FullName };
+            yield return new object[] { typeof(List<int>), typeof(List<>).FullName };
+            yield return new object[] { typeof(List<>), typeof(List<>).FullName };
+            yield return new object[] { typeof(List<>).GetGenericArguments()[0], "T" };
+            yield return new object[] { typeof(void), typeof(void).FullName };
+            yield return new object[] { typeof(NestedClass), typeof(NestedClass).FullName };
+            yield return new object[] { typeof(ClassWithoutNamespace), typeof(ClassWithoutNamespace).FullName };
+            yield return new object[] { typeof(Nullable), typeof(Nullable).FullName };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_Type_TestData))]
+        public void Ctor_Type(Type type, string expectedBaseType)
+        {
+            var typeReference = new CodeTypeReference(type);
+            string expectedArrayElementType = type.IsArray ? type.GetElementType().FullName : null;
+            int expectedArrayRank = type.IsArray ? type.GetArrayRank() : 0;
+            string[] expectedTypeArguments = type.GenericTypeArguments.Select(arg => arg.IsGenericType ? arg.GetGenericTypeDefinition().FullName : arg.FullName).ToArray();
+            VerifyCodeTypeReference(typeReference, expectedBaseType, expectedArrayElementType, expectedArrayRank, expectedTypeArguments);
+        }
+
+        [Theory]
+        [InlineData(typeof(int), (CodeTypeReferenceOptions)(-1))]
+        [InlineData(typeof(object), (CodeTypeReferenceOptions)0)]
+        [InlineData(typeof(void), CodeTypeReferenceOptions.GenericTypeParameter)]
+        [InlineData(typeof(string), CodeTypeReferenceOptions.GenericTypeParameter + 1)]
+        public void Ctor_Type_CodeReferenceTypeOptions_TestData(Type type, CodeTypeReferenceOptions options)
+        {
+            var typeReference = new CodeTypeReference(type, options);
+            Assert.Equal(type.FullName, typeReference.BaseType);
+            Assert.Equal(options, typeReference.Options);
+        }
+
+        [Fact]
+        public void Ctor_NullType_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeTypeReference((Type)null));
+            AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeTypeReference((Type)null, CodeTypeReferenceOptions.GenericTypeParameter));
+        }
+
+        public static IEnumerable<object[]> Ctor_String_TestData()
+        {
+            // Basic
+            yield return new object[] { "System.Int32", typeof(int).FullName, null, 0, new string[0] };
+            yield return new object[] { "System.Int32*", typeof(int).MakePointerType().FullName, null, 0, new string[0] };
+            yield return new object[] { "System.Int32&", typeof(int).MakeByRefType().FullName, null, 0, new string[0] };
+            yield return new object[] { "NoSuchType", "NoSuchType", null, 0, new string[0] };
+
+            // Arrays
+            yield return new object[] { "System.Int32[]", typeof(int).FullName, typeof(int).FullName, 1, new string[0] };
+            yield return new object[] { "System.Int32[,]", typeof(int).FullName, typeof(int).FullName, 2, new string[0] };
+            yield return new object[] { "System.Int32[][]", typeof(int).FullName, typeof(int).FullName, 1, new string[0] };
+
+            // Generic
+            yield return new object[] { "System.Collections.Generic.Dictionary`2[[System.String, mscorlib, Version = 2.0.0.0, Culture = neutral, PublicKeyToken = b77a5c561934e089], [System.Collections.Generic.List`1[[System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]], mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]]", typeof(Dictionary<,>).FullName, null, 0, new string[] { "System.String", "System.Collections.Generic.List`1" } };
+            yield return new object[] { "[System.Collections.Generic.List[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral,PublicKeyToken=b77a5c561934e089]], mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]", "System.Collections.Generic.List", null, 0, new string[] { "System.String" } };
+
+            // Empty
+            yield return new object[] { null, typeof(void).FullName, null, 0, new string[0] };
+            yield return new object[] { "", typeof(void).FullName, null, 0, new string[0] };
+            yield return new object[] { " \r \t \n ", " \r \t \n ", null, 0, new string[0] };
+
+            // Invalid assembly qualified name
+            yield return new object[] { "[]", "[]", null, 0, new string[0] };
+            yield return new object[] { "[]]", "[]]", null, 0, new string[0] };
+            yield return new object[] { "[[]", "[", "[", 1, new string[0] };
+            yield return new object[] { "[[]]", "[[]]", null, 0, new string[0] };
+            yield return new object[] { "]", "]", null, 0, new string[0] };
+            yield return new object[] { "[", "[", null, 0, new string[0] };
+            yield return new object[] { "[,,,,]", "", null, 0, new string[0] };
+            yield return new object[] { "[a,b,c,d,e]", "a", null, 0, new string[0] };
+            yield return new object[] { "[System.Int32,b,c,d,e]", typeof(int).FullName, null, 0, new string[0] };
+
+            // Invalid generic
+            yield return new object[] { "System.Collections.Generic.Dictionary`2", "System.Collections.Generic.Dictionary`2", null, 0, new string[0] };
+            yield return new object[] { "System.Collections.Generic.Dictionary`2[System.String]", "System.Collections.Generic.Dictionary`2", null, 0, new string[] { "System.String" } };
+            yield return new object[] { "System.Collections.Generic.Dictionary`2[System.String,", "System.Collections.Generic.Dictionary`2[System.String,", null, 0, new string[0] };
+            yield return new object[] { "System.Collections.Generic.Dictionary`2[System.String,]", "System.Collections.Generic.Dictionary`2", null, 0, new string[] { "System.String" } };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_String_TestData))]
+        public void Ctor_String(string type, string expectedBaseType, string expectedArrayElementType, int expectedArrayRank, string[] expectedTypeArguments)
+        {
+            var typeReference = new CodeTypeReference(type);
+            VerifyCodeTypeReference(typeReference, expectedBaseType, expectedArrayElementType, expectedArrayRank, expectedTypeArguments);
+        }
+
+        [Theory]
+        [InlineData("System.Int32", (CodeTypeReferenceOptions)(-1))]
+        [InlineData("System.Object", (CodeTypeReferenceOptions)0)]
+        [InlineData("System.Void", CodeTypeReferenceOptions.GenericTypeParameter)]
+        [InlineData("System.String", CodeTypeReferenceOptions.GenericTypeParameter + 1)]
+        public void Ctor_String_CodeReferenceTypeOptions(string type, CodeTypeReferenceOptions options)
+        {
+            var typeReference = new CodeTypeReference(type, options);
+            Assert.Equal(type, typeReference.BaseType);
+            Assert.Equal(options, typeReference.Options);
+        }
+
+        public static IEnumerable<object[]> Ctor_CodeTypeReference_Int_TestData()
+        {
+            yield return new object[] { new CodeTypeReference(typeof(int)), -1, "" };
+            yield return new object[] { new CodeTypeReference(typeof(void)), 0, "" };
+            yield return new object[] { new CodeTypeReference(typeof(string)), 1, "System.String" };
+            yield return new object[] { null, 1, "" };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_CodeTypeReference_Int_TestData))]
+        public void Ctor_CodeTypeReference_Int(CodeTypeReference type, int rank, string expectedBaseType)
+        {
+            var typeReference = new CodeTypeReference(type, rank);
+            Assert.Equal(expectedBaseType, typeReference.BaseType);
+            Assert.Equal(type?.BaseType, typeReference.ArrayElementType?.BaseType);
+            Assert.Equal(rank, typeReference.ArrayRank);
+        }
+
+        [Theory]
+        [InlineData("System.Int32", -1, "")]
+        [InlineData("System.Void", 0, "")]
+        [InlineData("System.String", 1, "System.String")]
+        public void Ctor_String_Int(string type, int rank, string expectedBaseType)
+        {
+            var typeReference = new CodeTypeReference(type, rank);
+            Assert.Equal(expectedBaseType, typeReference.BaseType);
+            Assert.Equal(type, typeReference.ArrayElementType.BaseType);
+            Assert.Equal(rank, typeReference.ArrayRank);
+        }
+
+        public static IEnumerable<object[]> Ctor_String_ParamsCodeTypeReference_TestData()
+        {
+            yield return new object[] { "System.String", null, "System.String" };
+            yield return new object[] { "System.Void", new CodeTypeReference[0], "System.Void" };
+            yield return new object[] { "System.Int32", new CodeTypeReference[] { new CodeTypeReference("System.String") }, "System.Int32`1" };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_String_ParamsCodeTypeReference_TestData))]
+        public void Ctor_String_ParamsCodeTypeReference(string name, CodeTypeReference[] typeArguments, string expectedBaseType)
+        {
+            var typeReference = new CodeTypeReference(name, typeArguments);
+            Assert.Equal(expectedBaseType, typeReference.BaseType);
+            Assert.Equal(typeArguments ?? new CodeTypeReference[0], typeReference.TypeArguments.Cast<CodeTypeReference>());
+        }
+
+        [Fact]
+        public void Ctor_NullObjectInTypeArguments_ThrowsArgumentNullException()
+        {
+            CodeTypeReference[] typeArguments = new CodeTypeReference[] { null };
+            AssertExtensions.Throws<ArgumentNullException>("value", () => new CodeTypeReference("System.Int32", typeArguments));
+        }
+
+        public static IEnumerable<object[]> Ctor_CodeTypeParameter_TestData()
+        {
+            yield return new object[] { null };
+            yield return new object[] { new CodeTypeParameter() };
+            yield return new object[] { new CodeTypeParameter("T") };
+            yield return new object[] { new CodeTypeParameter("System.Int32") };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_CodeTypeParameter_TestData))]
+        public void Ctor_CodeTypeParameter(CodeTypeParameter parameter)
+        {
+            var typeReference = new CodeTypeReference(parameter);
+            Assert.Equal(string.IsNullOrEmpty(parameter?.Name) ? "System.Void" : parameter.Name, typeReference.BaseType);
+            Assert.Equal(CodeTypeReferenceOptions.GenericTypeParameter, typeReference.Options);
+        }
+
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void ArrayElementType_Set_Get_ReturnsExpected(CodeTypeReference value)
+        {
+            var codeTypeReference = new CodeTypeReference();
+            codeTypeReference.ArrayElementType = value;
+            Assert.Equal(value, codeTypeReference.ArrayElementType);
+        }
+
+        [Theory]
+        [InlineData(-1)]
+        [InlineData(0)]
+        [InlineData(1)]
+        public void ArrayRank_Set_Get_ReturnsExpected(int value)
+        {
+            var codeTypeReference = new CodeTypeReference();
+            codeTypeReference.ArrayRank = value;
+            Assert.Equal(value, codeTypeReference.ArrayRank);
+        }
+
+        [Theory]
+        [InlineData(null, "System.Void")]
+        [InlineData("", "System.Void")]
+        [InlineData("System.Int32", "System.Int32")]
+        public void BaseType_Set_Get_ReturnsExpected(string value, string expected)
+        {
+            var codeTypeReference = new CodeTypeReference();
+            codeTypeReference.BaseType = value;
+            Assert.Equal(expected, codeTypeReference.BaseType);
+        }
+
+        [Fact]
+        public void TypeArguments_AddMultiple_ReturnsExpected()
+        {
+            var codeTypeReference = new CodeTypeReference();
+
+            CodeTypeReference type1 = new CodeTypeReference(typeof(int));
+            codeTypeReference.TypeArguments.Add(type1);
+            Assert.Equal(new CodeTypeReference[] { type1 }, codeTypeReference.TypeArguments.Cast<CodeTypeReference>());
+
+            CodeTypeReference type2 = new CodeTypeReference(typeof(char));
+            codeTypeReference.TypeArguments.Add(type2);
+            Assert.Equal(new CodeTypeReference[] { type1, type2 }, codeTypeReference.TypeArguments.Cast<CodeTypeReference>());
+        }
+
+        private static void VerifyCodeTypeReference(CodeTypeReference typeReference, string expectedBaseType, string expectedArrayElementType, int expectedArrayRank, string[] expectedTypeArguments)
+        {
+            Assert.Equal(expectedBaseType, typeReference.BaseType);
+
+            Assert.Equal(expectedArrayElementType, typeReference.ArrayElementType?.BaseType);
+
+            Assert.Equal(expectedArrayRank, typeReference.ArrayRank);
+
+            Assert.Equal((CodeTypeReferenceOptions)0, typeReference.Options);
+
+            CodeTypeReference[] actualTypeArguments = typeReference.TypeArguments.Cast<CodeTypeReference>().ToArray();
+            Assert.Equal(expectedTypeArguments.Length, actualTypeArguments.Length);
+            for (int i = 0; i < expectedTypeArguments.Length; i++)
+            {
+                Assert.Equal(expectedTypeArguments[i], actualTypeArguments[i].BaseType);
+                Assert.Equal((CodeTypeReferenceOptions)0, actualTypeArguments[i].Options);
+            }
+        }
+
+        public class NestedClass { }
+    }
 }
 
 public class ClassWithoutNamespace { }
index 4e0bd99..f7c54ed 100644 (file)
@@ -7,151 +7,151 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeVariableDeclarationStatementTests : CodeObjectTestBase<CodeVariableDeclarationStatement>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var variableDeclaration = new CodeVariableDeclarationStatement();
-                       Assert.Null(variableDeclaration.InitExpression);
-                       Assert.Empty(variableDeclaration.Name);
-                       Assert.Equal(typeof(void).FullName, variableDeclaration.Type.BaseType);
-               }
-
-               public static IEnumerable<object[]> Ctor_CodeTypeReference_String_TestData()
-               {
-                       yield return new object[] { null, null };
-                       yield return new object[] { new CodeTypeReference(), "" };
-                       yield return new object[] { new CodeTypeReference(typeof(int)), "Name" };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_CodeTypeReference_String_TestData))]
-               public void Ctor_CodeTypeReference_String(CodeTypeReference type, string name)
-               {
-                       var variableDeclaration = new CodeVariableDeclarationStatement(type, name);
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, variableDeclaration.Type.BaseType);
-                       Assert.Equal(name ?? string.Empty, variableDeclaration.Name);
-                       Assert.Null(variableDeclaration.InitExpression);
-               }
-
-               public static IEnumerable<object[]> Ctor_String_String_TestData()
-               {
-                       yield return new object[] { null, null, "System.Void" };
-                       yield return new object[] { "", "", "System.Void" };
-                       yield return new object[] { "Int32", "Name", "Int32" };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_String_String_TestData))]
-               public void Ctor_String_String(string type, string name, string expectedBaseType)
-               {
-                       var variableDeclaration = new CodeVariableDeclarationStatement(type, name);
-                       Assert.Equal(expectedBaseType, variableDeclaration.Type.BaseType);
-                       Assert.Equal(name ?? string.Empty, variableDeclaration.Name);
-                       Assert.Null(variableDeclaration.InitExpression);
-               }
-
-               public static IEnumerable<object[]> Ctor_Type_String_TestData()
-               {
-                       yield return new object[] { typeof(int), null, "System.Int32" };
-                       yield return new object[] { typeof(List<>), "", "System.Collections.Generic.List`1" };
-                       yield return new object[] { typeof(void), "Name", "System.Void" };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_Type_String_TestData))]
-               public void Ctor_Type_String(Type type, string name, string expectedBaseType)
-               {
-                       var variableDeclaration = new CodeVariableDeclarationStatement(type, name);
-                       Assert.Equal(expectedBaseType, variableDeclaration.Type.BaseType);
-                       Assert.Equal(name ?? string.Empty, variableDeclaration.Name);
-                       Assert.Null(variableDeclaration.InitExpression);
-               }
-
-               public static IEnumerable<object[]> Ctor_CodeTypeReference_String_CodeExpression_TestData()
-               {
-                       yield return new object[] { null, null, null };
-                       yield return new object[] { new CodeTypeReference(), "", new CodeExpression() };
-                       yield return new object[] { new CodeTypeReference(typeof(int)), "Name", new CodePrimitiveExpression("Value") };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_CodeTypeReference_String_CodeExpression_TestData))]
-               public void Ctor_CodeTypeReference_String_CodeExpression(CodeTypeReference type, string name, CodeExpression initExpression)
-               {
-                       var variableDeclaration = new CodeVariableDeclarationStatement(type, name, initExpression);
-                       Assert.Equal((type ?? new CodeTypeReference("")).BaseType, variableDeclaration.Type.BaseType);
-                       Assert.Equal(name ?? string.Empty, variableDeclaration.Name);
-                       Assert.Equal(initExpression, variableDeclaration.InitExpression);
-               }
-
-               public static IEnumerable<object[]> Ctor_String_String_CodeExpression_TestData()
-               {
-                       yield return new object[] { null, null, null, "System.Void" };
-                       yield return new object[] { "", "", new CodeExpression(), "System.Void" };
-                       yield return new object[] { "Int32", "Name", new CodePrimitiveExpression("Value"), "Int32" };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_String_String_CodeExpression_TestData))]
-               public void Ctor_String_String_CodeExpression(string type, string name, CodeExpression initExpression, string expectedBaseType)
-               {
-                       var variableDeclaration = new CodeVariableDeclarationStatement(type, name, initExpression);
-                       Assert.Equal(expectedBaseType, variableDeclaration.Type.BaseType);
-                       Assert.Equal(name ?? string.Empty, variableDeclaration.Name);
-                       Assert.Equal(initExpression, variableDeclaration.InitExpression);
-               }
-
-               public static IEnumerable<object[]> Ctor_Type_String_CodeExpression_TestData()
-               {
-                       yield return new object[] { typeof(int), null, null, "System.Int32" };
-                       yield return new object[] { typeof(List<>), "", new CodeExpression(), "System.Collections.Generic.List`1" };
-                       yield return new object[] { typeof(void), "Name", new CodePrimitiveExpression("Value"), "System.Void" };
-               }
-
-               [Theory]
-               [MemberData(nameof(Ctor_Type_String_CodeExpression_TestData))]
-               public void Ctor_Type_String_CodeExpression(Type type, string name, CodeExpression initExpression, string expectedBaseType)
-               {
-                       var variableDeclaration = new CodeVariableDeclarationStatement(type, name, initExpression);
-                       Assert.Equal(expectedBaseType, variableDeclaration.Type.BaseType);
-                       Assert.Equal(name ?? string.Empty, variableDeclaration.Name);
-                       Assert.Equal(initExpression, variableDeclaration.InitExpression);
-               }
-
-               [Fact]
-               public void Ctor_NullType_ThrowsArgumentNullException()
-               {
-                       AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeVariableDeclarationStatement((Type)null, "Name"));
-                       AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeVariableDeclarationStatement((Type)null, "Name", new CodePrimitiveExpression("Value")));
-               }
-
-               [Theory]
-               [MemberData(nameof(CodeExpression_TestData))]
-               public void InitExpression_Set_Get_ReturnsExpected(CodeExpression value)
-               {
-                       var variableDeclaration = new CodeVariableDeclarationStatement();
-                       variableDeclaration.InitExpression = value;
-                       Assert.Equal(value, variableDeclaration.InitExpression);
-               }
-
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Name_Set_Get_ReturnsExpected(string value)
-               {
-                       var variableDeclaration = new CodeVariableDeclarationStatement();
-                       variableDeclaration.Name = value;
-                       Assert.Equal(value ?? string.Empty, variableDeclaration.Name);
-               }
-
-               [Theory]
-               [MemberData(nameof(CodeTypeReference_TestData))]
-               public void Type_Set_Get_ReturnsExpected(CodeTypeReference value)
-               {
-                       var variableDeclaration = new CodeVariableDeclarationStatement();
-                       variableDeclaration.Type = value;
-                       Assert.Equal((value ?? new CodeTypeReference("")).BaseType, variableDeclaration.Type.BaseType);
-               }
-       }
+    public class CodeVariableDeclarationStatementTests : CodeObjectTestBase<CodeVariableDeclarationStatement>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var variableDeclaration = new CodeVariableDeclarationStatement();
+            Assert.Null(variableDeclaration.InitExpression);
+            Assert.Empty(variableDeclaration.Name);
+            Assert.Equal(typeof(void).FullName, variableDeclaration.Type.BaseType);
+        }
+
+        public static IEnumerable<object[]> Ctor_CodeTypeReference_String_TestData()
+        {
+            yield return new object[] { null, null };
+            yield return new object[] { new CodeTypeReference(), "" };
+            yield return new object[] { new CodeTypeReference(typeof(int)), "Name" };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_CodeTypeReference_String_TestData))]
+        public void Ctor_CodeTypeReference_String(CodeTypeReference type, string name)
+        {
+            var variableDeclaration = new CodeVariableDeclarationStatement(type, name);
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, variableDeclaration.Type.BaseType);
+            Assert.Equal(name ?? string.Empty, variableDeclaration.Name);
+            Assert.Null(variableDeclaration.InitExpression);
+        }
+
+        public static IEnumerable<object[]> Ctor_String_String_TestData()
+        {
+            yield return new object[] { null, null, "System.Void" };
+            yield return new object[] { "", "", "System.Void" };
+            yield return new object[] { "Int32", "Name", "Int32" };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_String_String_TestData))]
+        public void Ctor_String_String(string type, string name, string expectedBaseType)
+        {
+            var variableDeclaration = new CodeVariableDeclarationStatement(type, name);
+            Assert.Equal(expectedBaseType, variableDeclaration.Type.BaseType);
+            Assert.Equal(name ?? string.Empty, variableDeclaration.Name);
+            Assert.Null(variableDeclaration.InitExpression);
+        }
+
+        public static IEnumerable<object[]> Ctor_Type_String_TestData()
+        {
+            yield return new object[] { typeof(int), null, "System.Int32" };
+            yield return new object[] { typeof(List<>), "", "System.Collections.Generic.List`1" };
+            yield return new object[] { typeof(void), "Name", "System.Void" };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_Type_String_TestData))]
+        public void Ctor_Type_String(Type type, string name, string expectedBaseType)
+        {
+            var variableDeclaration = new CodeVariableDeclarationStatement(type, name);
+            Assert.Equal(expectedBaseType, variableDeclaration.Type.BaseType);
+            Assert.Equal(name ?? string.Empty, variableDeclaration.Name);
+            Assert.Null(variableDeclaration.InitExpression);
+        }
+
+        public static IEnumerable<object[]> Ctor_CodeTypeReference_String_CodeExpression_TestData()
+        {
+            yield return new object[] { null, null, null };
+            yield return new object[] { new CodeTypeReference(), "", new CodeExpression() };
+            yield return new object[] { new CodeTypeReference(typeof(int)), "Name", new CodePrimitiveExpression("Value") };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_CodeTypeReference_String_CodeExpression_TestData))]
+        public void Ctor_CodeTypeReference_String_CodeExpression(CodeTypeReference type, string name, CodeExpression initExpression)
+        {
+            var variableDeclaration = new CodeVariableDeclarationStatement(type, name, initExpression);
+            Assert.Equal((type ?? new CodeTypeReference("")).BaseType, variableDeclaration.Type.BaseType);
+            Assert.Equal(name ?? string.Empty, variableDeclaration.Name);
+            Assert.Equal(initExpression, variableDeclaration.InitExpression);
+        }
+
+        public static IEnumerable<object[]> Ctor_String_String_CodeExpression_TestData()
+        {
+            yield return new object[] { null, null, null, "System.Void" };
+            yield return new object[] { "", "", new CodeExpression(), "System.Void" };
+            yield return new object[] { "Int32", "Name", new CodePrimitiveExpression("Value"), "Int32" };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_String_String_CodeExpression_TestData))]
+        public void Ctor_String_String_CodeExpression(string type, string name, CodeExpression initExpression, string expectedBaseType)
+        {
+            var variableDeclaration = new CodeVariableDeclarationStatement(type, name, initExpression);
+            Assert.Equal(expectedBaseType, variableDeclaration.Type.BaseType);
+            Assert.Equal(name ?? string.Empty, variableDeclaration.Name);
+            Assert.Equal(initExpression, variableDeclaration.InitExpression);
+        }
+
+        public static IEnumerable<object[]> Ctor_Type_String_CodeExpression_TestData()
+        {
+            yield return new object[] { typeof(int), null, null, "System.Int32" };
+            yield return new object[] { typeof(List<>), "", new CodeExpression(), "System.Collections.Generic.List`1" };
+            yield return new object[] { typeof(void), "Name", new CodePrimitiveExpression("Value"), "System.Void" };
+        }
+
+        [Theory]
+        [MemberData(nameof(Ctor_Type_String_CodeExpression_TestData))]
+        public void Ctor_Type_String_CodeExpression(Type type, string name, CodeExpression initExpression, string expectedBaseType)
+        {
+            var variableDeclaration = new CodeVariableDeclarationStatement(type, name, initExpression);
+            Assert.Equal(expectedBaseType, variableDeclaration.Type.BaseType);
+            Assert.Equal(name ?? string.Empty, variableDeclaration.Name);
+            Assert.Equal(initExpression, variableDeclaration.InitExpression);
+        }
+
+        [Fact]
+        public void Ctor_NullType_ThrowsArgumentNullException()
+        {
+            AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeVariableDeclarationStatement((Type)null, "Name"));
+            AssertExtensions.Throws<ArgumentNullException>("type", () => new CodeVariableDeclarationStatement((Type)null, "Name", new CodePrimitiveExpression("Value")));
+        }
+
+        [Theory]
+        [MemberData(nameof(CodeExpression_TestData))]
+        public void InitExpression_Set_Get_ReturnsExpected(CodeExpression value)
+        {
+            var variableDeclaration = new CodeVariableDeclarationStatement();
+            variableDeclaration.InitExpression = value;
+            Assert.Equal(value, variableDeclaration.InitExpression);
+        }
+
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Name_Set_Get_ReturnsExpected(string value)
+        {
+            var variableDeclaration = new CodeVariableDeclarationStatement();
+            variableDeclaration.Name = value;
+            Assert.Equal(value ?? string.Empty, variableDeclaration.Name);
+        }
+
+        [Theory]
+        [MemberData(nameof(CodeTypeReference_TestData))]
+        public void Type_Set_Get_ReturnsExpected(CodeTypeReference value)
+        {
+            var variableDeclaration = new CodeVariableDeclarationStatement();
+            variableDeclaration.Type = value;
+            Assert.Equal((value ?? new CodeTypeReference("")).BaseType, variableDeclaration.Type.BaseType);
+        }
+    }
 }
index 9b6ae80..fec6fdf 100644 (file)
@@ -6,30 +6,30 @@ using Xunit;
 
 namespace System.CodeDom.Tests
 {
-       public class CodeVariableReferenceExpressionTests : CodeObjectTestBase<CodeVariableReferenceExpression>
-       {
-               [Fact]
-               public void Ctor_Default()
-               {
-                       var variableReference = new CodeVariableReferenceExpression();
-                       Assert.Empty(variableReference.VariableName);
-               }
+    public class CodeVariableReferenceExpressionTests : CodeObjectTestBase<CodeVariableReferenceExpression>
+    {
+        [Fact]
+        public void Ctor_Default()
+        {
+            var variableReference = new CodeVariableReferenceExpression();
+            Assert.Empty(variableReference.VariableName);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void Ctor_String(string VariableName)
-               {
-                       var variableReference = new CodeVariableReferenceExpression(VariableName);
-                       Assert.Equal(VariableName ?? string.Empty, variableReference.VariableName);
-               }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void Ctor_String(string VariableName)
+        {
+            var variableReference = new CodeVariableReferenceExpression(VariableName);
+            Assert.Equal(VariableName ?? string.Empty, variableReference.VariableName);
+        }
 
-               [Theory]
-               [MemberData(nameof(String_TestData))]
-               public void VariableName_Set_Get_ReturnsExpected(string VariableName)
-               {
-                       var variableReference = new CodeVariableReferenceExpression();
-                       variableReference.VariableName = VariableName;
-                       Assert.Equal(VariableName ?? string.Empty, variableReference.VariableName);
-               }
-       }
+        [Theory]
+        [MemberData(nameof(String_TestData))]
+        public void VariableName_Set_Get_ReturnsExpected(string VariableName)
+        {
+            var variableReference = new CodeVariableReferenceExpression();
+            variableReference.VariableName = VariableName;
+            Assert.Equal(VariableName ?? string.Empty, variableReference.VariableName);
+        }
+    }
 }
index bca24f1..7bff28f 100644 (file)
@@ -324,7 +324,7 @@ nameof(boundedCapacity), boundedCapacity,
         /// cref="System.Collections.Concurrent.BlockingCollection{T}"/> has been disposed.</exception>
         /// <exception cref="System.ArgumentOutOfRangeException"><paramref name="timeout"/> is a negative number
         /// other than -1 milliseconds, which represents an infinite time-out -or- timeout is greater than
-        /// <see cref="System.Int32.MaxValue"/>.</exception>
+        /// <see cref="int.MaxValue"/>.</exception>
         /// <exception cref="System.InvalidOperationException">The underlying collection didn't accept the item.</exception>
         public bool TryAdd(T item, TimeSpan timeout)
         {
@@ -597,7 +597,7 @@ nameof(boundedCapacity), boundedCapacity,
         /// cref="System.Collections.Concurrent.BlockingCollection{T}"/> has been disposed.</exception>
         /// <exception cref="System.ArgumentOutOfRangeException"><paramref name="timeout"/> is a negative number
         /// other than -1 milliseconds, which represents an infinite time-out -or- timeout is greater than
-        /// <see cref="System.Int32.MaxValue"/>.</exception>
+        /// <see cref="int.MaxValue"/>.</exception>
         /// <exception cref="System.InvalidOperationException">The underlying collection was modified
         /// outside of this <see
         /// cref="System.Collections.Concurrent.BlockingCollection{T}"/> instance.</exception>
@@ -888,7 +888,7 @@ nameof(boundedCapacity), boundedCapacity,
         /// cref="System.Collections.Concurrent.BlockingCollection{T}"/> instances has been disposed.</exception>
         /// <exception cref="System.ArgumentOutOfRangeException"><paramref name="timeout"/> is a negative number
         /// other than -1 milliseconds, which represents an infinite time-out -or- timeout is greater than
-        /// <see cref="System.Int32.MaxValue"/>.</exception>
+        /// <see cref="int.MaxValue"/>.</exception>
         /// <exception cref="System.InvalidOperationException">At least one underlying collection didn't accept the item.</exception>
         /// <exception cref="System.ArgumentOutOfRangeException">The count of <paramref name="collections"/> is greater than the maximum size of
         /// 62 for STA and 63 for MTA.</exception>
@@ -1248,7 +1248,7 @@ nameof(boundedCapacity), boundedCapacity,
         /// cref="System.Collections.Concurrent.BlockingCollection{T}"/> instances has been disposed.</exception>
         /// <exception cref="System.ArgumentOutOfRangeException"><paramref name="timeout"/> is a negative number
         /// other than -1 milliseconds, which represents an infinite time-out -or- timeout is greater than
-        /// <see cref="System.Int32.MaxValue"/>.</exception>
+        /// <see cref="int.MaxValue"/>.</exception>
         /// <exception cref="System.InvalidOperationException">At least one of the underlying collections was modified
         /// outside of its <see
         /// cref="System.Collections.Concurrent.BlockingCollection{T}"/> instance.</exception>
index 3c0f366..f611c38 100644 (file)
@@ -304,11 +304,11 @@ namespace System.Collections.Immutable
         }
 
         /// <summary>
-        /// Determines whether the specified <see cref="Object"/> is equal to this instance.
+        /// Determines whether the specified <see cref="object"/> is equal to this instance.
         /// </summary>
-        /// <param name="obj">The <see cref="Object"/> to compare with this instance.</param>
+        /// <param name="obj">The <see cref="object"/> to compare with this instance.</param>
         /// <returns>
-        ///   <c>true</c> if the specified <see cref="Object"/> is equal to this instance; otherwise, <c>false</c>.
+        ///   <c>true</c> if the specified <see cref="object"/> is equal to this instance; otherwise, <c>false</c>.
         /// </returns>
         [Pure]
         public override bool Equals(object obj)
index 2e87332..200425e 100644 (file)
@@ -1146,10 +1146,10 @@ namespace System.Collections.Immutable
         }
 
         /// <summary>
-        /// Gets or sets the <see cref="System.Object"/> at the specified index.
+        /// Gets or sets the <see cref="object"/> at the specified index.
         /// </summary>
         /// <value>
-        /// The <see cref="System.Object"/>.
+        /// The <see cref="object"/>.
         /// </value>
         /// <param name="index">The index.</param>
         /// <returns></returns>
index 0cf4e38..e0c802b 100644 (file)
@@ -262,7 +262,7 @@ namespace System.Collections.Immutable
                 {
                     if (_syncRoot == null)
                     {
-                        Threading.Interlocked.CompareExchange<Object>(ref _syncRoot, new object(), null);
+                        Threading.Interlocked.CompareExchange<object>(ref _syncRoot, new object(), null);
                     }
 
                     return _syncRoot;
index edc4c6a..f65c2ba 100644 (file)
@@ -1052,10 +1052,10 @@ namespace System.Collections.Immutable
             }
 
             /// <summary>
-            /// Gets or sets the <see cref="System.Object"/> at the specified index.
+            /// Gets or sets the <see cref="object"/> at the specified index.
             /// </summary>
             /// <value>
-            /// The <see cref="System.Object"/>.
+            /// The <see cref="object"/>.
             /// </value>
             /// <param name="index">The index.</param>
             /// <returns></returns>
@@ -1100,7 +1100,7 @@ namespace System.Collections.Immutable
                 {
                     if (_syncRoot == null)
                     {
-                        System.Threading.Interlocked.CompareExchange<Object>(ref _syncRoot, new object(), null);
+                        System.Threading.Interlocked.CompareExchange<object>(ref _syncRoot, new object(), null);
                     }
 
                     return _syncRoot;
index 66a455f..f67cb62 100644 (file)
@@ -1080,10 +1080,10 @@ namespace System.Collections.Immutable
         void IList.Remove(object value) => throw new NotSupportedException();
 
         /// <summary>
-        /// Gets or sets the <see cref="System.Object"/> at the specified index.
+        /// Gets or sets the <see cref="object"/> at the specified index.
         /// </summary>
         /// <value>
-        /// The <see cref="System.Object"/>.
+        /// The <see cref="object"/>.
         /// </value>
         /// <param name="index">The index.</param>
         /// <returns>The value at the specified index.</returns>
index e7e7f8c..94fc2c9 100644 (file)
@@ -275,7 +275,7 @@ namespace System.Collections.Immutable
                 {
                     if (_syncRoot == null)
                     {
-                        Threading.Interlocked.CompareExchange<Object>(ref _syncRoot, new object(), null);
+                        Threading.Interlocked.CompareExchange<object>(ref _syncRoot, new object(), null);
                     }
 
                     return _syncRoot;
index 324a5cc..66d3017 100644 (file)
@@ -492,7 +492,7 @@ namespace System.Collections.Immutable
                 {
                     if (_syncRoot == null)
                     {
-                        Threading.Interlocked.CompareExchange<Object>(ref _syncRoot, new object(), null);
+                        Threading.Interlocked.CompareExchange<object>(ref _syncRoot, new object(), null);
                     }
 
                     return _syncRoot;
index 939ed15..34b71a3 100644 (file)
@@ -929,10 +929,10 @@ namespace System.Collections.Immutable
         }
 
         /// <summary>
-        /// Gets or sets the <see cref="System.Object"/> at the specified index.
+        /// Gets or sets the <see cref="object"/> at the specified index.
         /// </summary>
         /// <value>
-        /// The <see cref="System.Object"/>.
+        /// The <see cref="object"/>.
         /// </value>
         /// <param name="index">The index.</param>
         /// <exception cref="System.NotSupportedException"></exception>
index 4c6c5e3..c6fb904 100644 (file)
@@ -257,7 +257,7 @@ namespace System.Collections
         public virtual object[] ToArray()
         {
             if (_size == 0)
-                return Array.Empty<Object>();
+                return Array.Empty<object>();
 
             object[] arr = new object[_size];
             if (_head < _tail)
index aaec350..70ab637 100644 (file)
@@ -87,8 +87,8 @@ namespace System.Collections
         
         private void Init()
         {
-            keys = Array.Empty<Object>();
-            values = Array.Empty<Object>();
+            keys = Array.Empty<object>();
+            values = Array.Empty<object>();
             _size = 0;
             comparer = new Comparer(CultureInfo.CurrentCulture);
         }
@@ -229,8 +229,8 @@ namespace System.Collections
                     {
                         // size can only be zero here.
                         Debug.Assert(_size == 0, "Size is not zero");
-                        keys = Array.Empty<Object>();
-                        values = Array.Empty<Object>();
+                        keys = Array.Empty<object>();
+                        values = Array.Empty<object>();
                     }
                 }
             }
index 1214fd8..a535fd8 100644 (file)
@@ -205,7 +205,7 @@ namespace System.Collections
         public virtual object[] ToArray()
         {
             if (_size == 0)
-                return Array.Empty<Object>();
+                return Array.Empty<object>();
 
             object[] objArray = new object[_size];
             int i = 0;
index 1dde89f..469769e 100644 (file)
@@ -17,8 +17,8 @@ using System.Runtime.Serialization;
 namespace System.Collections.Specialized
 {
     /// <devdoc>
-    /// <para>Provides the <see langword='abstract '/>base class for a sorted collection of associated <see cref='System.String' qualify='true'/> keys
-    ///    and <see cref='System.Object' qualify='true'/> values that can be accessed either with the hash code of
+    /// <para>Provides the <see langword='abstract '/>base class for a sorted collection of associated <see cref='string' qualify='true'/> keys
+    ///    and <see cref='object' qualify='true'/> values that can be accessed either with the hash code of
     ///    the key or with the index.</para>
     /// </devdoc>
     public abstract class NameObjectCollectionBase : ICollection, ISerializable, IDeserializationCallback
@@ -395,7 +395,7 @@ namespace System.Collections.Specialized
         //
 
         /// <devdoc>
-        /// <para>Returns a <see cref='System.String' qualify='true'/> array containing all the keys in the
+        /// <para>Returns a <see cref='string' qualify='true'/> array containing all the keys in the
         /// <see cref='System.Collections.Specialized.NameObjectCollectionBase'/> instance.</para>
         /// </devdoc>
         protected string[] BaseGetAllKeys()
@@ -410,7 +410,7 @@ namespace System.Collections.Specialized
         }
 
         /// <devdoc>
-        /// <para>Returns an <see cref='System.Object' qualify='true'/> array containing all the values in the
+        /// <para>Returns an <see cref='object' qualify='true'/> array containing all the values in the
         /// <see cref='System.Collections.Specialized.NameObjectCollectionBase'/> instance.</para>
         /// </devdoc>
         protected object[] BaseGetAllValues()
@@ -541,7 +541,7 @@ namespace System.Collections.Specialized
         //
 
         /// <devdoc>
-        /// <para>Represents a collection of the <see cref='System.String' qualify='true'/> keys of a collection.</para>
+        /// <para>Represents a collection of the <see cref='string' qualify='true'/> keys of a collection.</para>
         /// </devdoc>
         public class KeysCollection : ICollection
         {
index 56db4ec..82e1f99 100644 (file)
@@ -14,7 +14,7 @@ using System.Text;
 namespace System.Collections.Specialized
 {
     /// <devdoc>
-    /// <para>Represents a sorted collection of associated <see cref='System.String' qualify='true'/> keys and <see cref='System.String' qualify='true'/> values that
+    /// <para>Represents a sorted collection of associated <see cref='string' qualify='true'/> keys and <see cref='string' qualify='true'/> values that
     ///    can be accessed either with the hash code of the key or with the index.</para>
     /// </devdoc>
     public class NameValueCollection : NameObjectCollectionBase
index 5366479..39705ca 100644 (file)
@@ -248,7 +248,7 @@ namespace System.Collections.Generic
 
             if (_size == 0)
             {
-               result = default!;
+                result = default!;
                 return false;
             }
 
@@ -280,7 +280,7 @@ namespace System.Collections.Generic
         {
             if (_size == 0)
             {
-               result = default!;
+                result = default!;
                 return false;
             }
 
index 6037e81..14666f3 100644 (file)
@@ -236,7 +236,7 @@ namespace System.Collections.Tests
             int iterations = 0;
             int expectedCount = expectedItems.Length;
 
-            //[] Verify non deterministic behavior of current every time it is called before a call to MoveNext() has been made                        
+            //[] Verify non deterministic behavior of current every time it is called before a call to MoveNext() has been made            
             for (int i = 0; i < 3; i++)
             {
                 try
@@ -298,7 +298,7 @@ namespace System.Collections.Tests
             int iterations = 0;
             int expectedCount = expectedItems.Length;
 
-            //[] Verify non deterministic behavior of current every time it is called before a call to MoveNext() has been made                        
+            //[] Verify non deterministic behavior of current every time it is called before a call to MoveNext() has been made            
             for (int i = 0; i < 3; i++)
             {
                 try
index 7768309..059b175 100644 (file)
@@ -68,7 +68,7 @@ namespace System.Collections.Tests
             tempNode1 = linkedList.First;
             tempNode2 = linkedList.Last;
 
-            linkedList.Remove(linkedList.First); //Remove when  VS Whidbey: 234648 is resolved         
+            linkedList.Remove(linkedList.First); //Remove when  VS Whidbey: 234648 is resolved
             linkedList.Remove(linkedList.Last); //Remove when  VS Whidbey: 234648 is resolved
 
             InitialItems_Tests(linkedList, new T[0]);
@@ -93,7 +93,7 @@ namespace System.Collections.Tests
             linkedList.AddLast(headItems[2]);
             tempNode1 = linkedList.First.Next;
 
-            linkedList.Remove(linkedList.First.Next); //Remove when  VS Whidbey: 234648 is resolved            
+            linkedList.Remove(linkedList.First.Next); //Remove when  VS Whidbey: 234648 is resolved
             InitialItems_Tests(linkedList, new T[] { headItems[0], headItems[2] });
             VerifyRemovedNode(linkedList, new T[] { headItems[0], headItems[2] }, tempNode1, headItems[1]);
 
@@ -104,7 +104,7 @@ namespace System.Collections.Tests
             linkedList.AddLast(headItems[2]);
             tempNode1 = linkedList.Last;
 
-            linkedList.Remove(linkedList.Last); //Remove when  VS Whidbey: 234648 is resolved          
+            linkedList.Remove(linkedList.Last); //Remove when  VS Whidbey: 234648 is resolved
             InitialItems_Tests(linkedList, new T[] { headItems[0], headItems[1] });
             VerifyRemovedNode(linkedList, new T[] { headItems[0], headItems[1] }, tempNode1, headItems[2]);
 
@@ -117,9 +117,9 @@ namespace System.Collections.Tests
             tempNode2 = linkedList.First.Next;
             tempNode3 = linkedList.Last;
 
-            linkedList.Remove(linkedList.First.Next.Next); //Remove when  VS Whidbey: 234648 is resolved               
+            linkedList.Remove(linkedList.First.Next.Next); //Remove when  VS Whidbey: 234648 is resolved
             linkedList.Remove(linkedList.First.Next); //Remove when  VS Whidbey: 234648 is resolved
-            linkedList.Remove(linkedList.First); //Remove when  VS Whidbey: 234648 is resolved         
+            linkedList.Remove(linkedList.First); //Remove when  VS Whidbey: 234648 is resolved
 
             InitialItems_Tests(linkedList, new T[0]);
             VerifyRemovedNode(tempNode1, headItems[0]);
@@ -133,7 +133,7 @@ namespace System.Collections.Tests
 
             for (int i = 0; i < arraySize; ++i)
             {
-                linkedList.Remove(linkedList.First); //Remove when  VS Whidbey: 234648 is resolved             
+                linkedList.Remove(linkedList.First); //Remove when  VS Whidbey: 234648 is resolved
                 int startIndex = i + 1;
                 int length = arraySize - i - 1;
                 T[] expectedItems = new T[length];
@@ -148,7 +148,7 @@ namespace System.Collections.Tests
 
             for (int i = arraySize - 1; 0 <= i; --i)
             {
-                linkedList.Remove(linkedList.Last); //Remove when  VS Whidbey: 234648 is resolved              
+                linkedList.Remove(linkedList.Last); //Remove when  VS Whidbey: 234648 is resolved
                 T[] expectedItems = new T[i];
                 Array.Copy(headItems, 0, expectedItems, 0, i);
                 InitialItems_Tests(linkedList, expectedItems);
@@ -159,11 +159,11 @@ namespace System.Collections.Tests
             for (int i = 0; i < arraySize; ++i)
                 linkedList.AddFirst(headItems[i]);
 
-            linkedList.Remove(linkedList.First.Next.Next); //Remove when  VS Whidbey: 234648 is resolved               
-            linkedList.Remove(linkedList.Last.Previous.Previous); //Remove when  VS Whidbey: 234648 is resolved                
-            linkedList.Remove(linkedList.First.Next); //Remove when  VS Whidbey: 234648 is resolved            
+            linkedList.Remove(linkedList.First.Next.Next); //Remove when  VS Whidbey: 234648 is resolved
+            linkedList.Remove(linkedList.Last.Previous.Previous); //Remove when  VS Whidbey: 234648 is resolved
+            linkedList.Remove(linkedList.First.Next); //Remove when  VS Whidbey: 234648 is resolved
             linkedList.Remove(linkedList.Last.Previous);
-            linkedList.Remove(linkedList.First); //Remove when  VS Whidbey: 234648 is resolved         
+            linkedList.Remove(linkedList.First); //Remove when  VS Whidbey: 234648 is resolved
             linkedList.Remove(linkedList.Last); //Remove when  VS Whidbey: 234648 is resolved
 
             //With the above remove we should have removed the first and last 3 items 
@@ -223,11 +223,11 @@ namespace System.Collections.Tests
                 ++index;
             }
 
-            linkedList.Remove(linkedList.First.Next.Next); //Remove when  VS Whidbey: 234648 is resolved               
-            linkedList.Remove(linkedList.Last.Previous.Previous); //Remove when  VS Whidbey: 234648 is resolved                
-            linkedList.Remove(linkedList.First.Next); //Remove when  VS Whidbey: 234648 is resolved            
+            linkedList.Remove(linkedList.First.Next.Next); //Remove when  VS Whidbey: 234648 is resolved
+            linkedList.Remove(linkedList.Last.Previous.Previous); //Remove when  VS Whidbey: 234648 is resolved
+            linkedList.Remove(linkedList.First.Next); //Remove when  VS Whidbey: 234648 is resolved
             linkedList.Remove(linkedList.Last.Previous);
-            linkedList.Remove(linkedList.First); //Remove when  VS Whidbey: 234648 is resolved         
+            linkedList.Remove(linkedList.First); //Remove when  VS Whidbey: 234648 is resolved
             linkedList.Remove(linkedList.Last); //Remove when  VS Whidbey: 234648 is resolved
 
             //[] Verify that the duplicates were removed from the beginning of the collection
@@ -282,4 +282,4 @@ namespace System.Collections.Tests
             InitialItems_Tests(linkedList, items);
         }
     }
-}
\ No newline at end of file
+}
index 6342663..e180455 100644 (file)
@@ -170,7 +170,7 @@ namespace System.Collections.Tests
             int iterations = 0;
             int expectedCount = expectedItems.Length;
 
-            //[] Verify non deterministic behavior of current every time it is called before a call to MoveNext() has been made                        
+            //[] Verify non deterministic behavior of current every time it is called before a call to MoveNext() has been made            
             for (int i = 0; i < 3; i++)
             {
                 try
@@ -232,7 +232,7 @@ namespace System.Collections.Tests
             int iterations = 0;
             int expectedCount = expectedItems.Length;
 
-            //[] Verify non deterministic behavior of current every time it is called before a call to MoveNext() has been made                        
+            //[] Verify non deterministic behavior of current every time it is called before a call to MoveNext() has been made            
             for (int i = 0; i < 3; i++)
             {
                 try
index 97219eb..3f35991 100644 (file)
@@ -73,7 +73,7 @@ namespace System.ComponentModel.DataAnnotations
         ///     Using <see cref="NullDisplayTextResourceType" /> along with <see cref="NullDisplayText" />, allows the <see cref="GetNullDisplayText" />
         ///     method to return localized values.
         /// </summary>
-               public Type NullDisplayTextResourceType
+        public Type NullDisplayTextResourceType
         {
             get => _nullDisplayText.ResourceType;
             set => _nullDisplayText.ResourceType = value;
index 7a74fc5..0fc2779 100644 (file)
@@ -98,7 +98,7 @@ namespace System.ComponentModel.DataAnnotations
         /// <summary>
         ///     Override the string representation of this instance, returning
         ///     the <see cref="ErrorMessage" /> if not <c>null</c>, otherwise
-        ///     the base <see cref="Object.ToString" /> result.
+        ///     the base <see cref="object.ToString" /> result.
         /// </summary>
         /// <remarks>
         ///     If the <see cref="ErrorMessage" /> is empty, it will still qualify
@@ -106,7 +106,7 @@ namespace System.ComponentModel.DataAnnotations
         /// </remarks>
         /// <returns>
         ///     The <see cref="ErrorMessage" /> property value if specified,
-        ///     otherwise, the base <see cref="Object.ToString" /> result.
+        ///     otherwise, the base <see cref="object.ToString" /> result.
         /// </returns>
         public override string ToString() => ErrorMessage ?? base.ToString();
         #endregion Methods
index 5a1b02e..3f043e4 100644 (file)
@@ -224,7 +224,7 @@ namespace System.ComponentModel.Composition
         /// <param name="part">The part.</param>
         /// <param name="contractType">Type of the contract.</param>
         /// <returns>
-        ///    <c>true</c> if the specified part exports the specified contract; otherwise, <c>false</c>.
+        ///    <c>true</c> if the specified part exports the specified contract; otherwise, <c>false</c>.
         /// </returns>
         public static bool Exports(this ComposablePartDefinition part, Type contractType)
         {
@@ -240,7 +240,7 @@ namespace System.ComponentModel.Composition
         /// <typeparam name="T">Type of the contract.</typeparam>
         /// <param name="part">The part.</param>
         /// <returns>
-        ///    <c>true</c> if the specified part exports the specified contract; otherwise, <c>false</c>.
+        ///     <c>true</c> if the specified part exports the specified contract; otherwise, <c>false</c>.
         /// </returns>
         public static bool Exports<T>(this ComposablePartDefinition part)
         {
@@ -255,7 +255,7 @@ namespace System.ComponentModel.Composition
         /// <param name="part">The part.</param>
         /// <param name="contractType">Type of the contract.</param>
         /// <returns>
-        ///    <c>true</c> if the specified part imports the specified contract; otherwise, <c>false</c>.
+        ///     <c>true</c> if the specified part imports the specified contract; otherwise, <c>false</c>.
         /// </returns>
         public static bool Imports(this ComposablePartDefinition part, Type contractType)
         {
@@ -271,7 +271,7 @@ namespace System.ComponentModel.Composition
         /// <param name="part">The part.</param>
         /// <typeparam name="T">Type of the contract.</typeparam>
         /// <returns>
-        ///    <c>true</c> if the specified part imports the specified contract; otherwise, <c>false</c>.
+        ///     <c>true</c> if the specified part imports the specified contract; otherwise, <c>false</c>.
         /// </returns>
         public static bool Imports<T>(this ComposablePartDefinition part)
         {
@@ -287,7 +287,7 @@ namespace System.ComponentModel.Composition
         /// <param name="contractType">Type of the contract.</param>
         /// <param name="importCardinality">The import cardinality.</param>
         /// <returns>
-        ///    <c>true</c> if the specified part imports the specified contract with the given cardinality; otherwise, <c>false</c>.
+        ///     <c>true</c> if the specified part imports the specified contract with the given cardinality; otherwise, <c>false</c>.
         /// </returns>
         public static bool Imports(this ComposablePartDefinition part, Type contractType, ImportCardinality importCardinality)
         {
@@ -304,7 +304,7 @@ namespace System.ComponentModel.Composition
         /// <typeparam name="T">Type of the contract.</typeparam>
         /// <param name="importCardinality">The import cardinality.</param>
         /// <returns>
-        ///    <c>true</c> if the specified part imports the specified contract with the given cardinality; otherwise, <c>false</c>.
+        ///     <c>true</c> if the specified part imports the specified contract with the given cardinality; otherwise, <c>false</c>.
         /// </returns>
         public static bool Imports<T>(this ComposablePartDefinition part, ImportCardinality importCardinality)
         {
index ed24e45..e67667e 100644 (file)
@@ -50,7 +50,7 @@ namespace System.ComponentModel.Composition
         ///     Gets a message that describes the exception.
         /// </summary>
         /// <value>
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="ChangeRejectedException"/>.
         /// </value>
         public override string Message
index 3771f9d..a9e5624 100644 (file)
@@ -27,7 +27,7 @@ namespace System.ComponentModel.Composition
         ///     with the specified error message.
         /// </summary>
         /// <param name="message">
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="CompositionContractMismatchException"/>; or <see langword="null"/> to set
         ///     the <see cref="Exception.Message"/> property to its default value.
         /// </param>
@@ -42,7 +42,7 @@ namespace System.ComponentModel.Composition
         ///     exception.
         /// </summary>
         /// <param name="message">
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="CompositionContractMismatchException"/>; or <see langword="null"/> to set
         ///     the <see cref="Exception.Message"/> property to its default value.
         /// </param>
index 1679519..6f18d6f 100644 (file)
@@ -25,7 +25,7 @@ namespace System.ComponentModel.Composition
         ///     with the specified error message.
         /// </summary>
         /// <param name="message">
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="CompositionError"/>; or <see langword="null"/> to set the 
         ///     <see cref="Description"/> property to an empty string ("").
         /// </param>
@@ -46,7 +46,7 @@ namespace System.ComponentModel.Composition
         ///     <see langword="null"/>.
         /// </param>
         /// <param name="message">
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="CompositionError"/>; or <see langword="null"/> to set the 
         ///     <see cref="Description"/> property to an empty string ("").
         /// </param>
@@ -61,7 +61,7 @@ namespace System.ComponentModel.Composition
         ///     composition error.
         /// </summary>
         /// <param name="message">
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="CompositionError"/>; or <see langword="null"/> to set the 
         ///     <see cref="Description"/> property to an empty string ("").
         /// </param>
@@ -81,7 +81,7 @@ namespace System.ComponentModel.Composition
         ///     is the cause of the composition error.
         /// </summary>
         /// <param name="message">
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="CompositionError"/>; or <see langword="null"/> to set the 
         ///     <see cref="Description"/> property to an empty string ("").
         /// </param>
@@ -125,7 +125,7 @@ namespace System.ComponentModel.Composition
         ///     Gets the message that describes the composition error.
         /// </summary>
         /// <value>
-        ///     A <see cref="String"/> containing a message that describes the
+        ///     A <see cref="string"/> containing a message that describes the
         ///     <see cref="CompositionError"/>.
         /// </value>
         public string Description
@@ -159,7 +159,7 @@ namespace System.ComponentModel.Composition
         ///     Returns a string representation of the composition error.
         /// </summary>
         /// <returns>
-        ///     A <see cref="String"/> containing the <see cref="Description"/> property.
+        ///     A <see cref="string"/> containing the <see cref="Description"/> property.
         /// </returns>
         public override string ToString()
         {
index 2555897..2d5a585 100644 (file)
@@ -37,7 +37,7 @@ namespace System.ComponentModel.Composition
         ///     with the specified error message.
         /// </summary>
         /// <param name="message">
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="CompositionException"/>; or <see langword="null"/> to set
         ///     the <see cref="Exception.Message"/> property to its default value.
         /// </param>
@@ -52,7 +52,7 @@ namespace System.ComponentModel.Composition
         ///     exception.
         /// </summary>
         /// <param name="message">
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="CompositionException"/>; or <see langword="null"/> to set
         ///     the <see cref="Exception.Message"/> property to its default value.
         /// </param>
@@ -113,7 +113,7 @@ namespace System.ComponentModel.Composition
         ///     Gets a message that describes the exception.
         /// </summary>
         /// <value>
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="CompositionException"/>.
         /// </value>
         public override string Message
index 508cf28..9ea1ac6 100644 (file)
@@ -70,7 +70,7 @@ namespace System.ComponentModel.Composition
         ///     type or member marked with this attribute under the specified contract name.
         /// </summary>
         /// <param name="contractName">
-        ///      A <see cref="String"/> containing the contract name to export the type or member 
+        ///      A <see cref="string"/> containing the contract name to export the type or member 
         ///      marked with this attribute, under; or <see langword="null"/> or an empty string 
         ///      ("") to use the default contract name.
         /// </param>
@@ -95,7 +95,7 @@ namespace System.ComponentModel.Composition
         ///     type or member marked with this attribute under the specified contract name.
         /// </summary>
         /// <param name="contractName">
-        ///      A <see cref="String"/> containing the contract name to export the type or member 
+        ///      A <see cref="string"/> containing the contract name to export the type or member 
         ///      marked with this attribute, under; or <see langword="null"/> or an empty string 
         ///      ("") to use the default contract name.
         /// </param>
@@ -125,7 +125,7 @@ namespace System.ComponentModel.Composition
         ///     Gets the contract name to export the type or member under.
         /// </summary>
         /// <value>
-        ///      A <see cref="String"/> containing the contract name to export the type or member 
+        ///      A <see cref="string"/> containing the contract name to export the type or member 
         ///      marked with this attribute, under. The default value is an empty string ("").
         /// </value>
         public string ContractName { get; private set; }
index 566c400..39729ee 100644 (file)
@@ -17,7 +17,7 @@ namespace System.ComponentModel.Composition
         ///     specified name and metadata value.
         /// </summary>
         /// <param name="name">
-        ///     A <see cref="String"/> containing the name of the metadata value; or 
+        ///     A <see cref="string"/> containing the name of the metadata value; or 
         ///     <see langword="null"/> to set the <see cref="Name"/> property to an empty 
         ///     string ("").
         /// </param>
@@ -35,7 +35,7 @@ namespace System.ComponentModel.Composition
         ///     Gets the name of the metadata value.
         /// </summary>
         /// <value>
-        ///     A <see cref="String"/> containing the name of the metadata value.
+        ///     A <see cref="string"/> containing the name of the metadata value.
         /// </value>
         public string Name
         {
index d90125c..46012c1 100644 (file)
@@ -146,7 +146,7 @@ namespace System.ComponentModel.Composition.Hosting
         /// empty <see cref="IEnumerable{T}"/>.
         /// </result>
         /// <remarks>
-        ///    <note type="inheritinfo">
+        /// <note type="inheritinfo">
         /// The implementers should not treat the cardinality-related mismatches as errors, and are not
         /// expected to throw exceptions in those cases.
         /// For instance, if the import requests exactly one export and the provider has no matching exports or more than one,
index edb3a22..20ea301 100644 (file)
@@ -187,7 +187,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     Returns a string representation of the directory catalog.
         /// </summary>
         /// <returns>
-        ///     A <see cref="String"/> containing the string representation of the <see cref="DirectoryCatalog"/>.
+        ///     A <see cref="string"/> containing the string representation of the <see cref="DirectoryCatalog"/>.
         /// </returns>
         public override string ToString()
         {
@@ -198,7 +198,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     Gets the display name of the ApplicationCatalog.
         /// </summary>
         /// <value>
-        ///     A <see cref="String"/> containing a human-readable display name of the <see cref="ApplicationCatalog"/>.
+        ///     A <see cref="string"/> containing a human-readable display name of the <see cref="ApplicationCatalog"/>.
         /// </value>
         [SuppressMessage("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes")]
         string ICompositionElement.DisplayName
index 388a705..eeaecc6 100644 (file)
@@ -36,7 +36,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     with the specified code base.
         /// </summary>
         /// <param name="codeBase">
-        ///     A <see cref="String"/> containing the code base of the assembly containing the
+        ///     A <see cref="string"/> containing the code base of the assembly containing the
         ///     attributed <see cref="Type"/> objects to add to the <see cref="AssemblyCatalog"/>.
         /// </param>
         /// <exception cref="ArgumentNullException">
@@ -84,7 +84,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     with the specified code base.
         /// </summary>
         /// <param name="codeBase">
-        ///     A <see cref="String"/> containing the code base of the assembly containing the
+        ///     A <see cref="string"/> containing the code base of the assembly containing the
         ///     attributed <see cref="Type"/> objects to add to the <see cref="AssemblyCatalog"/>.
         /// </param>
         /// <param name="reflectionContext">
@@ -142,7 +142,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     with the specified code base.
         /// </summary>
         /// <param name="codeBase">
-        ///     A <see cref="String"/> containing the code base of the assembly containing the
+        ///     A <see cref="string"/> containing the code base of the assembly containing the
         ///     attributed <see cref="Type"/> objects to add to the <see cref="AssemblyCatalog"/>.
         /// </param>
         /// <param name="definitionOrigin">
@@ -198,7 +198,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     with the specified code base.
         /// </summary>
         /// <param name="codeBase">
-        ///     A <see cref="String"/> containing the code base of the assembly containing the
+        ///     A <see cref="string"/> containing the code base of the assembly containing the
         ///     attributed <see cref="Type"/> objects to add to the <see cref="AssemblyCatalog"/>.
         /// </param>
         /// <param name="reflectionContext">
@@ -477,7 +477,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     Gets the display name of the assembly catalog.
         /// </summary>
         /// <value>
-        ///     A <see cref="String"/> containing a human-readable display name of the <see cref="AssemblyCatalog"/>.
+        ///     A <see cref="string"/> containing a human-readable display name of the <see cref="AssemblyCatalog"/>.
         /// </value>
         [SuppressMessage("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes")]
         string ICompositionElement.DisplayName
@@ -501,7 +501,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     Returns a string representation of the assembly catalog.
         /// </summary>
         /// <returns>
-        ///     A <see cref="String"/> containing the string representation of the <see cref="AssemblyCatalog"/>.
+        ///     A <see cref="string"/> containing the string representation of the <see cref="AssemblyCatalog"/>.
         /// </returns>
         public override string ToString()
         {
index 0f4d95b..afd2661 100644 (file)
@@ -300,7 +300,7 @@ namespace System.ComponentModel.Composition.Hosting
         /// empty <see cref="IEnumerable{T}"/>.
         /// </result>
         /// <remarks>
-        ///    <note type="inheritinfo">
+        /// <note type="inheritinfo">
         /// The implementers should not treat the cardinality-related mismatches as errors, and are not
         /// expected to throw exceptions in those cases.
         /// For instance, if the import requests exactly one export and the provider has no matching exports or more than one,
index e37d990..b9c4144 100644 (file)
@@ -192,7 +192,7 @@ namespace System.ComponentModel.Composition.Hosting
         /// empty <see cref="IEnumerable{T}"/>.
         /// </result>
         /// <remarks>
-        ///    <note type="inheritinfo">
+        /// <note type="inheritinfo">
         /// The implementers should not treat the cardinality-related mismatches as errors, and are not
         /// expected to throw exceptions in those cases.
         /// For instance, if the import requests exactly one export and the provider has no matching exports or more than one,
index 55b02a8..4bddd0f 100644 (file)
@@ -587,7 +587,7 @@ namespace System.ComponentModel.Composition.Hosting
         /// empty <see cref="IEnumerable{T}"/>.
         /// </result>
         /// <remarks>
-        ///    <note type="inheritinfo">
+        /// <note type="inheritinfo">
         /// The implementers should not treat the cardinality-related mismatches as errors, and are not
         /// expected to throw exceptions in those cases.
         /// For instance, if the import requests exactly one export and the provider has no matching exports or more than one,
index a2546fd..99d01bc 100644 (file)
@@ -165,13 +165,13 @@ namespace System.ComponentModel.Composition.Hosting
         /// by <paramref name="definition"/>.
         /// </returns>
         /// <exception cref="ArgumentNullException">
-        ///    <paramref name="definition"/> is <see langword="null"/>.
+        /// <paramref name="definition"/> is <see langword="null"/>.
         /// </exception>
         /// <exception cref="ObjectDisposedException">
         /// The <see cref="ComposablePartCatalog"/> has been disposed of.
         /// </exception>
         /// <remarks>
-        ///    <note type="inheritinfo">
+        /// <note type="inheritinfo">
         /// Overriders of this property should never return <see langword="null"/>, if no
         /// <see cref="ExportDefinition"/> match the conditions defined by
         /// <paramref name="definition"/>, return an empty <see cref="IEnumerable{T}"/>.
index f88ecb4..cc814d2 100644 (file)
@@ -655,7 +655,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     Returns a string representation of the directory catalog.
         /// </summary>
         /// <returns>
-        ///     A <see cref="String"/> containing the string representation of the <see cref="DirectoryCatalog"/>.
+        ///     A <see cref="string"/> containing the string representation of the <see cref="DirectoryCatalog"/>.
         /// </returns>
         public override string ToString()
         {
@@ -782,7 +782,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     Gets the display name of the directory catalog.
         /// </summary>
         /// <value>
-        ///     A <see cref="String"/> containing a human-readable display name of the <see cref="DirectoryCatalog"/>.
+        ///     A <see cref="string"/> containing a human-readable display name of the <see cref="DirectoryCatalog"/>.
         /// </value>
         [SuppressMessage("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes")]
         string ICompositionElement.DisplayName
index 69f2cdf..32a28ce 100644 (file)
@@ -32,7 +32,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///         <see cref="Lazy{T, TMetadataView}"/> underneath, where 
         ///         <c>TMetadataView</c>
         ///         is <see cref="IDictionary{TKey, TValue}"/> and where <c>TKey</c> 
-        ///         is <see cref="String"/> and <c>TValue</c> is <see cref="Object"/>.
+        ///         is <see cref="string"/> and <c>TValue</c> is <see cref="object"/>.
         ///     </para>
         ///     <para>
         ///         The contract name is the result of calling 
@@ -70,7 +70,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     The type of the <see cref="Lazy{T}"/> object to return.
         /// </typeparam>
         /// <param name="contractName">
-        ///     A <see cref="String"/> containing the contract name of the <see cref="Lazy{T}"/> 
+        ///     A <see cref="string"/> containing the contract name of the <see cref="Lazy{T}"/> 
         ///     object to return; or <see langword="null"/> or an empty string ("") to use the 
         ///     default contract name.
         /// </param>
@@ -83,7 +83,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///         <see cref="Lazy{T, TMetadataView}"/> underneath, where 
         ///         <c>TMetadataView</c>
         ///         is <see cref="IDictionary{TKey, TValue}"/> and where <c>TKey</c> 
-        ///         is <see cref="String"/> and <c>TValue</c> is <see cref="Object"/>.
+        ///         is <see cref="string"/> and <c>TValue</c> is <see cref="object"/>.
         ///     </para>
         ///     <para>
         ///         The contract name is the result of calling 
@@ -175,7 +175,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     to return.
         /// </typeparam>
         /// <param name="contractName">
-        ///     A <see cref="String"/> containing the contract name of the 
+        ///     A <see cref="string"/> containing the contract name of the 
         ///     <see cref="Lazy{T, TMetadataView}"/> object to return; or <see langword="null"/> 
         ///     or an empty string ("") to use the default contract name.
         /// </param>
@@ -225,7 +225,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     return.
         /// </param>
         /// <param name="contractName">
-        ///     A <see cref="String"/> containing the contract name of the 
+        ///     A <see cref="string"/> containing the contract name of the 
         ///     <see cref="Export"/> object to return; or <see langword="null"/> 
         ///     or an empty string ("") to use the default contract name.
         /// </param>
@@ -292,7 +292,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///         <see cref="Lazy{T, TMetadataView}"/> underneath, where 
         ///         <c>TMetadataView</c>
         ///         is <see cref="IDictionary{TKey, TValue}"/> and where <c>TKey</c> 
-        ///         is <see cref="String"/> and <c>TValue</c> is <see cref="Object"/>.
+        ///         is <see cref="string"/> and <c>TValue</c> is <see cref="object"/>.
         ///     </para>
         ///     <para>
         ///         The contract name is the result of calling 
@@ -319,7 +319,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     The type of the <see cref="Lazy{T}"/> objects to return.
         /// </typeparam>
         /// <param name="contractName">
-        ///     A <see cref="String"/> containing the contract name of the <see cref="Lazy{T}"/> 
+        ///     A <see cref="string"/> containing the contract name of the <see cref="Lazy{T}"/> 
         ///     objects to return; or <see langword="null"/> or an empty string ("") to use the 
         ///     default contract name.
         /// </param>
@@ -334,7 +334,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///         <see cref="Lazy{T, TMetadataView}"/> underneath, where 
         ///         <c>TMetadataView</c>
         ///         is <see cref="IDictionary{TKey, TValue}"/> and where <c>TKey</c> 
-        ///         is <see cref="String"/> and <c>TValue</c> is <see cref="Object"/>.
+        ///         is <see cref="string"/> and <c>TValue</c> is <see cref="object"/>.
         ///     </para>
         ///     <para>
         ///         The default contract name is the result of calling 
@@ -405,7 +405,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     to return.
         /// </typeparam>
         /// <param name="contractName">
-        ///     A <see cref="String"/> containing the contract name of the 
+        ///     A <see cref="string"/> containing the contract name of the 
         ///     <see cref="Lazy{T, TMetadataView}"/> objects to return; or <see langword="null"/> 
         ///     or an empty string ("") to use the default contract name.
         /// </param>
@@ -445,7 +445,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     derived from this type parameter.
         /// </typeparam>
         /// <returns>
-        ///     The exported <see cref="Object"/> with the contract name derived from 
+        ///     The exported <see cref="object"/> with the contract name derived from 
         ///     <typeparamref name="T"/>.
         /// </returns>
         /// <remarks>
@@ -492,11 +492,11 @@ namespace System.ComponentModel.Composition.Hosting
         ///     The type of the exported value to return.
         /// </typeparam>
         /// <param name="contractName">
-        ///     A <see cref="String"/> containing the contract name of the exported value to return,
+        ///     A <see cref="string"/> containing the contract name of the exported value to return,
         ///     or <see langword="null"/> or an empty string ("") to use the default contract name.
         /// </param>
         /// <returns>
-        ///     The exported <see cref="Object"/> with the specified contract name.
+        ///     The exported <see cref="object"/> with the specified contract name.
         /// </returns>
         /// <remarks>
         ///     <para>
@@ -543,7 +543,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     derived from this type parameter.
         /// </typeparam>
         /// <returns>
-        ///     The exported <see cref="Object"/> with the contract name derived from 
+        ///     The exported <see cref="object"/> with the contract name derived from 
         ///     <typeparamref name="T"/>, if found; otherwise, the default value for
         ///     <typeparamref name="T"/>.
         /// </returns>
@@ -592,11 +592,11 @@ namespace System.ComponentModel.Composition.Hosting
         ///     The type of the exported value to return.
         /// </typeparam>
         /// <param name="contractName">
-        ///     A <see cref="String"/> containing the contract name of the exported value to return,
+        ///     A <see cref="string"/> containing the contract name of the exported value to return,
         ///     or <see langword="null"/> or an empty string ("") to use the default contract name.
         /// </param>
         /// <returns>
-        ///     The exported <see cref="Object"/> with the specified contract name, if found; 
+        ///     The exported <see cref="object"/> with the specified contract name, if found; 
         ///     otherwise, the default value for <typeparamref name="T"/>.
         /// </returns>
         /// <remarks>
@@ -680,7 +680,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     The type of the exported value to return.
         /// </typeparam>
         /// <param name="contractName">
-        ///     A <see cref="String"/> containing the contract name of the exported values to 
+        ///     A <see cref="string"/> containing the contract name of the exported values to 
         ///     return; or <see langword="null"/> or an empty string ("") to use the default 
         ///     contract name.
         /// </param>
index 2fdda03..dd45801 100644 (file)
@@ -139,13 +139,13 @@ namespace System.ComponentModel.Composition.Hosting
         /// by <paramref name="definition"/>.
         /// </returns>
         /// <exception cref="ArgumentNullException">
-        ///    <paramref name="definition"/> is <see langword="null"/>.
+        /// <paramref name="definition"/> is <see langword="null"/>.
         /// </exception>
         /// <exception cref="ObjectDisposedException">
         /// The <see cref="ComposablePartCatalog"/> has been disposed of.
         /// </exception>
         /// <remarks>
-        ///    <note type="inheritinfo">
+        /// <note type="inheritinfo">
         /// Overriders of this property should never return <see langword="null"/>, if no
         /// <see cref="ExportDefinition"/> match the conditions defined by
         /// <paramref name="definition"/>, return an empty <see cref="IEnumerable{T}"/>.
index 9d43859..3c9416e 100644 (file)
@@ -15,7 +15,7 @@ namespace System.ComponentModel.Composition.Hosting
         /// <param name="part">The part.</param>
         /// <param name="contractName">Name of the contract.</param>
         /// <returns>
-        ///    <c>true</c> if the specified part exports the specified contract; otherwise, <c>false</c>.
+        ///     <c>true</c> if the specified part exports the specified contract; otherwise, <c>false</c>.
         /// </returns>
         public static bool Exports(this ComposablePartDefinition part, string contractName)
         {
@@ -38,7 +38,7 @@ namespace System.ComponentModel.Composition.Hosting
         /// <param name="part">The part.</param>
         /// <param name="contractName">Name of the contract.</param>
         /// <returns>
-        ///    <c>true</c> if the specified part imports the specified contract; otherwise, <c>false</c>.
+        ///     <c>true</c> if the specified part imports the specified contract; otherwise, <c>false</c>.
         /// </returns>
         public static bool Imports(this ComposablePartDefinition part, string contractName)
         {
@@ -63,7 +63,7 @@ namespace System.ComponentModel.Composition.Hosting
         /// <param name="contractName">Name of the contract.</param>
         /// <param name="importCardinality">The import cardinality.</param>
         /// <returns>
-        ///    <c>true</c> if the specified part imports the specified contract with the given cardinality; otherwise, <c>false</c>.
+        ///     <c>true</c> if the specified part imports the specified contract with the given cardinality; otherwise, <c>false</c>.
         /// </returns>
         public static bool Imports(this ComposablePartDefinition part, string contractName, ImportCardinality importCardinality)
         {
@@ -87,7 +87,7 @@ namespace System.ComponentModel.Composition.Hosting
         /// <param name="part">The part.</param>
         /// <param name="key">The key.</param>
         /// <returns>
-        ///    <c>true</c> if the part contains a metadata entry with the specified key; otherwise, <c>false</c>.
+        ///     <c>true</c> if the part contains a metadata entry with the specified key; otherwise, <c>false</c>.
         /// </returns>
         public static bool ContainsPartMetadataWithKey(this ComposablePartDefinition part, string key)
         {
@@ -105,7 +105,7 @@ namespace System.ComponentModel.Composition.Hosting
         /// <param name="key">The key.</param>
         /// <param name="value">The value.</param>
         /// <returns>
-        ///    <c>true</c> the specified part contains a metadata entry with the specified key and value; otherwise, <c>false</c>.
+        ///     <c>true</c> the specified part contains a metadata entry with the specified key and value; otherwise, <c>false</c>.
         /// </returns>
         public static bool ContainsPartMetadata<T>(this ComposablePartDefinition part, string key, T value)
         {
index 382d646..275025e 100644 (file)
@@ -228,7 +228,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     Gets the display name of the type catalog.
         /// </summary>
         /// <value>
-        ///     A <see cref="String"/> containing a human-readable display name of the <see cref="TypeCatalog"/>.
+        ///     A <see cref="string"/> containing a human-readable display name of the <see cref="TypeCatalog"/>.
         /// </value>
         [SuppressMessage("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes")]
         string ICompositionElement.DisplayName
@@ -341,7 +341,7 @@ namespace System.ComponentModel.Composition.Hosting
         ///     Returns a string representation of the type catalog.
         /// </summary>
         /// <returns>
-        ///     A <see cref="String"/> containing the string representation of the <see cref="TypeCatalog"/>.
+        ///     A <see cref="string"/> containing the string representation of the <see cref="TypeCatalog"/>.
         /// </returns>
         public override string ToString()
         {
index 3cfa779..2be2c8b 100644 (file)
@@ -69,7 +69,7 @@ namespace System.ComponentModel.Composition
         ///     export with the specified contract name.
         /// </summary>
         /// <param name="contractName">
-        ///      A <see cref="String"/> containing the contract name of the export to import, or 
+        ///      A <see cref="string"/> containing the contract name of the export to import, or 
         ///      <see langword="null"/> or an empty string ("") to use the default contract name.
         /// </param>
         /// <remarks>
@@ -98,7 +98,7 @@ namespace System.ComponentModel.Composition
         ///     Gets the contract name of the export to import.
         /// </summary>
         /// <value>
-        ///      A <see cref="String"/> containing the contract name of the export to import. The 
+        ///      A <see cref="string"/> containing the contract name of the export to import. The 
         ///      default value is an empty string ("").
         /// </value>
         public string ContractName { get; private set; }
index 3d66ab5..033c3f9 100644 (file)
@@ -30,7 +30,7 @@ namespace System.ComponentModel.Composition
         ///     with the specified error message.
         /// </summary>
         /// <param name="message">
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="ImportCardinalityMismatchException"/>; or <see langword="null"/> to set
         ///     the <see cref="Exception.Message"/> property to its default value.
         /// </param>
@@ -45,7 +45,7 @@ namespace System.ComponentModel.Composition
         ///     exception.
         /// </summary>
         /// <param name="message">
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="ImportCardinalityMismatchException"/>; or <see langword="null"/> to set
         ///     the <see cref="Exception.Message"/> property to its default value.
         /// </param>
index fbc166d..2e8b702 100644 (file)
@@ -69,7 +69,7 @@ namespace System.ComponentModel.Composition
         ///     set of exports with the specified contract name.
         /// </summary>
         /// <param name="contractName">
-        ///      A <see cref="String"/> containing the contract name of the exports to import, or 
+        ///      A <see cref="string"/> containing the contract name of the exports to import, or 
         ///      <see langword="null"/> or an empty string ("") to use the default contract name.
         /// </param>
         /// <remarks>
@@ -98,7 +98,7 @@ namespace System.ComponentModel.Composition
         ///     Gets the contract name of the exports to import.
         /// </summary>
         /// <value>
-        ///      A <see cref="String"/> containing the contract name of the exports to import. The 
+        ///      A <see cref="string"/> containing the contract name of the exports to import. The 
         ///      default value is an empty string ("").
         /// </value>
         public string ContractName { get; private set; }
index 057339e..615f991 100644 (file)
@@ -68,7 +68,7 @@ namespace System.ComponentModel.Composition
         ///     type or member marked with this attribute under the specified contract name.
         /// </summary>
         /// <param name="contractName">
-        ///      A <see cref="String"/> containing the contract name to export the type 
+        ///      A <see cref="string"/> containing the contract name to export the type 
         ///      marked with this attribute, under; or <see langword="null"/> or an empty string 
         ///      ("") to use the default contract name.
         /// </param>
@@ -93,7 +93,7 @@ namespace System.ComponentModel.Composition
         ///     type or member marked with this attribute under the specified contract name.
         /// </summary>
         /// <param name="contractName">
-        ///      A <see cref="String"/> containing the contract name to export the type 
+        ///      A <see cref="string"/> containing the contract name to export the type 
         ///      marked with this attribute, under; or <see langword="null"/> or an empty string 
         ///      ("") to use the default contract name.
         /// </param>
index b2821f6..8857cff 100644 (file)
@@ -16,7 +16,7 @@ namespace System.ComponentModel.Composition
         ///     specified name and metadata value.
         /// </summary>
         /// <param name="name">
-        ///     A <see cref="String"/> containing the name of the metadata value; or 
+        ///     A <see cref="string"/> containing the name of the metadata value; or 
         ///     <see langword="null"/> to use an empty string ("").
         /// </param>
         /// <param name="value">
@@ -33,7 +33,7 @@ namespace System.ComponentModel.Composition
         ///     Gets the name of the metadata value.
         /// </summary>
         /// <value>
-        ///     A <see cref="String"/> containing the name of the metadata value.
+        ///     A <see cref="string"/> containing the name of the metadata value.
         /// </value>
         public string Name
         {
index 9712f29..c13beb4 100644 (file)
@@ -57,7 +57,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     with the specified error message.
         /// </summary>
         /// <param name="message">
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="ComposablePartException"/>; or <see langword="null"/> to set
         ///     the <see cref="Exception.Message"/> property to its default value.
         /// </param>
@@ -72,7 +72,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     the exception.
         /// </summary>
         /// <param name="message">
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="ComposablePartException"/>; or <see langword="null"/> to set
         ///     the <see cref="Exception.Message"/> property to its default value.
         /// </param>
@@ -93,7 +93,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     exception.
         /// </summary>
         /// <param name="message">
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="ComposablePartException"/>; or <see langword="null"/> to set
         ///     the <see cref="Exception.Message"/> property to its default value.
         /// </param>
@@ -113,7 +113,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     are the cause of the exception.
         /// </summary>
         /// <param name="message">
-        ///     A <see cref="String"/> containing a message that describes the 
+        ///     A <see cref="string"/> containing a message that describes the 
         ///     <see cref="ComposablePartException"/>; or <see langword="null"/> to set
         ///     the <see cref="Exception.Message"/> property to its default value.
         /// </param>
index 8998a83..143e0f3 100644 (file)
@@ -51,7 +51,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     is a prerequisite.
         /// </summary>
         /// <param name="contractName">
-        ///     A <see cref="String"/> containing the contract name of the 
+        ///     A <see cref="string"/> containing the contract name of the 
         ///     <see cref="Export"/> required by the <see cref="ContractBasedImportDefinition"/>.
         /// </param>
         /// <param name="requiredTypeIdentity">
@@ -59,7 +59,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     to generate a type identity for a given type. If no specific type is required pass <see langword="null"/>.
         /// </param>
         /// <param name="requiredMetadata">
-        ///     An <see cref="IEnumerable{T}"/> of <see cref="String"/> objects containing
+        ///     An <see cref="IEnumerable{T}"/> of <see cref="string"/> objects containing
         ///     the metadata names of the <see cref="Export"/> required by the 
         ///     <see cref="ContractBasedImportDefinition"/>; or <see langword="null"/> to
         ///     set the <see cref="RequiredMetadata"/> property to an empty <see cref="IEnumerable{T}"/>.
@@ -113,7 +113,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     is a prerequisite.
         /// </summary>
         /// <param name="contractName">
-        ///     A <see cref="String"/> containing the contract name of the 
+        ///     A <see cref="string"/> containing the contract name of the 
         ///     <see cref="Export"/> required by the <see cref="ContractBasedImportDefinition"/>.
         /// </param>
         /// <param name="requiredTypeIdentity">
@@ -121,7 +121,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     to generate a type identity for a given type. If no specific type is required pass <see langword="null"/>.
         /// </param>
         /// <param name="requiredMetadata">
-        ///     An <see cref="IEnumerable{T}"/> of <see cref="String"/> objects containing
+        ///     An <see cref="IEnumerable{T}"/> of <see cref="string"/> objects containing
         ///     the metadata names of the <see cref="Export"/> required by the 
         ///     <see cref="ContractBasedImportDefinition"/>; or <see langword="null"/> to
         ///     set the <see cref="RequiredMetadata"/> property to an empty <see cref="IEnumerable{T}"/>.
index 07dc38b..813dd0b 100644 (file)
@@ -39,7 +39,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     with the specified contract name and exported value getter.
         /// </summary>
         /// <param name="contractName">
-        ///     A <see cref="String"/> containing the contract name of the 
+        ///     A <see cref="string"/> containing the contract name of the 
         ///     <see cref="Export"/>.
         /// </param>
         /// <param name="exportedValueGetter">
@@ -66,7 +66,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     with the specified contract name, metadata and exported value getter.
         /// </summary>
         /// <param name="contractName">
-        ///     A <see cref="String"/> containing the contract name of the 
+        ///     A <see cref="string"/> containing the contract name of the 
         ///     <see cref="Export"/>.
         /// </param>
         /// <param name="metadata">
@@ -181,7 +181,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     Returns the exported value of the export.
         /// </summary>
         /// <returns>
-        ///     The exported <see cref="Object"/> of the <see cref="Export"/>.
+        ///     The exported <see cref="object"/> of the <see cref="Export"/>.
         /// </returns>
         /// <exception cref="CompositionException">
         ///     An error occurred during composition. <see cref="CompositionException.Errors"/> will 
@@ -214,7 +214,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     Returns the exported value of the export.
         /// </summary>
         /// <returns>
-        ///     The exported <see cref="Object"/> of the <see cref="Export"/>.
+        ///     The exported <see cref="object"/> of the <see cref="Export"/>.
         /// </returns>
         /// <exception cref="CompositionException">
         ///     An error occurred during composition. <see cref="CompositionException.Errors"/> will 
index ffe3910..4285468 100644 (file)
@@ -37,7 +37,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     the specified contract name and metadata.
         /// </summary>
         /// <param name="contractName">
-        ///     A <see cref="String"/> containing the contract name of the 
+        ///     A <see cref="string"/> containing the contract name of the 
         ///     <see cref="ExportDefinition"/>.
         /// </param>
         /// <param name="metadata">
@@ -68,7 +68,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     Gets the contract name of the export definition.
         /// </summary>
         /// <value>
-        ///     A <see cref="String"/> containing the contract name of the 
+        ///     A <see cref="string"/> containing the contract name of the 
         ///     <see cref="ExportDefinition"/>.
         /// </value>
         /// <exception cref="NotImplementedException">
@@ -127,7 +127,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     Returns a string representation of the export definition.
         /// </summary>
         /// <returns>
-        ///     A <see cref="String"/> containing the value of the <see cref="ContractName"/> property.
+        ///     A <see cref="string"/> containing the value of the <see cref="ContractName"/> property.
         /// </returns>
         public override string ToString()
         {
index ef69b28..10a4e4e 100644 (file)
@@ -13,7 +13,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     Gets the display name of the composition element.
         /// </summary>
         /// <value>
-        ///     A <see cref="String"/> containing a human-readable display name of the <see cref="ICompositionElement"/>.
+        ///     A <see cref="string"/> containing a human-readable display name of the <see cref="ICompositionElement"/>.
         /// </value>
         /// <remarks>
         ///     <note type="implementnotes">
index af6bdd6..809da3b 100644 (file)
@@ -124,9 +124,9 @@ namespace System.ComponentModel.Composition.Primitives
         ///     Gets the contract name of the export required by the import definition.
         /// </summary>
         /// <value>
-        ///     A <see cref="String"/> containing the contract name of the <see cref="Export"/> 
+        ///     A <see cref="string"/> containing the contract name of the <see cref="Export"/> 
         ///     required by the <see cref="ContractBasedImportDefinition"/>. This property should
-        ///     return <see cref="String.Empty"/> for imports that do not require a specific 
+        ///     return <see cref="string.Empty"/> for imports that do not require a specific 
         ///     contract name.
         /// </value>
         public virtual string ContractName
@@ -279,7 +279,7 @@ namespace System.ComponentModel.Composition.Primitives
         ///     Returns a string representation of the import definition.
         /// </summary>
         /// <returns>
-        ///     A <see cref="String"/> containing the value of the <see cref="Constraint"/> property.
+        ///     A <see cref="string"/> containing the value of the <see cref="Constraint"/> property.
         /// </returns>
         public override string ToString()
         {
index 99553d1..54297b7 100644 (file)
@@ -17,7 +17,7 @@ namespace System.ComponentModel.Composition
         {
             var catalog = CatalogFactory.Create();
             catalog.Dispose();
-                       var definition = ImportDefinitionFactory.Create();
+            var definition = ImportDefinitionFactory.Create();
 
             ExceptionAssert.ThrowsDisposed(catalog, () =>
             {
index 82a5eb2..3d32456 100644 (file)
@@ -116,7 +116,7 @@ namespace System.ComponentModel
         protected bool DesignMode => _site?.DesignMode ?? false;
 
         /// <summary>
-        /// Returns a <see cref='System.String'/> containing the name of the
+        /// Returns a <see cref='string'/> containing the name of the
         /// <see cref='System.ComponentModel.Component'/>, if any.
         /// This method should not be overridden.
         /// </summary>
index a95fe5f..9f26567 100644 (file)
@@ -96,7 +96,7 @@ namespace System.ComponentModel
         }
 
         /// <summary>
-        /// Initializes a new instance of the <see cref='System.ComponentModel.AmbientValueAttribute'/> class using a <see cref='System.Boolean'/>
+        /// Initializes a new instance of the <see cref='System.ComponentModel.AmbientValueAttribute'/> class using a <see cref='bool'/>
         /// value.
         /// </summary>
         public AmbientValueAttribute(bool value)
@@ -105,7 +105,7 @@ namespace System.ComponentModel
         }
 
         /// <summary>
-        /// Initializes a new instance of the <see cref='System.ComponentModel.AmbientValueAttribute'/> class using a <see cref='System.String'/>.
+        /// Initializes a new instance of the <see cref='System.ComponentModel.AmbientValueAttribute'/> class using a <see cref='string'/>.
         /// </summary>
         public AmbientValueAttribute(string value)
         {
index ce9ce66..e107c56 100644 (file)
@@ -128,7 +128,7 @@ namespace System.ComponentModel
                 if (dt.Ticks == 0) 
                 {
                     // Special case for empty DateTime
-                    ConstructorInfo ctr = typeof(DateTime).GetConstructor(new Type[] { typeof(Int64) });
+                    ConstructorInfo ctr = typeof(DateTime).GetConstructor(new Type[] { typeof(long) });
                         
                     if (ctr != null) 
                     {
index 36c64ca..f36b200 100644 (file)
@@ -10,7 +10,7 @@ using System.Reflection;
 namespace System.ComponentModel
 {
     /// <summary>
-    /// Provides a type converter to convert <see cref='System.Decimal'/>
+    /// Provides a type converter to convert <see cref='decimal'/>
     /// objects to and from various other representations.
     /// </summary>
     public class DecimalConverter : BaseNumberConverter
index b62b198..b02b26b 100644 (file)
@@ -154,7 +154,7 @@ namespace System.ComponentModel
         public virtual bool DesignMode => _site?.DesignMode ?? false;
 
         /// <summary>
-        /// Returns a <see cref='System.String'/> containing the name of the <see cref='System.ComponentModel.Component'/> , if any. This method should not be
+        /// Returns a <see cref='string'/> containing the name of the <see cref='System.ComponentModel.Component'/> , if any. This method should not be
         /// overridden. For
         /// internal use only.
         /// </summary>
index 5678a0a..614c45c 100644 (file)
@@ -193,7 +193,7 @@ namespace System.ComponentModel
         public virtual string Name => _name ?? "";
 
         /// <summary>
-        /// Gets the hash code for the name of the member as specified in <see cref='System.String.GetHashCode()'/>.
+        /// Gets the hash code for the name of the member as specified in <see cref='string.GetHashCode()'/>.
         /// </summary>
         protected virtual int NameHashCode => _nameHash;
 
index 1b6fb46..aae2e6d 100644 (file)
@@ -177,7 +177,7 @@ namespace System.ComponentModel
         }
 
         /// <summary>
-        /// Re-creates an <see cref='System.Object'/> given a set of property values for the object.
+        /// Re-creates an <see cref='object'/> given a set of property values for the object.
         /// </summary>
         public object CreateInstance(IDictionary propertyValues)
         {
@@ -185,7 +185,7 @@ namespace System.ComponentModel
         }
 
         /// <summary>
-        /// Re-creates an <see cref='System.Object'/> given a set of property values for the object.
+        /// Re-creates an <see cref='object'/> given a set of property values for the object.
         /// </summary>
         public virtual object CreateInstance(ITypeDescriptorContext context, IDictionary propertyValues) => null;
 
index c127dd3..bb9d9f7 100644 (file)
@@ -5,7 +5,7 @@
 // System.ComponentModel.Container test cases
 //
 // Authors:
-//     Gonzalo Paniagua Javier (gonzalo@ximian.com)
+//  Gonzalo Paniagua Javier (gonzalo@ximian.com)
 //  Ivan N. Zlatev (contact i-nZ.net)
 
 // Copyright (c) 2006 Novell, Inc. (http://www.novell.com)
index 4c16e14..a355dca 100644 (file)
@@ -3,10 +3,10 @@
 
 //
 // ContextStackTest.cs - Unit tests for 
-//     System.ComponentModel.Design.Serialization.ContextStack
+//  System.ComponentModel.Design.Serialization.ContextStack
 //
 // Author:
-//     Ivan N. Zlatev <contact@i-nz.net>
+//  Ivan N. Zlatev <contact@i-nz.net>
 //
 // Copyright (C) 2007 Ivan N. Zlatev <contact@i-nz.net>
 //
@@ -196,4 +196,4 @@ namespace System.ComponentModel.Tests
         {
         }
     }
-}
\ No newline at end of file
+}
index 10bdf49..50beee7 100644 (file)
@@ -3,10 +3,10 @@
 
 //
 // InstanceDescriptorTest.cs - Unit tests for 
-//     System.ComponentModel.Design.Serialization.InstanceDescriptor
+//  System.ComponentModel.Design.Serialization.InstanceDescriptor
 //
 // Author:
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index f104f26..01594fa 100644 (file)
@@ -5,9 +5,9 @@
 // System.ComponentModel.LicenseManagerTests test cases
 //
 // Authors:
-//     Ivan Hamilton (ivan@chimerical.com.au)
-//     Gonzalo Paniagua Javier (gonzalo@ximian.com)
-//     Martin Willemoes Hansen (mwh@sysrq.dk)
+//  Ivan Hamilton (ivan@chimerical.com.au)
+//  Gonzalo Paniagua Javier (gonzalo@ximian.com)
+//  Martin Willemoes Hansen (mwh@sysrq.dk)
 //
 // (c) 2002 Ximian, Inc. (http://www.ximian.com)
 // (c) 2003 Martin Willemoes Hansen
index af0c8af..1c68983 100644 (file)
@@ -11,63 +11,63 @@ namespace System.Security.Authentication.ExtendedProtection.Tests
 {
     public class ExtendedProtectionPolicyTypeConverterTests
     {
-       [Theory]
-       [InlineData(typeof(int))]
-       [InlineData(typeof(ExtendedProtectionPolicy))]
-       [InlineData(typeof(bool))]
-       [InlineData(null)]
-       [InlineData(typeof(float))]
-       [InlineData(typeof(TypeConverter))]
-       public void CanConvertTo_NegativeTests(Type destinationType)
-       {
-                       Assert.False(converter.CanConvertTo(null, destinationType));            
-       }
+        [Theory]
+        [InlineData(typeof(int))]
+        [InlineData(typeof(ExtendedProtectionPolicy))]
+        [InlineData(typeof(bool))]
+        [InlineData(null)]
+        [InlineData(typeof(float))]
+        [InlineData(typeof(TypeConverter))]
+        public void CanConvertTo_NegativeTests(Type destinationType)
+        {
+            Assert.False(converter.CanConvertTo(null, destinationType));         
+        }
 
-       [Fact]
-       public void CanConvertTo_PositiveTests()
-       {
-               Assert.True(converter.CanConvertTo(null, typeof(string)));
-               Assert.True(converter.CanConvertTo(null, typeof(InstanceDescriptor)));
-       }
+        [Fact]
+        public void CanConvertTo_PositiveTests()
+        {
+            Assert.True(converter.CanConvertTo(null, typeof(string)));
+            Assert.True(converter.CanConvertTo(null, typeof(InstanceDescriptor)));
+        }
 
-       [Fact]
-       public void ConvertTo_NullTypeTests()
-       {
-               Assert.Throws<ArgumentNullException>(() => converter.ConvertTo(null, CultureInfo.InvariantCulture, new ExtendedProtectionPolicy(PolicyEnforcement.Never), null));
-       }
+        [Fact]
+        public void ConvertTo_NullTypeTests()
+        {
+            Assert.Throws<ArgumentNullException>(() => converter.ConvertTo(null, CultureInfo.InvariantCulture, new ExtendedProtectionPolicy(PolicyEnforcement.Never), null));
+        }
 
-       [Fact]
-       public void ConvertTo_PositiveTests()
-       {
-               ExtendedProtectionPolicy policy = new ExtendedProtectionPolicy(PolicyEnforcement.Never);
-               
-               InstanceDescriptor instanceDescriptor = converter.ConvertTo(null, CultureInfo.InvariantCulture, policy, typeof(InstanceDescriptor)) as InstanceDescriptor;
-               ExtendedProtectionPolicy instanceResult = instanceDescriptor.Invoke() as ExtendedProtectionPolicy;
-               Assert.NotNull(instanceDescriptor);
-               Assert.NotNull(instanceResult);
-               Assert.Equal(PolicyEnforcement.Never, instanceResult.PolicyEnforcement);
-               Assert.Equal(policy.ProtectionScenario, instanceResult.ProtectionScenario);
-               Assert.Null(instanceResult.CustomServiceNames);
+        [Fact]
+        public void ConvertTo_PositiveTests()
+        {
+            ExtendedProtectionPolicy policy = new ExtendedProtectionPolicy(PolicyEnforcement.Never);
+            
+            InstanceDescriptor instanceDescriptor = converter.ConvertTo(null, CultureInfo.InvariantCulture, policy, typeof(InstanceDescriptor)) as InstanceDescriptor;
+            ExtendedProtectionPolicy instanceResult = instanceDescriptor.Invoke() as ExtendedProtectionPolicy;
+            Assert.NotNull(instanceDescriptor);
+            Assert.NotNull(instanceResult);
+            Assert.Equal(PolicyEnforcement.Never, instanceResult.PolicyEnforcement);
+            Assert.Equal(policy.ProtectionScenario, instanceResult.ProtectionScenario);
+            Assert.Null(instanceResult.CustomServiceNames);
 
-               Assert.Equal(string.Empty, 
-                       converter.ConvertTo(null, CultureInfo.InvariantCulture, null, typeof(string)) as string);
-               Assert.Equal(policy.ToString(), 
-                       converter.ConvertTo(null, CultureInfo.InvariantCulture, policy, typeof(string)) as string);
-       }
+            Assert.Equal(string.Empty, 
+                converter.ConvertTo(null, CultureInfo.InvariantCulture, null, typeof(string)) as string);
+            Assert.Equal(policy.ToString(), 
+                converter.ConvertTo(null, CultureInfo.InvariantCulture, policy, typeof(string)) as string);
+        }
 
-       [Theory]
-       [InlineData(typeof(int))]
-       [InlineData(typeof(ExtendedProtectionPolicy))]
-       [InlineData(typeof(bool))]
-       [InlineData(typeof(float))]
-       [InlineData(typeof(TypeConverter))]
-       public void ConvertTo_NegativeTests(Type destinationType)
-       {
-               ExtendedProtectionPolicy policy = new ExtendedProtectionPolicy(PolicyEnforcement.Never);
+        [Theory]
+        [InlineData(typeof(int))]
+        [InlineData(typeof(ExtendedProtectionPolicy))]
+        [InlineData(typeof(bool))]
+        [InlineData(typeof(float))]
+        [InlineData(typeof(TypeConverter))]
+        public void ConvertTo_NegativeTests(Type destinationType)
+        {
+            ExtendedProtectionPolicy policy = new ExtendedProtectionPolicy(PolicyEnforcement.Never);
 
-               Assert.Throws<NotSupportedException>(() => converter.ConvertTo(null, CultureInfo.InvariantCulture, policy, destinationType));
-       }
+            Assert.Throws<NotSupportedException>(() => converter.ConvertTo(null, CultureInfo.InvariantCulture, policy, destinationType));
+        }
 
-       private ExtendedProtectionPolicyTypeConverter converter = new ExtendedProtectionPolicyTypeConverter();
+        private ExtendedProtectionPolicyTypeConverter converter = new ExtendedProtectionPolicyTypeConverter();
     }
 }
index a2c8531..3112e86 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.CallbackValidator.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 6e85ae5..96783c1 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.CommaDelimitedStringCollectionConverter.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index a8dddca..135a4b9 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.CommaDelimitedStringCollection.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 34cb04f..cc4dfb5 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.ConfigurationElement.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2006 Novell, Inc (http://www.novell.com)
 //
index 9d8c521..a244850 100644 (file)
@@ -4,7 +4,7 @@
 // ConfigurationErrorsExceptionTest.cs
 //
 // Author:
-//     Gert Driesen  <drieseng@users.sourceforge.net>
+//  Gert Driesen  <drieseng@users.sourceforge.net>
 //
 // Copyright (C) 2008 Gert Driesen
 //
index e8d2930..34090dc 100644 (file)
@@ -5,7 +5,7 @@
 // tests for System.Configuration.ConfigurationLockCollection.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 1afd91e..7c49168 100644 (file)
@@ -5,8 +5,8 @@
 // for System.Configuration.ConfigurationManager.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
-//     Atsushi Enomoto  <atsushi@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
+//  Atsushi Enomoto  <atsushi@ximian.com>
 //
 // Copyright (C) 2005-2006 Novell, Inc (http://www.novell.com)
 //
index 3d5e090..5145dd3 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.ConfigurationElement.
 //
 // Author:
-//     Konstantin Triger <kostat@mainsoft.com>
+//  Konstantin Triger <kostat@mainsoft.com>
 //
 // Copyright (C) 2006 Mainsoft, Inc (http://www.mainsoft.com)
 //
index 758511c..ff2444e 100644 (file)
@@ -4,7 +4,7 @@
 // ConfigurationSectionGroupTest.cs
 //
 // Author:
-//     Atsushi Enomoto  <atsushi@ximian.com>
+//  Atsushi Enomoto  <atsushi@ximian.com>
 //
 // Copyright (C) 2007 Novell, Inc (http://www.novell.com)
 //
index 808337c..2dba3b8 100644 (file)
@@ -4,8 +4,8 @@
 // System.Configuration.ConfigurationSectionTest.cs - Unit tests
 //
 // Author:
-//     Greg Smolyn
-//     Gonzalo Paniagua Javier <gonzalo@novell.com
+//  Greg Smolyn
+//  Gonzalo Paniagua Javier <gonzalo@novell.com
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 6a4519c..4f77bf2 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.ConnectionStringSettings
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 6bf2375..d8ac109 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.DefaultValidator.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 81c98a7..2d3cb4c 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.ExeConfigurationFileMap.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index f17bd16..11e6f02 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.GenericEnumConverter.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 61066d2..4f57c7a 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.InfiniteIntConverter.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 46c9cce..3109f26 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.InfiniteTimeSpanConverter.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 268fc33..952ed60 100644 (file)
@@ -5,8 +5,8 @@
 // for System.Configuration.IntegerValidator.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
-//     Andres G. Aragoneses  <andres@7digital.com>
+//  Chris Toshok  <toshok@ximian.com>
+//    Andres G. Aragoneses  <andres@7digital.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 // Copyright (C) 2012 7digital Media, Ltd (http://www.7digital.com)
index 9bad339..fa5f7c5 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.KeyValueConfigurationCollection.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 055e063..6f1f1cf 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.KeyValueConfigurationElement.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 903381f..5a3e6c6 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.LongValidator.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 719bf6c..a1f8a73 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.PositiveTimeSpanValidator.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 5c5e70e..2b09452 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.RegexStringValidator.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 82d1052..c512013 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.StringValidator.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index b0ae448..9e049d6 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.SubclassTypeValidator.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 2ef6ca2..1c5ddd7 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.TimeSpanMinutesConverter.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 146413f..bd280bf 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.TimeSpanMinutesOrInfiniteConverter.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index f83984a..a462b5d 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.TimeSpanSecondsConverter.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 61d2848..dad3aae 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.TimeSpanSecondsOrInfiniteConverter.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index f01e546..574afbc 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.TimeSpanValidator.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index b672c41..31e28e6 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.TypeNameConverter.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 8517b4d..0964a4c 100644 (file)
@@ -5,7 +5,7 @@
 // for System.Configuration.WhiteSpaceTrimStringConverter.
 //
 // Author:
-//     Chris Toshok  <toshok@ximian.com>
+//  Chris Toshok  <toshok@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index 992f807..a4af4da 100644 (file)
@@ -605,7 +605,7 @@ namespace System
             }
         }
 
-        public unsafe static string Title
+        public static unsafe string Title
         {
             get
             {
index 4f0a63f..ce691dd 100644 (file)
@@ -24,5 +24,5 @@ namespace System.Data.Common
             value = null;
             return false;
         }
-       }
+    }
 }
\ No newline at end of file
index 88bdb5b..07e7314 100644 (file)
@@ -162,7 +162,7 @@ namespace System.Data
                 finalPredicate =
                     (DataRow row) =>
                     {
-                        if (!Object.ReferenceEquals(row, _selector((TRow)(object)row)))
+                        if (!object.ReferenceEquals(row, _selector((TRow)(object)row)))
                         {
                             throw DataSetUtil.NotSupported(SR.ToLDVUnsupported);
                         }
@@ -182,7 +182,7 @@ namespace System.Data
                 finalPredicate =
                     (DataRow row) =>
                     {
-                        if (!Object.ReferenceEquals(row, _selector((TRow)(object)row)))
+                        if (!object.ReferenceEquals(row, _selector((TRow)(object)row)))
                         {
                             throw DataSetUtil.NotSupported(SR.ToLDVUnsupported);
                         }
index 5877466..5e68f9d 100644 (file)
@@ -40,9 +40,9 @@ namespace System.Data
         internal const int Minus = 16;          // -
         internal const int Multiply = 17;       // *
         internal const int Divide = 18;     // /
-        //internal final static int IntegerDiv = 19;   // \
+        //internal final static int IntegerDiv = 19;    // \
         internal const int Modulo = 20;     // %
-        //internal final static int Exponent = 21;     // **
+        //internal final static int Exponent = 21;    // **
         /* End of arithmetic operators */
 
         /* Beginning of bitwise operators */
@@ -172,37 +172,37 @@ namespace System.Data
             "Between", //Between = 6;
 
             /* Beginning of Comparison (relationa) operators */
-            "=",    //EqualTo = 7;             // =
-            ">", //GreaterThen = 8;    // >
-            "<",    //LessThen = 9;            // <
+            "=",    //EqualTo = 7;        // =
+            ">", //GreaterThen = 8;    // >
+            "<",    //LessThen = 9;        // <
             ">=", //GreaterOrEqual = 10;// >=
-            "<=",       //LessOrEqual = 11;    // <=
-            "<>", //NotEqual = 12;             // <>
+            "<=",       //LessOrEqual = 11;    // <=
+            "<>", //NotEqual = 12;        // <>
             /* End of Comparison (relational) operators */
 
             "Is",       //Is = 13;
             "Like", //Like = 14;
 
             /* Beginning of arithmetic operators */
-            "+",    //Plus = 15;                       // +
-            "-", //Minus = 16;                 // -
-            "*", //Multiply = 17;              // *
-            "/",    //Divide = 18;             // /
-            "\\", //IntegerDiv = 19;   // \
-            "Mod", //Modulo = 20;              // %
-            "**", //Exponent = 21;     // **
+            "+",    //Plus = 15;            // +
+            "-", //Minus = 16;            // -
+            "*", //Multiply = 17;        // *
+            "/",    //Divide = 18;        // /
+            "\\", //IntegerDiv = 19;    // \
+            "Mod", //Modulo = 20;        // %
+            "**", //Exponent = 21;    // **
             /* End of arithmetic operators */
 
             /* Beginning of bitwise operators */
-            "&",    //BitwiseAnd = 22; // &
-            "|",    //BitwiseOr = 23;          // |
-            "^",    //BitwiseXor = 24; // ^
-            "~",    //BitwiseNot = 25; // ~
+            "&",    //BitwiseAnd = 22;    // &
+            "|",    //BitwiseOr = 23;        // |
+            "^",    //BitwiseXor = 24;    // ^
+            "~",    //BitwiseNot = 25;    // ~
             /* End of bitwise operators */
 
             /* Beginning of logical operators */
-            "And",  //And = 26;                // AND
-            "Or",       //Or = 27;             // OR
+            "And",  //And = 26;        // AND
+            "Or",       //Or = 27;        // OR
             // Not is in the unary ops
             /* End of logical operators */
 
@@ -217,12 +217,12 @@ namespace System.Data
             "True", //True = 33;
             "False", //False = 34;
 
-            "Date", //Date = 35;                       // Date constant
-            "GenUniqueId()",    //GenUniqueId = 36;    // Generate unique ID
-            "GenGuid()",    //GenGUID = 37;            // Generate GUID
-            "Guid {..}",    //GUID = 38;                       // GUID constant
+            "Date", //Date = 35;            // Date constant
+            "GenUniqueId()",    //GenUniqueId = 36;    // Generate unique ID
+            "GenGuid()",    //GenGUID = 37;        // Generate GUID
+            "Guid {..}",    //GUID = 38;            // GUID constant
 
-            "Is Not",   //IsNot = 39;                  // internal only
+            "Is Not",   //IsNot = 39;            // internal only
         };
 
         internal static string ToString(int op)
index 1ff9433..2fb6d08 100644 (file)
@@ -88,7 +88,7 @@ namespace System.Data
                 if (value == null) 
                 {
                     base.RowPredicate = null;
-                    base.RowFilter = String.Empty; // INDEX rebuild twice
+                    base.RowFilter = string.Empty; // INDEX rebuild twice
                 }
                 else
                 {
@@ -108,10 +108,10 @@ namespace System.Data
         internal override int FindByKey(object key)
         {
             Debug.Assert(base.Sort != null);
-            Debug.Assert(!(!String.IsNullOrEmpty(base.Sort) && base.SortComparison != null),
+            Debug.Assert(!(!string.IsNullOrEmpty(base.Sort) && base.SortComparison != null),
                 "string and expression based sort cannot both be set");
 
-            if (!String.IsNullOrEmpty(base.Sort))  // use find for DV's sort string
+            if (!string.IsNullOrEmpty(base.Sort))  // use find for DV's sort string
             {
                 return base.FindByKey(key);
             }
@@ -144,7 +144,7 @@ namespace System.Data
         internal override int FindByKey(object[] key)
         {
             // must have string or expression based sort specified
-            if (base.SortComparison == null && String.IsNullOrEmpty(base.Sort)) 
+            if (base.SortComparison == null && string.IsNullOrEmpty(base.Sort)) 
             {
                 // This is the exception message from DataView that we want to use
                 throw ExceptionBuilder.IndexKeyLength(0, 0);
@@ -184,7 +184,7 @@ namespace System.Data
         internal override DataRowView[] FindRowsByKey(object[] key)
         {
             // must have string or expression based sort specified
-            if (base.SortComparison == null && String.IsNullOrEmpty(base.Sort))
+            if (base.SortComparison == null && string.IsNullOrEmpty(base.Sort))
             {
                 // This is the exception message from DataView that we want to use
                 throw ExceptionBuilder.IndexKeyLength(0, 0);
@@ -237,7 +237,7 @@ namespace System.Data
         /// </summary>
         void IBindingList.RemoveSort()
         {
-            base.Sort = String.Empty;
+            base.Sort = string.Empty;
             base.SortComparison = null;
         }
 
index bf84e5f..5f7d2a5 100644 (file)
@@ -25,22 +25,22 @@ namespace System.Data.SqlTypes
     public sealed class SqlBytes : INullable, IXmlSerializable, ISerializable
     {
         // --------------------------------------------------------------
-        //       Data members
+        //      Data members
         // --------------------------------------------------------------
 
         // SqlBytes has five possible states
         // 1) SqlBytes is Null
-        //             - m_stream must be null, m_lCuLen must be x_lNull.
+        //      - m_stream must be null, m_lCuLen must be x_lNull.
         // 2) SqlBytes contains a valid buffer, 
-        //             - m_rgbBuf must not be null,m_stream must be null
+        //      - m_rgbBuf must not be null,m_stream must be null
         // 3) SqlBytes contains a valid pointer
-        //             - m_rgbBuf could be null or not,
-        //                     if not null, content is garbage, should never look into it.
+        //      - m_rgbBuf could be null or not,
+        //        if not null, content is garbage, should never look into it.
         //      - m_stream must be null.
         // 4) SqlBytes contains a Stream
         //      - m_stream must not be null
         //      - m_rgbBuf could be null or not. if not null, content is garbage, should never look into it.
-        //             - m_lCurLen must be x_lNull.
+        //      - m_lCurLen must be x_lNull.
         // 5) SqlBytes contains a Lazy Materialized Blob (ie, StorageState.Delayed)
         //
         internal byte[] _rgbBuf;   // Data buffer
@@ -56,7 +56,7 @@ namespace System.Data.SqlTypes
         private const long x_lNull = -1L;
 
         // --------------------------------------------------------------
-        //       Constructor(s)
+        //      Constructor(s)
         // --------------------------------------------------------------
 
         // Public default constructor used for XML serialization
@@ -106,7 +106,7 @@ namespace System.Data.SqlTypes
 
 
         // --------------------------------------------------------------
-        //       Public properties
+        //      Public properties
         // --------------------------------------------------------------
 
         // INullable
@@ -119,7 +119,7 @@ namespace System.Data.SqlTypes
         }
 
         // Property: the in-memory buffer of SqlBytes
-        //             Return Buffer even if SqlBytes is Null.
+        //        Return Buffer even if SqlBytes is Null.
         public byte[] Buffer
         {
             get
@@ -152,9 +152,9 @@ namespace System.Data.SqlTypes
         }
 
         // Property: the max length of the data
-        //             Return MaxLength even if SqlBytes is Null.
-        //             When the buffer is also null, return -1.
-        //             If containing a Stream, return -1.
+        //        Return MaxLength even if SqlBytes is Null.
+        //        When the buffer is also null, return -1.
+        //        If containing a Stream, return -1.
         public long MaxLength
         {
             get
@@ -260,7 +260,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Public methods
+        //      Public methods
         // --------------------------------------------------------------
 
         public void SetNull()
@@ -422,7 +422,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Conversion operators
+        //      Conversion operators
         // --------------------------------------------------------------
 
         // Alternative method: ToSqlBinary()
@@ -438,7 +438,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Private utility functions
+        //      Private utility functions
         // --------------------------------------------------------------
 
         [Conditional("DEBUG")]
@@ -501,7 +501,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //             XML Serialization
+        //         XML Serialization
         // --------------------------------------------------------------
 
         XmlSchema IXmlSerializable.GetSchema()
@@ -561,7 +561,7 @@ namespace System.Data.SqlTypes
 
 
         // --------------------------------------------------------------
-        //             Serialization using ISerializable
+        //         Serialization using ISerializable
         // --------------------------------------------------------------
 
         // State information is not saved. The current state is converted to Buffer and only the underlying
@@ -572,7 +572,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Static fields, properties
+        //      Static fields, properties
         // --------------------------------------------------------------
 
         // Get a Null instance. 
@@ -594,14 +594,14 @@ namespace System.Data.SqlTypes
     internal sealed class StreamOnSqlBytes : Stream
     {
         // --------------------------------------------------------------
-        //       Data members
+        //      Data members
         // --------------------------------------------------------------
 
         private SqlBytes _sb;      // the SqlBytes object 
         private long _lPosition;
 
         // --------------------------------------------------------------
-        //       Constructor(s)
+        //      Constructor(s)
         // --------------------------------------------------------------
 
         internal StreamOnSqlBytes(SqlBytes sb)
@@ -611,7 +611,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Public properties
+        //      Public properties
         // --------------------------------------------------------------
 
         // Always can read/write/seek, unless sb is null, 
@@ -668,7 +668,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Public methods
+        //      Public methods
         // --------------------------------------------------------------
 
         public override long Seek(long offset, SeekOrigin origin)
@@ -794,7 +794,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Private utility functions
+        //      Private utility functions
         // --------------------------------------------------------------
 
         private bool FClosed()
index f9476f2..1f68527 100644 (file)
@@ -17,22 +17,22 @@ namespace System.Data.SqlTypes
     public sealed class SqlChars : INullable, IXmlSerializable, ISerializable
     {
         // --------------------------------------------------------------
-        //       Data members
+        //      Data members
         // --------------------------------------------------------------
 
         // SqlChars has five possible states
         // 1) SqlChars is Null
-        //             - m_stream must be null, m_lCuLen must be x_lNull
+        //        - m_stream must be null, m_lCuLen must be x_lNull
         // 2) SqlChars contains a valid buffer, 
-        //             - m_rgchBuf must not be null, and m_stream must be null
+        //        - m_rgchBuf must not be null, and m_stream must be null
         // 3) SqlChars contains a valid pointer
-        //             - m_rgchBuf could be null or not,
-        //                     if not null, content is garbage, should never look into it.
+        //        - m_rgchBuf could be null or not,
+        //            if not null, content is garbage, should never look into it.
         //      - m_stream must be null.
         // 4) SqlChars contains a SqlStreamChars
         //      - m_stream must not be null
         //      - m_rgchBuf could be null or not. if not null, content is garbage, should never look into it.
-        //             - m_lCurLen must be x_lNull.
+        //        - m_lCurLen must be x_lNull.
         // 5) SqlChars contains a Lazy Materialized Blob (ie, StorageState.Delayed)
         //
         internal char[] _rgchBuf;  // Data buffer
@@ -48,7 +48,7 @@ namespace System.Data.SqlTypes
         private const long x_lNull = -1L;
 
         // --------------------------------------------------------------
-        //       Constructor(s)
+        //      Constructor(s)
         // --------------------------------------------------------------
 
         // Public default constructor used for XML serialization
@@ -97,7 +97,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Public properties
+        //      Public properties
         // --------------------------------------------------------------
 
         // INullable
@@ -110,7 +110,7 @@ namespace System.Data.SqlTypes
         }
 
         // Property: the in-memory buffer of SqlChars
-        //             Return Buffer even if SqlChars is Null.
+        //        Return Buffer even if SqlChars is Null.
 
         public char[] Buffer
         {
@@ -144,9 +144,9 @@ namespace System.Data.SqlTypes
         }
 
         // Property: the max length of the data
-        //             Return MaxLength even if SqlChars is Null.
-        //             When the buffer is also null, return -1.
-        //             If containing a Stream, return -1.
+        //        Return MaxLength even if SqlChars is Null.
+        //        When the buffer is also null, return -1.
+        //        If containing a Stream, return -1.
 
         public long MaxLength
         {
@@ -257,7 +257,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Public methods
+        //      Public methods
         // --------------------------------------------------------------
 
         public void SetNull()
@@ -421,7 +421,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Conversion operators
+        //      Conversion operators
         // --------------------------------------------------------------
 
         // Alternative method: ToSqlString()
@@ -437,7 +437,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Private utility functions
+        //      Private utility functions
         // --------------------------------------------------------------
 
         [Conditional("DEBUG")]
@@ -499,7 +499,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //             XML Serialization
+        //         XML Serialization
         // --------------------------------------------------------------
 
 
@@ -546,7 +546,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //             Serialization using ISerializable
+        //         Serialization using ISerializable
         // --------------------------------------------------------------
 
         // State information is not saved. The current state is converted to Buffer and only the underlying
@@ -557,7 +557,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Static fields, properties
+        //      Static fields, properties
         // --------------------------------------------------------------
 
         // Get a Null instance. 
@@ -577,14 +577,14 @@ namespace System.Data.SqlTypes
     internal sealed class SqlStreamChars
     {
         // --------------------------------------------------------------
-        //       Data members
+        //      Data members
         // --------------------------------------------------------------
 
         private SqlChars _sqlchars;        // the SqlChars object 
         private long _lPosition;
 
         // --------------------------------------------------------------
-        //       Constructor(s)
+        //      Constructor(s)
         // --------------------------------------------------------------
 
         internal SqlStreamChars(SqlChars s)
@@ -594,7 +594,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Public properties
+        //      Public properties
         // --------------------------------------------------------------
 
         public long Length
@@ -624,7 +624,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Public methods
+        //      Public methods
         // --------------------------------------------------------------
 
         public long Seek(long offset, SeekOrigin origin)
@@ -705,7 +705,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Private utility functions
+        //      Private utility functions
         // --------------------------------------------------------------
 
         private bool FClosed()
index 0108f3f..fe8ebf2 100644 (file)
@@ -40,7 +40,7 @@ namespace System.Data.SqlTypes
 
         public SqlXml(XmlReader value)
         {
-            // whoever pass in the XmlReader is responsible for closing it                       
+            // whoever pass in the XmlReader is responsible for closing it
             if (value == null)
             {
                 SetNull();
@@ -208,7 +208,7 @@ namespace System.Data.SqlTypes
                 ww.WriteNode(reader, true);
             }
             ww.Flush();
-            // set the stream to the beginning                 
+            // set the stream to the beginning
             writerStream.Seek(0, SeekOrigin.Begin);
             return writerStream;
         }
@@ -269,17 +269,17 @@ namespace System.Data.SqlTypes
         {
             return new XmlQualifiedName("anyType", XmlSchema.Namespace);
         }
-    } // SqlXml                
+    } // SqlXml
 
     // two purposes for this class
     // 1) keep its internal position so one reader positions on the orginial stream 
-    //   will not interface with the other
+    //    will not interface with the other
     // 2) when xmlreader calls close, do not close the orginial stream
     //
     internal sealed class SqlXmlStreamWrapper : Stream
     {
         // --------------------------------------------------------------
-        //       Data members
+        //      Data members
         // --------------------------------------------------------------
 
         private Stream _stream;
@@ -287,7 +287,7 @@ namespace System.Data.SqlTypes
         private bool _isClosed;
 
         // --------------------------------------------------------------
-        //       Constructor(s)
+        //      Constructor(s)
         // --------------------------------------------------------------
 
         internal SqlXmlStreamWrapper(Stream stream)
@@ -299,7 +299,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Public properties
+        //      Public properties
         // --------------------------------------------------------------
 
         // Always can read/write/seek, unless stream is null, 
@@ -365,7 +365,7 @@ namespace System.Data.SqlTypes
         }
 
         // --------------------------------------------------------------
-        //       Public methods
+        //      Public methods
         // --------------------------------------------------------------
 
         public override long Seek(long offset, SeekOrigin origin)
index d3b6d16..4ec5c7e 100644 (file)
@@ -181,36 +181,36 @@ namespace System.Data.Tests.Common
         [Fact]
         public void Equals()
         {
-            //                 DataColumnMappingCollection collect2=new DataColumnMappingCollection();
+            //            DataColumnMappingCollection collect2=new DataColumnMappingCollection();
             _columnMapCollection.AddRange(_cols);
-            //                 collect2.AddRange(cols);
+            //            collect2.AddRange(cols);
             DataColumnMappingCollection copy1;
             copy1 = _columnMapCollection;
 
-            //                 Assert.Equal (false, columnMapCollection.Equals(collect2));
+            //            Assert.Equal (false, columnMapCollection.Equals(collect2));
             Assert.True(_columnMapCollection.Equals(copy1));
-            //                 Assert.Equal (false, collect2.Equals(columnMapCollection));
+            //            Assert.Equal (false, collect2.Equals(columnMapCollection));
             Assert.True(copy1.Equals(_columnMapCollection));
-            //                 Assert.Equal (false, collect2.Equals(copy1));
+            //            Assert.Equal (false, collect2.Equals(copy1));
             Assert.True(copy1.Equals(_columnMapCollection));
             Assert.True(_columnMapCollection.Equals(_columnMapCollection));
-            //                 Assert.Equal (true, collect2.Equals(collect2));
+            //            Assert.Equal (true, collect2.Equals(collect2));
             Assert.True(copy1.Equals(copy1));
 
-            //                 Assert.Equal (false, Object.Equals(collect2, columnMapCollection));
+            //            Assert.Equal (false, Object.Equals(collect2, columnMapCollection));
             Assert.True(object.Equals(copy1, _columnMapCollection));
-            //                 Assert.Equal (false, Object.Equals(columnMapCollection, collect2));
+            //            Assert.Equal (false, Object.Equals(columnMapCollection, collect2));
             Assert.True(object.Equals(_columnMapCollection, copy1));
-            //                 Assert.Equal (false, Object.Equals(copy1, collect2));
+            //            Assert.Equal (false, Object.Equals(copy1, collect2));
             Assert.True(object.Equals(_columnMapCollection, copy1));
             Assert.True(object.Equals(_columnMapCollection, _columnMapCollection));
-            //                 Assert.Equal (true, Object.Equals(collect2, collect2));
+            //            Assert.Equal (true, Object.Equals(collect2, collect2));
             Assert.True(object.Equals(copy1, copy1));
-            //                 Assert.Equal (false, Object.Equals(columnMapCollection, collect2));
+            //            Assert.Equal (false, Object.Equals(columnMapCollection, collect2));
             Assert.True(object.Equals(_columnMapCollection, copy1));
-            //                 Assert.Equal (false, Object.Equals(collect2, columnMapCollection));
+            //            Assert.Equal (false, Object.Equals(collect2, columnMapCollection));
             Assert.True(object.Equals(copy1, _columnMapCollection));
-            //                 Assert.Equal (false, Object.Equals(collect2, copy1));
+            //            Assert.Equal (false, Object.Equals(collect2, copy1));
             Assert.True(object.Equals(copy1, _columnMapCollection));
         }
 
index 518a331..7857724 100644 (file)
@@ -162,36 +162,36 @@ namespace System.Data.Tests.Common
         [Fact]
         public void Equals()
         {
-            //                 DataTableMappingCollection collect2=new DataTableMappingCollection();
+            //            DataTableMappingCollection collect2=new DataTableMappingCollection();
             _tableMapCollection.AddRange(_tabs);
-            //                 collect2.AddRange(tabs);
+            //            collect2.AddRange(tabs);
             DataTableMappingCollection copy1;
             copy1 = _tableMapCollection;
 
-            //                 Assert.False(tableMapCollection.Equals(collect2));
+            //            Assert.False(tableMapCollection.Equals(collect2));
             Assert.True(_tableMapCollection.Equals(copy1));
-            //                 Assert.False(collect2.Equals(tableMapCollection));
+            //            Assert.False(collect2.Equals(tableMapCollection));
             Assert.True(copy1.Equals(_tableMapCollection));
-            //                 Assert.False(collect2.Equals(copy1));
+            //            Assert.False(collect2.Equals(copy1));
             Assert.True(copy1.Equals(_tableMapCollection));
             Assert.True(_tableMapCollection.Equals(_tableMapCollection));
-            //                 Assert.True(collect2.Equals(collect2));
+            //            Assert.True(collect2.Equals(collect2));
             Assert.True(copy1.Equals(copy1));
 
-            //                 Assert.False(Object.Equals(collect2, tableMapCollection));
+            //            Assert.False(Object.Equals(collect2, tableMapCollection));
             Assert.True(object.Equals(copy1, _tableMapCollection));
-            //                 Assert.False(Object.Equals(tableMapCollection, collect2));
+            //            Assert.False(Object.Equals(tableMapCollection, collect2));
             Assert.True(object.Equals(_tableMapCollection, copy1));
-            //                 Assert.False(Object.Equals(copy1, collect2));
+            //            Assert.False(Object.Equals(copy1, collect2));
             Assert.True(object.Equals(_tableMapCollection, copy1));
             Assert.True(object.Equals(_tableMapCollection, _tableMapCollection));
-            //                 Assert.True(Object.Equals(collect2, collect2));
+            //            Assert.True(Object.Equals(collect2, collect2));
             Assert.True(object.Equals(copy1, copy1));
-            //                 Assert.False(Object.Equals(tableMapCollection, collect2));
+            //            Assert.False(Object.Equals(tableMapCollection, collect2));
             Assert.True(object.Equals(_tableMapCollection, copy1));
-            //                 Assert.False(Object.Equals(collect2, tableMapCollection));
+            //            Assert.False(Object.Equals(collect2, tableMapCollection));
             Assert.True(object.Equals(copy1, _tableMapCollection));
-            //                 Assert.False(Object.Equals(collect2, copy1));
+            //            Assert.False(Object.Equals(collect2, copy1));
             Assert.True(object.Equals(copy1, _tableMapCollection));
         }
 
index 133b0ac..e17da58 100644 (file)
@@ -504,7 +504,7 @@ namespace System.Data.Tests
                 ds.Tables.Add(DataProvider.CreateChildDataTable());
                 Constraint badConstraint = new UniqueConstraint(ds.Tables[0].Columns[0]);
 
-                ds.Tables[1].Constraints.AddRange(new Constraint[] { badConstraint }); //Cuz foreign key belongs to child table        
+                ds.Tables[1].Constraints.AddRange(new Constraint[] { badConstraint }); //Cuz foreign key belongs to child table
             });
         }
 
index cbedf8b..72d1c00 100644 (file)
@@ -240,8 +240,8 @@ namespace System.Data.Tests
             }
             catch (ArgumentException e)
             {
-                //                             Assert.Equal (typeof (ArgumentException), e.GetType ());
-                //                             Assert.Equal ("Column 'test' already belongs to this or another DataTable.", e.Message);
+                //                Assert.Equal (typeof (ArgumentException), e.GetType ());
+                //                Assert.Equal ("Column 'test' already belongs to this or another DataTable.", e.Message);
             }
 
             try
@@ -251,8 +251,8 @@ namespace System.Data.Tests
             }
             catch (ArgumentException e)
             {
-                //                             Assert.Equal (typeof (ArgumentException), e.GetType ());
-                //                             Assert.Equal ("Column 'test' already belongs to this or another DataTable.", e.Message);
+                //                Assert.Equal (typeof (ArgumentException), e.GetType ());
+                //                Assert.Equal ("Column 'test' already belongs to this or another DataTable.", e.Message);
             }
 
             DataColumn C2 = new DataColumn("test");
@@ -264,8 +264,8 @@ namespace System.Data.Tests
             }
             catch (DuplicateNameException e)
             {
-                //                             Assert.Equal (typeof (DuplicateNameException), e.GetType ());
-                //                             Assert.Equal ("A DataColumn named 'test' already belongs to this DataTable.", e.Message);
+                //                Assert.Equal (typeof (DuplicateNameException), e.GetType ());
+                //                Assert.Equal ("A DataColumn named 'test' already belongs to this DataTable.", e.Message);
             }
 
             try
@@ -275,8 +275,8 @@ namespace System.Data.Tests
             }
             catch (InvalidExpressionException e)
             {
-                //                             Assert.True (e is InvalidExpressionException);
-                //                             Assert.Equal ("Expression 'substring ('fdsafewq', 2)' is invalid.", e.Message);
+                //                Assert.True (e is InvalidExpressionException);
+                //                Assert.Equal ("Expression 'substring ('fdsafewq', 2)' is invalid.", e.Message);
             }
         }
 
index 903ff99..84f2d22 100644 (file)
@@ -73,7 +73,7 @@ namespace System.Data.Tests
                 Assert.Equal(typeof(ArgumentNullException), ex.GetType());
                 Assert.Null(ex.InnerException);
                 // Never premise English.
-                //                             Assert.NotNull (ex.Message);
+                //                Assert.NotNull (ex.Message);
                 Assert.NotNull(ex.ParamName);
                 Assert.Equal("dataType", ex.ParamName);
             }
@@ -995,25 +995,25 @@ namespace System.Data.Tests
 
 #if false
 // Check Windows output for the row [0] value
-               [Fact]
-               public void NullStrings ()
-               {
-                       var a = MakeColumn ("nullbar", "null+'bar'");
-                       var b = MakeColumn ("barnull", "'bar'+null");
-                       var c = MakeColumn ("foobar", "'foo'+'bar'");
-
-                       var table = new DataTable();
-                       
-                       table.Columns.Add(a);
-                       table.Columns.Add(b);
-                       table.Columns.Add(c);
-               
-                       var row = table.NewRow();
-                       table.Rows.Add(row);
-                       Assert.Equal (row [0], DBNull.Value);
-                       Assert.Equal (row [1], DBNull.Value);
-                       Assert.Equal (row [2], "foobar");
-               }
+        [Fact]
+        public void NullStrings ()
+        {
+            var a = MakeColumn ("nullbar", "null+'bar'");
+            var b = MakeColumn ("barnull", "'bar'+null");
+            var c = MakeColumn ("foobar", "'foo'+'bar'");
+
+                var table = new DataTable();
+                
+                table.Columns.Add(a);
+                table.Columns.Add(b);
+                table.Columns.Add(c);
+        
+                var row = table.NewRow();
+                table.Rows.Add(row);
+            Assert.Equal (row [0], DBNull.Value);
+            Assert.Equal (row [1], DBNull.Value);
+            Assert.Equal (row [2], "foobar");
+        }
 #endif
     }
 }
index b2b3863..a2cf994 100644 (file)
@@ -355,7 +355,7 @@ namespace System.Data.Tests
             string sColName, sExp;
             dc = new DataColumn();
 
-            //ToString = ColumnName                    
+            //ToString = ColumnName
             sColName = "Test1";
             dc.ColumnName = sColName;
             // ToString - ColumnName
index ee3ae2a..81e707a 100644 (file)
@@ -207,7 +207,7 @@ namespace System.Data.Tests
             catch (ArgumentException e)
             {
                 // MSDN says this exception is InvalidCastException
-                //                             Assert.Equal (typeof (ArgumentException), e.GetType ());
+                //                Assert.Equal (typeof (ArgumentException), e.GetType ());
             }
 
             object[] obs1 = new object[5];
index 6398ed4..2008ea0 100644 (file)
@@ -257,7 +257,7 @@ namespace System.Data.Tests
             {
                 DataSet ds = DataProvider.CreateForeignConstraint();
 
-                ds.Tables[0].Rows.Clear(); //Try to clear the parent table             
+                ds.Tables[0].Rows.Clear(); //Try to clear the parent table
             });
         }
 
index 6cc363d..729dac7 100644 (file)
@@ -2228,17 +2228,17 @@ namespace System.Data.Tests
             // Item - columnn,Current
             Assert.Equal(1, (int)myRow[dc, DataRowVersion.Current]);
 
-            // testMore();
+            //  testMore();
         }
 
         /*public void testMore()
-               {
-                       DataTable dt = DataProvider.CreateParentDataTable();
-                       dt.Rows[0].BeginEdit();
-                       dt.Rows[0][0] = 10;
-                       dt.Rows[0].EndEdit();
-                       dt.AcceptChanges();
-               }*/
+        {
+            DataTable dt = DataProvider.CreateParentDataTable();
+            dt.Rows[0].BeginEdit();
+            dt.Rows[0][0] = 10;
+            dt.Rows[0].EndEdit();
+            dt.AcceptChanges();
+        }*/
 
         [Fact]
         public void RejectChanges()
index 885a9b4..7f06534 100644 (file)
@@ -66,13 +66,13 @@ namespace System.Data.Tests
    <child_after_significant_space />
 </root>";
         // This is useless ... since xml:space becomes a DataColumn here.
-        //             string xml12 = "<root xml:space='preserve'>     </root>";
+        //        string xml12 = "<root xml:space='preserve'>     </root>";
         // The result is silly under MS.NET. It never ignores comment, so
         // They differ:
         //   1) <root>simple string.</root>
         //   2) <root>simple <!-- comment -->string.</root>
         // The same applies to PI.
-        //             string xml13 = "<root><tab><col>test <!-- out --> comment</col></tab></root>";
+        //        string xml13 = "<root><tab><col>test <!-- out --> comment</col></tab></root>";
 
         // simple namespace/prefix support
         private string _xml14 = "<p:root xmlns:p='urn:foo'>test string</p:root>";
index 3c60245..5f6c647 100644 (file)
@@ -67,47 +67,47 @@ namespace System.Data.Tests
             // (regardless of its schema type), the elements will
             // never be treated as a DataSet.
             string xsbase = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' id='hoge'>
-       <xs:element name='Root'> <!-- When simple, it becomes table. When complex, it becomes DataSet -->
-               <xs:complexType>
-                       <xs:choice>
-                               {0}
-                       </xs:choice>
-               </xs:complexType>
-       </xs:element>
+    <xs:element name='Root'> <!-- When simple, it becomes table. When complex, it becomes DataSet -->
+        <xs:complexType>
+            <xs:choice>
+                {0}
+            </xs:choice>
+        </xs:complexType>
+    </xs:element>
 </xs:schema>";
 
             string xsbase2 = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' id='hoge'>
-       <xs:element name='Root'> <!-- When simple, it becomes table. When complex, it becomes DataSet -->
-               <xs:complexType>
-                       <xs:choice>
-                               {0}
-                       </xs:choice>
-               </xs:complexType>
-       </xs:element>
-       <xs:element name='more' type='xs:string' />
+    <xs:element name='Root'> <!-- When simple, it becomes table. When complex, it becomes DataSet -->
+        <xs:complexType>
+            <xs:choice>
+                {0}
+            </xs:choice>
+        </xs:complexType>
+    </xs:element>
+    <xs:element name='more' type='xs:string' />
 </xs:schema>";
 
             string simple = "<xs:element name='Child' type='xs:string' />";
             string complex = @"<xs:element name='Child'>
-       <xs:complexType>
-               <xs:attribute name='a1' />
-               <xs:attribute name='a2' type='xs:integer' />
-       </xs:complexType>
+    <xs:complexType>
+        <xs:attribute name='a1' />
+        <xs:attribute name='a2' type='xs:integer' />
+    </xs:complexType>
 </xs:element>";
             string elref = "<xs:element ref='more' />";
 
             string xs2 = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' id='hoge'>
-       <xs:element name='Root' type='RootType' />
-       <xs:complexType name='RootType'>
-               <xs:choice>
-                       <xs:element name='Child'>
-                               <xs:complexType>
-                                       <xs:attribute name='a1' />
-                                       <xs:attribute name='a2' type='xs:integer' />
-                               </xs:complexType>
-                       </xs:element>
-               </xs:choice>
-       </xs:complexType>
+    <xs:element name='Root' type='RootType' />
+    <xs:complexType name='RootType'>
+        <xs:choice>
+            <xs:element name='Child'>
+                <xs:complexType>
+                    <xs:attribute name='a1' />
+                    <xs:attribute name='a2' type='xs:integer' />
+                </xs:complexType>
+            </xs:element>
+        </xs:choice>
+    </xs:complexType>
 </xs:schema>";
 
             var ds = new DataSet();
@@ -154,19 +154,19 @@ namespace System.Data.Tests
         {
             string schema = @"<?xml version='1.0'?>
 <xsd:schema xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
-       <xsd:attribute name='foo' type='xsd:string'/>
-       <xsd:attribute name='bar' type='xsd:string'/>
-       <xsd:complexType name='attRef'>
-               <xsd:attribute name='att1' type='xsd:int'/>
-               <xsd:attribute name='att2' type='xsd:string'/>
-       </xsd:complexType>
-       <xsd:element name='doc'>
-               <xsd:complexType>
-                       <xsd:choice>
-                               <xsd:element name='elem' type='attRef'/>
-                       </xsd:choice>
-               </xsd:complexType>
-       </xsd:element>
+    <xsd:attribute name='foo' type='xsd:string'/>
+    <xsd:attribute name='bar' type='xsd:string'/>
+    <xsd:complexType name='attRef'>
+        <xsd:attribute name='att1' type='xsd:int'/>
+        <xsd:attribute name='att2' type='xsd:string'/>
+    </xsd:complexType>
+    <xsd:element name='doc'>
+        <xsd:complexType>
+            <xsd:choice>
+                <xsd:element name='elem' type='attRef'/>
+            </xsd:choice>
+        </xsd:complexType>
+    </xsd:element>
 </xsd:schema>";
             var ds = new DataSet();
             ds.ReadXmlSchema(new StringReader(schema));
@@ -178,18 +178,18 @@ namespace System.Data.Tests
         public void UnusedComplexTypesIgnored()
         {
             string xs = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' id='hoge'>
-       <xs:element name='Root'>
-               <xs:complexType>
-                       <xs:sequence>
-                               <xs:element name='Child' type='xs:string' />
-                       </xs:sequence>
-               </xs:complexType>
-       </xs:element>
-       <xs:complexType name='unusedType'>
-               <xs:sequence>
-                       <xs:element name='Orphan' type='xs:string' />
-               </xs:sequence>
-       </xs:complexType>
+    <xs:element name='Root'>
+        <xs:complexType>
+            <xs:sequence>
+                <xs:element name='Child' type='xs:string' />
+            </xs:sequence>
+        </xs:complexType>
+    </xs:element>
+    <xs:complexType name='unusedType'>
+        <xs:sequence>
+            <xs:element name='Orphan' type='xs:string' />
+        </xs:sequence>
+    </xs:complexType>
 </xs:schema>";
 
             var ds = new DataSet();
@@ -203,8 +203,8 @@ namespace System.Data.Tests
         public void SimpleTypeComponentsIgnored()
         {
             string xs = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema'>
-       <xs:element name='Root' type='xs:string'/>
-       <xs:attribute name='Attr' type='xs:string'/>
+    <xs:element name='Root' type='xs:string'/>
+    <xs:attribute name='Attr' type='xs:string'/>
 </xs:schema>";
 
             var ds = new DataSet();
@@ -217,13 +217,13 @@ namespace System.Data.Tests
         public void IsDataSetAndTypeIgnored()
         {
             string xsbase = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' xmlns:msdata='urn:schemas-microsoft-com:xml-msdata'>
-       <xs:element name='Root' type='unusedType' msdata:IsDataSet='{0}'>
-       </xs:element>
-       <xs:complexType name='unusedType'>
-               <xs:sequence>
-                       <xs:element name='Child' type='xs:string' />
-               </xs:sequence>
-       </xs:complexType>
+    <xs:element name='Root' type='unusedType' msdata:IsDataSet='{0}'>
+    </xs:element>
+    <xs:complexType name='unusedType'>
+        <xs:sequence>
+            <xs:element name='Child' type='xs:string' />
+        </xs:sequence>
+    </xs:complexType>
 </xs:schema>";
 
             // Even if a global element uses a complexType, it will be
@@ -247,20 +247,20 @@ namespace System.Data.Tests
         public void NestedReferenceNotAllowed()
         {
             string xs = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' xmlns:msdata='urn:schemas-microsoft-com:xml-msdata'>
-       <xs:element name='Root' type='unusedType' msdata:IsDataSet='true'>
-       </xs:element>
-       <xs:complexType name='unusedType'>
-               <xs:sequence>
-                       <xs:element name='Child' type='xs:string' />
-               </xs:sequence>
-       </xs:complexType>
-       <xs:element name='Foo'>
-               <xs:complexType>
-                       <xs:sequence>
-                               <xs:element ref='Root' />
-                       </xs:sequence>
-               </xs:complexType>
-       </xs:element>
+    <xs:element name='Root' type='unusedType' msdata:IsDataSet='true'>
+    </xs:element>
+    <xs:complexType name='unusedType'>
+        <xs:sequence>
+            <xs:element name='Child' type='xs:string' />
+        </xs:sequence>
+    </xs:complexType>
+    <xs:element name='Foo'>
+        <xs:complexType>
+            <xs:sequence>
+                <xs:element ref='Root' />
+            </xs:sequence>
+        </xs:complexType>
+    </xs:element>
 </xs:schema>";
 
             // DataSet element cannot be converted into a DataTable.
@@ -276,13 +276,13 @@ namespace System.Data.Tests
         public void IsDataSetOnLocalElementIgnored()
         {
             string xsbase = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' xmlns:msdata='urn:schemas-microsoft-com:xml-msdata'>
-       <xs:element name='Root' type='unusedType'>
-       </xs:element>
-       <xs:complexType name='unusedType'>
-               <xs:sequence>
-                       <xs:element name='Child' type='xs:string' msdata:IsDataSet='True' />
-               </xs:sequence>
-       </xs:complexType>
+    <xs:element name='Root' type='unusedType'>
+    </xs:element>
+    <xs:complexType name='unusedType'>
+        <xs:sequence>
+            <xs:element name='Child' type='xs:string' msdata:IsDataSet='True' />
+        </xs:sequence>
+    </xs:complexType>
 </xs:schema>";
 
             // msdata:IsDataSet does not affect even if the value is invalid
@@ -301,14 +301,14 @@ namespace System.Data.Tests
             {
                 CultureInfo.CurrentCulture = new CultureInfo("fi-FI");
                 string xs = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' xmlns:msdata='urn:schemas-microsoft-com:xml-msdata'>
-       <xs:element name='Root' msdata:Locale='ja-JP'>
-               <xs:complexType>
-                       <xs:sequence>
-                               <xs:element name='Child' type='xs:string' />
-                       </xs:sequence>
-                       <xs:attribute name='Attr' type='xs:integer' />
-               </xs:complexType>
-       </xs:element>
+    <xs:element name='Root' msdata:Locale='ja-JP'>
+        <xs:complexType>
+            <xs:sequence>
+                <xs:element name='Child' type='xs:string' />
+            </xs:sequence>
+            <xs:attribute name='Attr' type='xs:integer' />
+        </xs:complexType>
+    </xs:element>
 </xs:schema>";
 
                 var ds = new DataSet();
@@ -330,38 +330,38 @@ namespace System.Data.Tests
         public void ElementHasIdentityConstraint()
         {
             string constraints = @"
-               <xs:key name='key'>
-                       <xs:selector xpath='./any/string_is_OK/R1'/>
-                       <xs:field xpath='Child2'/>
-               </xs:key>
-               <xs:keyref name='kref' refer='key'>
-                       <xs:selector xpath='.//R2'/>
-                       <xs:field xpath='Child2'/>
-               </xs:keyref>";
+        <xs:key name='key'>
+            <xs:selector xpath='./any/string_is_OK/R1'/>
+            <xs:field xpath='Child2'/>
+        </xs:key>
+        <xs:keyref name='kref' refer='key'>
+            <xs:selector xpath='.//R2'/>
+            <xs:field xpath='Child2'/>
+        </xs:keyref>";
             string xsbase = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' xmlns:msdata='urn:schemas-microsoft-com:xml-msdata'>
-       <xs:element name='DS' msdata:IsDataSet='true'>
-               <xs:complexType>
-                       <xs:choice>
-                               <xs:element ref='R1' />
-                               <xs:element ref='R2' />
-                       </xs:choice>
-               </xs:complexType>
-               {0}
-       </xs:element>
-       <xs:element name='R1' type='RootType'>
-             {1}
-       </xs:element>
-       <xs:element name='R2' type='RootType'>
-       </xs:element>
-       <xs:complexType name='RootType'>
-               <xs:choice>
-                       <xs:element name='Child1' type='xs:string'>
-                               {2}
-                       </xs:element>
-                       <xs:element name='Child2' type='xs:string' />
-               </xs:choice>
-               <xs:attribute name='Attr' type='xs:integer' />
-       </xs:complexType>
+    <xs:element name='DS' msdata:IsDataSet='true'>
+        <xs:complexType>
+            <xs:choice>
+                <xs:element ref='R1' />
+                <xs:element ref='R2' />
+            </xs:choice>
+        </xs:complexType>
+        {0}
+    </xs:element>
+    <xs:element name='R1' type='RootType'>
+          {1}
+    </xs:element>
+    <xs:element name='R2' type='RootType'>
+    </xs:element>
+    <xs:complexType name='RootType'>
+        <xs:choice>
+            <xs:element name='Child1' type='xs:string'>
+                {2}
+            </xs:element>
+            <xs:element name='Child2' type='xs:string' />
+        </xs:choice>
+        <xs:attribute name='Attr' type='xs:integer' />
+    </xs:complexType>
 </xs:schema>";
 
             // Constraints on DataSet element.
@@ -388,49 +388,49 @@ namespace System.Data.Tests
         public void PrefixedTargetNS()
         {
             string xs = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' xmlns:msdata='urn:schemas-microsoft-com:xml-msdata' xmlns:x='urn:foo' targetNamespace='urn:foo' elementFormDefault='qualified'>
-       <xs:element name='DS' msdata:IsDataSet='true'>
-               <xs:complexType>
-                       <xs:choice>
-                               <xs:element ref='x:R1' />
-                               <xs:element ref='x:R2' />
-                       </xs:choice>
-               </xs:complexType>
-               <xs:key name='key'>
-                       <xs:selector xpath='./any/string_is_OK/x:R1'/>
-                       <xs:field xpath='x:Child2'/>
-               </xs:key>
-               <xs:keyref name='kref' refer='x:key'>
-                       <xs:selector xpath='.//x:R2'/>
-                       <xs:field xpath='x:Child2'/>
-               </xs:keyref>
-       </xs:element>
-       <xs:element name='R3' type='x:RootType' />
-       <xs:complexType name='extracted'>
-               <xs:choice>
-                       <xs:element ref='x:R1' />
-                       <xs:element ref='x:R2' />
-               </xs:choice>
-       </xs:complexType>
-       <xs:element name='R1' type='x:RootType'>
-               <xs:unique name='Rkey'>
-                       <xs:selector xpath='.//x:Child1'/>
-                       <xs:field xpath='.'/>
-               </xs:unique>
-               <xs:keyref name='Rkref' refer='x:Rkey'>
-                       <xs:selector xpath='.//x:Child2'/>
-                       <xs:field xpath='.'/>
-               </xs:keyref>
-       </xs:element>
-       <xs:element name='R2' type='x:RootType'>
-       </xs:element>
-       <xs:complexType name='RootType'>
-               <xs:choice>
-                       <xs:element name='Child1' type='xs:string'>
-                       </xs:element>
-                       <xs:element name='Child2' type='xs:string' />
-               </xs:choice>
-               <xs:attribute name='Attr' type='xs:integer' />
-       </xs:complexType>
+    <xs:element name='DS' msdata:IsDataSet='true'>
+        <xs:complexType>
+            <xs:choice>
+                <xs:element ref='x:R1' />
+                <xs:element ref='x:R2' />
+            </xs:choice>
+        </xs:complexType>
+        <xs:key name='key'>
+            <xs:selector xpath='./any/string_is_OK/x:R1'/>
+            <xs:field xpath='x:Child2'/>
+        </xs:key>
+        <xs:keyref name='kref' refer='x:key'>
+            <xs:selector xpath='.//x:R2'/>
+            <xs:field xpath='x:Child2'/>
+        </xs:keyref>
+    </xs:element>
+    <xs:element name='R3' type='x:RootType' />
+    <xs:complexType name='extracted'>
+        <xs:choice>
+            <xs:element ref='x:R1' />
+            <xs:element ref='x:R2' />
+        </xs:choice>
+    </xs:complexType>
+    <xs:element name='R1' type='x:RootType'>
+        <xs:unique name='Rkey'>
+            <xs:selector xpath='.//x:Child1'/>
+            <xs:field xpath='.'/>
+        </xs:unique>
+        <xs:keyref name='Rkref' refer='x:Rkey'>
+            <xs:selector xpath='.//x:Child2'/>
+            <xs:field xpath='.'/>
+        </xs:keyref>
+    </xs:element>
+    <xs:element name='R2' type='x:RootType'>
+    </xs:element>
+    <xs:complexType name='RootType'>
+        <xs:choice>
+            <xs:element name='Child1' type='xs:string'>
+            </xs:element>
+            <xs:element name='Child2' type='xs:string' />
+        </xs:choice>
+        <xs:attribute name='Attr' type='xs:integer' />
+    </xs:complexType>
 </xs:schema>";
             // No prefixes on tables and columns
             var ds = new DataSet();
@@ -618,21 +618,21 @@ namespace System.Data.Tests
             ds.ReadXmlSchema(new StringReader(
                 @"<!-- Modified w3ctests attQ014.xsd -->
                 <xsd:schema xmlns:xsd=""http://www.w3.org/2001/XMLSchema"" targetNamespace=""http://xsdtesting"" xmlns:x=""http://xsdtesting"">
-                       <xsd:element name=""root"">
-                               <xsd:complexType>
-                                       <xsd:sequence>
-                                               <xsd:element name=""e"">
-                                                       <xsd:complexType>
-                                                               <xsd:simpleContent>
-                                                                       <xsd:extension base=""xsd:decimal"">
-                                                                               <xsd:attribute name=""a"" type=""xsd:string""/>
-                                                                       </xsd:extension>
-                                                               </xsd:simpleContent>
-                                                       </xsd:complexType>
-                                               </xsd:element>
-                                       </xsd:sequence>
-                               </xsd:complexType>
-                       </xsd:element>
+                    <xsd:element name=""root"">
+                        <xsd:complexType>
+                            <xsd:sequence>
+                                <xsd:element name=""e"">
+                                    <xsd:complexType>
+                                        <xsd:simpleContent>
+                                            <xsd:extension base=""xsd:decimal"">
+                                                <xsd:attribute name=""a"" type=""xsd:string""/>
+                                            </xsd:extension>
+                                        </xsd:simpleContent>
+                                    </xsd:complexType>
+                                </xsd:element>
+                            </xsd:sequence>
+                        </xsd:complexType>
+                    </xsd:element>
                 </xsd:schema>"));
             DataSetAssertion.AssertDataSet("013", ds, "root", 1, 0);
 
@@ -649,38 +649,38 @@ namespace System.Data.Tests
             ds.ReadXmlSchema(new StringReader(
                 @"<?xml version=""1.0"" encoding=""utf-8"" ?>
                     <xs:schema targetNamespace=""http://neurosaudio.com/Tracks.xsd"" xmlns=""http://neurosaudio.com/Tracks.xsd"" xmlns:mstns=""http://neurosaudio.com/Tracks.xsd"" xmlns:xs=""http://www.w3.org/2001/XMLSchema"" xmlns:msdata=""urn:schemas-microsoft-com:xml-msdata"" elementFormDefault=""qualified"" id=""Tracks"">
-                           <xs:element name=""Tracks"">
-                                   <xs:complexType>
-                                           <xs:sequence>
-                                                   <xs:element name=""Track"" minOccurs=""0"" maxOccurs=""unbounded"">
-                                                           <xs:complexType>
-                                                                   <xs:sequence>
-                                                                           <xs:element name=""Title"" type=""xs:string"" />
-                                                                           <xs:element name=""Artist"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""Album"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""Performer"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""Sequence"" type=""xs:unsignedInt"" minOccurs=""0"" />
-                                                                           <xs:element name=""Genre"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""Comment"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""Year"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""Duration"" type=""xs:unsignedInt"" minOccurs=""0"" />
-                                                                           <xs:element name=""Path"" type=""xs:string"" />
-                                                                           <xs:element name=""DevicePath"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""FileSize"" type=""xs:unsignedInt"" minOccurs=""0"" />
-                                                                           <xs:element name=""Source"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""FlashStatus"" type=""xs:unsignedInt"" />
-                                                                           <xs:element name=""HDStatus"" type=""xs:unsignedInt"" />
-                                                                   </xs:sequence>
-                                                                   <xs:attribute name=""ID"" type=""xs:unsignedInt"" msdata:AutoIncrement=""true"" msdata:AutoIncrementSeed=""1"" />
-                                                           </xs:complexType>
-                                                   </xs:element>
-                                           </xs:sequence>
-                                   </xs:complexType>
-                                   <xs:key name=""TrackPK"" msdata:PrimaryKey=""true"">
-                                           <xs:selector xpath="".//mstns:Track"" />
-                                           <xs:field xpath=""@ID"" />
-                                   </xs:key>
-                           </xs:element>
+                        <xs:element name=""Tracks"">
+                            <xs:complexType>
+                                <xs:sequence>
+                                    <xs:element name=""Track"" minOccurs=""0"" maxOccurs=""unbounded"">
+                                        <xs:complexType>
+                                            <xs:sequence>
+                                                <xs:element name=""Title"" type=""xs:string"" />
+                                                <xs:element name=""Artist"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""Album"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""Performer"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""Sequence"" type=""xs:unsignedInt"" minOccurs=""0"" />
+                                                <xs:element name=""Genre"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""Comment"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""Year"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""Duration"" type=""xs:unsignedInt"" minOccurs=""0"" />
+                                                <xs:element name=""Path"" type=""xs:string"" />
+                                                <xs:element name=""DevicePath"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""FileSize"" type=""xs:unsignedInt"" minOccurs=""0"" />
+                                                <xs:element name=""Source"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""FlashStatus"" type=""xs:unsignedInt"" />
+                                                <xs:element name=""HDStatus"" type=""xs:unsignedInt"" />
+                                            </xs:sequence>
+                                            <xs:attribute name=""ID"" type=""xs:unsignedInt"" msdata:AutoIncrement=""true"" msdata:AutoIncrementSeed=""1"" />
+                                        </xs:complexType>
+                                    </xs:element>
+                                </xs:sequence>
+                            </xs:complexType>
+                            <xs:key name=""TrackPK"" msdata:PrimaryKey=""true"">
+                                <xs:selector xpath="".//mstns:Track"" />
+                                <xs:field xpath=""@ID"" />
+                            </xs:key>
+                        </xs:element>
                     </xs:schema>"));
         }
 
@@ -796,9 +796,9 @@ namespace System.Data.Tests
                   <xs:element name='Foo' type='FooType' />
                   <!-- defining externally to avoid being regarded as dataset element -->
                   <xs:complexType name='FooType'>
-                       <xs:sequence>
-                               <xs:element name='Bar' maxOccurs='2' />
-                       </xs:sequence>
+                    <xs:sequence>
+                        <xs:element name='Bar' maxOccurs='2' />
+                    </xs:sequence>
                   </xs:complexType>
                 </xs:schema>"));
             DataSetAssertion.AssertDataSet("012", ds, "NewDataSet", 2, 1);
@@ -820,15 +820,15 @@ namespace System.Data.Tests
             var ds = new DataSet();
             ds.ReadXmlSchema(new StringReader(
                 @"<xsd:schema xmlns:xsd=""http://www.w3.org/2001/XMLSchema"">
-                       <xsd:element name=""root"">
-                               <xsd:complexType>
-                                       <xsd:sequence>
-                                               <xsd:element name=""x"" maxOccurs=""2"" />
-                                               <xsd:element ref=""y"" maxOccurs=""unbounded"" />
-                                       </xsd:sequence>
-                               </xsd:complexType>
-                       </xsd:element>
-                       <xsd:element name=""y"" />
+                    <xsd:element name=""root"">
+                        <xsd:complexType>
+                            <xsd:sequence>
+                                <xsd:element name=""x"" maxOccurs=""2"" />
+                                <xsd:element ref=""y"" maxOccurs=""unbounded"" />
+                            </xsd:sequence>
+                        </xsd:complexType>
+                    </xsd:element>
+                    <xsd:element name=""y"" />
                 </xsd:schema>"));
             DataSetAssertion.AssertDataSet("014", ds, "NewDataSet", 3, 2);
 
index 1bcd368..49d8312 100644 (file)
@@ -55,13 +55,13 @@ namespace System.Data.Tests
         private const string diff2 = diff1 + xml8;
 
         private const string schema1 = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema'>
-       <xs:element name='Root'>
-               <xs:complexType>
-                       <xs:sequence>
-                               <xs:element name='Child' type='xs:string' />
-                       </xs:sequence>
-               </xs:complexType>
-       </xs:element>
+    <xs:element name='Root'>
+        <xs:complexType>
+            <xs:sequence>
+                <xs:element name='Child' type='xs:string' />
+            </xs:sequence>
+        </xs:complexType>
+    </xs:element>
 </xs:schema>";
         private const string schema2 = schema1 + xml8;
 
@@ -643,13 +643,13 @@ namespace System.Data.Tests
         public void NameConflictDSAndTable()
         {
             string xml = @"<PriceListDetails> 
-       <PriceListList>    
-               <Id>1</Id>
-       </PriceListList>
-       <PriceListDetails> 
-               <Id>1</Id>
-               <Status>0</Status>
-       </PriceListDetails>
+    <PriceListList>    
+        <Id>1</Id>
+    </PriceListList>
+    <PriceListDetails> 
+        <Id>1</Id>
+        <Status>0</Status>
+    </PriceListDetails>
 </PriceListDetails>";
 
             var ds = new DataSet();
index 1bfae11..d1ca7e3 100644 (file)
@@ -179,7 +179,7 @@ namespace System.Data.Tests
             ds.WriteXmlSchema(writer);
 
             string TextString = DataSetAssertion.GetNormalizedSchema(writer.ToString());
-            //                 string TextString = writer.ToString ();
+            //            string TextString = writer.ToString ();
 
             string substring = TextString.Substring(0, TextString.IndexOfAny(new[] { '\r', '\n' }));
             TextString = TextString.Substring(TextString.IndexOf('\n') + 1);
@@ -188,13 +188,13 @@ namespace System.Data.Tests
             substring = TextString.Substring(0, TextString.IndexOfAny(new[] { '\r', '\n' }));
             TextString = TextString.Substring(TextString.IndexOf('\n') + 1);
             // This is original DataSet.WriteXmlSchema() output
-            //                 Assert.Equal ("<xs:schema id=\"test_dataset\" xmlns=\"\" xmlns:xs=\"http://www.w3.org/2001/XMLSchema\" xmlns:msdata=\"urn:schemas-microsoft-com:xml-msdata\">", substring);
+            //            Assert.Equal ("<xs:schema id=\"test_dataset\" xmlns=\"\" xmlns:xs=\"http://www.w3.org/2001/XMLSchema\" xmlns:msdata=\"urn:schemas-microsoft-com:xml-msdata\">", substring);
             Assert.Equal("<xs:schema id=\"test_dataset\" xmlns:msdata=\"urn:schemas-microsoft-com:xml-msdata\" xmlns:xs=\"http://www.w3.org/2001/XMLSchema\">", substring);
 
             substring = TextString.Substring(0, TextString.IndexOfAny(new[] { '\r', '\n' }));
             TextString = TextString.Substring(TextString.IndexOf('\n') + 1);
             // This is original DataSet.WriteXmlSchema() output
-            //                 Assert.Equal ("  <xs:element name=\"test_dataset\" msdata:IsDataSet=\"true\" msdata:Locale=\"fi-FI\">", substring);
+            //            Assert.Equal ("  <xs:element name=\"test_dataset\" msdata:IsDataSet=\"true\" msdata:Locale=\"fi-FI\">", substring);
             Assert.Equal("  <xs:element msdata:IsDataSet=\"true\" msdata:UseCurrentLocale=\"true\" name=\"test_dataset\">", substring);
 
             substring = TextString.Substring(0, TextString.IndexOfAny(new[] { '\r', '\n' }));
@@ -220,7 +220,7 @@ namespace System.Data.Tests
             substring = TextString.Substring(0, TextString.IndexOfAny(new[] { '\r', '\n' }));
             TextString = TextString.Substring(TextString.IndexOf('\n') + 1);
             // This is original DataSet.WriteXmlSchema() output
-            //                 Assert.Equal ("              <xs:element name=\"first\" msdata:Caption=\"test\" default=\"test_default_value\" minOccurs=\"0\">", substring);
+            //            Assert.Equal ("              <xs:element name=\"first\" msdata:Caption=\"test\" default=\"test_default_value\" minOccurs=\"0\">", substring);
             Assert.Equal("              <xs:element default=\"test_default_value\" minOccurs=\"0\" msdata:Caption=\"test\" name=\"first\">", substring);
 
             substring = TextString.Substring(0, TextString.IndexOfAny(new[] { '\r', '\n' }));
@@ -279,7 +279,7 @@ namespace System.Data.Tests
             substring = TextString.Substring(0, TextString.IndexOfAny(new[] { '\r', '\n' }));
             TextString = TextString.Substring(TextString.IndexOf('\n') + 1);
             // This is original DataSet.WriteXmlSchema() output
-            //                 Assert.Equal ("              <xs:element name=\"second_first\" default=\"default_value\" minOccurs=\"0\">", substring);
+            //            Assert.Equal ("              <xs:element name=\"second_first\" default=\"default_value\" minOccurs=\"0\">", substring);
             Assert.Equal("              <xs:element default=\"default_value\" minOccurs=\"0\" name=\"second_first\">", substring);
 
             substring = TextString.Substring(0, TextString.IndexOfAny(new[] { '\r', '\n' }));
@@ -345,7 +345,7 @@ namespace System.Data.Tests
             substring = TextString.Substring(0, TextString.IndexOfAny(new[] { '\r', '\n' }));
             TextString = TextString.Substring(TextString.IndexOf('\n') + 1);
             // This is original DataSet.WriteXmlSchema() output
-            //                 Assert.Equal ("    <xs:unique name=\"second_test_table_Constraint1\" msdata:ConstraintName=\"Constraint1\">", substring);
+            //            Assert.Equal ("    <xs:unique name=\"second_test_table_Constraint1\" msdata:ConstraintName=\"Constraint1\">", substring);
             Assert.Equal("    <xs:unique msdata:ConstraintName=\"Constraint1\" name=\"second_test_table_Constraint1\">", substring);
 
             substring = TextString.Substring(0, TextString.IndexOfAny(new[] { '\r', '\n' }));
@@ -744,36 +744,36 @@ namespace System.Data.Tests
         }
 
         /* To be added
-               [Fact]
-               public void WriteDiffReadAutoWriteSchema ()
-               {
-                       DataSet ds = new DataSet ();
-                       ds.Tables.Add ("Table1");
-                       ds.Tables.Add ("Table2");
-                       ds.Tables [0].Columns.Add ("Column1_1");
-                       ds.Tables [0].Columns.Add ("Column1_2");
-                       ds.Tables [0].Columns.Add ("Column1_3");
-                       ds.Tables [1].Columns.Add ("Column2_1");
-                       ds.Tables [1].Columns.Add ("Column2_2");
-                       ds.Tables [1].Columns.Add ("Column2_3");
-                       ds.Tables [0].Rows.Add (new object [] {"ppp", "www", "xxx"});
-
-                       // save as diffgram
-                       StringWriter sw = new StringWriter ();
-                       ds.WriteXml (sw, XmlWriteMode.DiffGram);
-                       string xml = sw.ToString ();
-                       string result = new StreamReader ("Test/System.Data/DataSetReadXmlTest1.xml", Encoding.ASCII).ReadToEnd ();
-                       Assert.Equal (result, xml);
-
-                       // load diffgram above
-                       ds.ReadXml (new StringReader (sw.ToString ()));
-                       sw = new StringWriter ();
-                       ds.WriteXml (sw, XmlWriteMode.WriteSchema);
-                       xml = sw.ToString ();
-                       result = new StreamReader ("Test/System.Data/DataSetReadXmlTest2.xml", Encoding.ASCII).ReadToEnd ();
-                       Assert.Equal (result, xml);
-               }
-               */
+        [Fact]
+        public void WriteDiffReadAutoWriteSchema ()
+        {
+            DataSet ds = new DataSet ();
+            ds.Tables.Add ("Table1");
+            ds.Tables.Add ("Table2");
+            ds.Tables [0].Columns.Add ("Column1_1");
+            ds.Tables [0].Columns.Add ("Column1_2");
+            ds.Tables [0].Columns.Add ("Column1_3");
+            ds.Tables [1].Columns.Add ("Column2_1");
+            ds.Tables [1].Columns.Add ("Column2_2");
+            ds.Tables [1].Columns.Add ("Column2_3");
+            ds.Tables [0].Rows.Add (new object [] {"ppp", "www", "xxx"});
+
+            // save as diffgram
+            StringWriter sw = new StringWriter ();
+            ds.WriteXml (sw, XmlWriteMode.DiffGram);
+            string xml = sw.ToString ();
+            string result = new StreamReader ("Test/System.Data/DataSetReadXmlTest1.xml", Encoding.ASCII).ReadToEnd ();
+            Assert.Equal (result, xml);
+
+            // load diffgram above
+            ds.ReadXml (new StringReader (sw.ToString ()));
+            sw = new StringWriter ();
+            ds.WriteXml (sw, XmlWriteMode.WriteSchema);
+            xml = sw.ToString ();
+            result = new StreamReader ("Test/System.Data/DataSetReadXmlTest2.xml", Encoding.ASCII).ReadToEnd ();
+            Assert.Equal (result, xml);
+        }
+        */
 
         [Fact]
         public void CloneCopy()
index d1fe158..d1f5385 100644 (file)
@@ -278,7 +278,7 @@ namespace System.Data.Tests
             {
                 // Never premise English.
                 //Assert.Equal ("Failed to enable constraints. One or more rows contain values " + 
-                //             "violating non-null, unique, or foreign-key constraints.", e.Message, "#2");
+                //        "violating non-null, unique, or foreign-key constraints.", e.Message, "#2");
             }
         }
 
@@ -301,7 +301,7 @@ namespace System.Data.Tests
             {
                 // Never premise English.
                 //Assert.Equal ("Failed to enable constraints. One or more rows contain values " + 
-                //             "violating non-null, unique, or foreign-key constraints.", e.Message, "#2");
+                //        "violating non-null, unique, or foreign-key constraints.", e.Message, "#2");
             }
         }
 
@@ -341,10 +341,10 @@ namespace System.Data.Tests
             //make some changes
 
             // can't check detached
-            //         dr = ds.Tables[0].Rows[0];
-            //         arrDetached = dr.ItemArray;
-            //         dr.Delete();
-            //         ds.Tables[0].AcceptChanges();
+            //        dr = ds.Tables[0].Rows[0];
+            //        arrDetached = dr.ItemArray;
+            //        dr.Delete();
+            //        ds.Tables[0].AcceptChanges();
 
             dr = ds.Tables[0].Rows[1];
             arrDeleted = dr.ItemArray;
@@ -370,11 +370,11 @@ namespace System.Data.Tests
             object[] tmp = new object[] { dr[0, DataRowVersion.Original], dr[1, DataRowVersion.Original], dr[2, DataRowVersion.Original], dr[3, DataRowVersion.Original], dr[4, DataRowVersion.Original], dr[5, DataRowVersion.Original] };
             Assert.Equal(arrDeleted, tmp);
 
-            // can't check it  
-            //         // GetChanges Detached
-            //         dr = ds.GetChanges(DataRowState.Detached).Tables[0].Rows[0];
-            //         object[] tmp = new object[] {dr[0,DataRowVersion.Original],dr[1,DataRowVersion.Original],dr[2,DataRowVersion.Original]};
-            //         Assert.Equal(arrDetached, tmp);
+            //    can't check it    
+            //        // GetChanges Detached
+            //        dr = ds.GetChanges(DataRowState.Detached).Tables[0].Rows[0];
+            //        object[] tmp = new object[] {dr[0,DataRowVersion.Original],dr[1,DataRowVersion.Original],dr[2,DataRowVersion.Original]};
+            //        Assert.Equal(arrDetached, tmp);
 
             // GetChanges Modified
             Assert.Equal(arrModified, ds.GetChanges(DataRowState.Modified).Tables[0].Rows[0].ItemArray);
@@ -577,7 +577,7 @@ namespace System.Data.Tests
             MemoryStream myStream = new MemoryStream(new ASCIIEncoding().GetBytes(sb.ToString()));
 
             var ds = new DataSet();
-            // ds.ReadXml(myStream);
+            //    ds.ReadXml(myStream);
             ds.InferXmlSchema(myStream, new string[] { "urn:schemas-microsoft-com:officedata" });
             Assert.Equal(2, ds.Tables.Count);
             Assert.Equal("CategoryID", ds.Tables[0].Columns[0].ColumnName);
@@ -634,7 +634,7 @@ namespace System.Data.Tests
             MemoryStream myStream = new MemoryStream(new ASCIIEncoding().GetBytes(sb.ToString()));
 
             var ds = new DataSet();
-            // ds.ReadXml(myStream);
+            //    ds.ReadXml(myStream);
             ds.InferXmlSchema(myStream, new string[] { "urn:schemas-microsoft-com:officedata" });
             Assert.Equal(3, ds.Tables.Count);
 
@@ -675,8 +675,8 @@ namespace System.Data.Tests
             ds.InferXmlSchema(myStream, new string[] { "http://www.xml.com/books", "http://www.w3.org/HTML/1998/html4" });
             //Assert.Equal(8, ds.Tables.Count);
 
-            //                 string str1 = tempDs.GetXmlSchema(); //DataProvider.GetDSSchema(tempDs);
-            //                 string str2 = ds.GetXmlSchema(); //DataProvider.GetDSSchema(ds);
+            //            string str1 = tempDs.GetXmlSchema(); //DataProvider.GetDSSchema(tempDs);
+            //            string str2 = ds.GetXmlSchema(); //DataProvider.GetDSSchema(ds);
             Assert.Equal(3, ds.Tables.Count);
             Assert.Equal("bookreview", ds.Tables[2].TableName);
             Assert.Equal(2, ds.Tables[2].Columns.Count);
@@ -1351,23 +1351,23 @@ namespace System.Data.Tests
             Assert.True(dsTarget1.Tables.Contains("NewTable"));
 
             //failed, should be success by MSDN Library documentation
-            //         // Merge MissingSchemaAction.Add - PrimaryKey
-            //         Assert.Equal(0, dsTarget1.Tables["NewTable"].PrimaryKey.Length);
+            //        // Merge MissingSchemaAction.Add - PrimaryKey
+            //        Assert.Equal(0, dsTarget1.Tables["NewTable"].PrimaryKey.Length);
             #endregion
 
             #region "ds,false,MissingSchemaAction.AddWithKey)"
             //MissingSchemaAction.Add,MissingSchemaAction.AddWithKey - behave the same, checked only Add
 
-            //         DataSet dsTarget2 = dsTarget.Copy();
-            //         dsTarget2.Merge(ds,false,MissingSchemaAction.AddWithKey);
-            //         // Merge MissingSchemaAction.AddWithKey - Column
-            //         Assert.True(dsTarget2.Tables["Table1"].Columns.Contains("NewColumn"));
+            //        DataSet dsTarget2 = dsTarget.Copy();
+            //        dsTarget2.Merge(ds,false,MissingSchemaAction.AddWithKey);
+            //        // Merge MissingSchemaAction.AddWithKey - Column
+            //        Assert.True(dsTarget2.Tables["Table1"].Columns.Contains("NewColumn"));
             //
-            //         // Merge MissingSchemaAction.AddWithKey - Table
-            //         Assert.True(dsTarget2.Tables.Contains("NewTable"));
+            //        // Merge MissingSchemaAction.AddWithKey - Table
+            //        Assert.True(dsTarget2.Tables.Contains("NewTable"));
             //
-            //         // Merge MissingSchemaAction.AddWithKey - PrimaryKey
-            //         Assert.Equal(dsTarget2.Tables["NewTable"].Columns["NewColumn1"], dsTarget2.Tables["NewTable"].PrimaryKey[0]);
+            //        // Merge MissingSchemaAction.AddWithKey - PrimaryKey
+            //        Assert.Equal(dsTarget2.Tables["NewTable"].Columns["NewColumn1"], dsTarget2.Tables["NewTable"].PrimaryKey[0]);
             #endregion
 
             #region "ds,false,MissingSchemaAction.Ignore )"
@@ -2206,19 +2206,19 @@ namespace System.Data.Tests
 
             input += "<?xml version=\"1.0\"?>";
             input += "<Stock name=\"MSFT\">";
-            input += "         <Company name=\"Microsoft Corp.\"/>";
-            input += "         <Price type=\"high\">";
-            input += "                 <Value>10.0</Value>";
-            input += "                 <Date>01/20/2000</Date>";
-            input += "         </Price>";
-            input += "         <Price type=\"low\">";
-            input += "                 <Value>1.0</Value>";
-            input += "                 <Date>03/21/2002</Date>";
-            input += "         </Price>";
-            input += "         <Price type=\"current\">";
-            input += "                 <Value>3.0</Value>";
-            input += "                 <Date>TODAY</Date>";
-            input += "         </Price>";
+            input += "        <Company name=\"Microsoft Corp.\"/>";
+            input += "        <Price type=\"high\">";
+            input += "            <Value>10.0</Value>";
+            input += "            <Date>01/20/2000</Date>";
+            input += "        </Price>";
+            input += "        <Price type=\"low\">";
+            input += "            <Value>1.0</Value>";
+            input += "            <Date>03/21/2002</Date>";
+            input += "        </Price>";
+            input += "        <Price type=\"current\">";
+            input += "            <Value>3.0</Value>";
+            input += "            <Date>TODAY</Date>";
+            input += "        </Price>";
             input += "</Stock>";
 
             sr = new StringReader(input);
@@ -2305,69 +2305,69 @@ namespace System.Data.Tests
 
             input += "<?xml version=\"1.0\"?>";
             input += "<Stocks>";
-            input += "         <Stock name=\"MSFT\">";
-            input += "                 <Company name=\"Microsoft Corp.\" />";
-            input += "                 <Company name=\"General Electric\"/>";
-            input += "                 <Price type=\"high\">";
-            input += "                         <Value>10.0</Value>";
-            input += "                         <Date>01/20/2000</Date>";
-            input += "                 </Price>";
-            input += "                 <Price type=\"low\">";
-            input += "                         <Value>1.0</Value>";
-            input += "                         <Date>03/21/2002</Date>";
-            input += "                 </Price>";
-            input += "                 <Price type=\"current\">";
-            input += "                         <Value>3.0</Value>";
-            input += "                         <Date>TODAY</Date>";
-            input += "                 </Price>";
-            input += "         </Stock>";
-            input += "         <Stock name=\"GE\">";
-            input += "                 <Company name=\"GE company\"/>";
-            input += "                 <Price type=\"high\">";
-            input += "                         <Value>22.23</Value>";
-            input += "                         <Date>02/12/2001</Date>";
-            input += "                 </Price>";
-            input += "                 <Price type=\"low\">";
-            input += "                         <Value>1.97</Value>";
-            input += "                         <Date>04/20/2003</Date>";
-            input += "                 </Price>";
-            input += "                 <Price type=\"current\">";
-            input += "                         <Value>3.0</Value>";
-            input += "                         <Date>TODAY</Date>";
-            input += "                 </Price>";
-            input += "         </Stock>";
-            input += "         <Stock name=\"Intel\">";
-            input += "                 <Company name=\"Intel Corp.\"/>";
-            input += "                 <Company name=\"Test1\" />";
-            input += "                 <Company name=\"Test2\"/>";
-            input += "                 <Price type=\"high\">";
-            input += "                         <Value>15.0</Value>";
-            input += "                         <Date>01/25/2000</Date>";
-            input += "                 </Price>";
-            input += "                 <Price type=\"low\">";
-            input += "                         <Value>1.0</Value>";
-            input += "                         <Date>03/23/2002</Date>";
-            input += "                 </Price>";
-            input += "                 <Price type=\"current\">";
-            input += "                         <Value>3.0</Value>";
-            input += "                         <Date>TODAY</Date>";
-            input += "                 </Price>";
-            input += "         </Stock>";
-            input += "         <Stock name=\"Mainsoft\">";
-            input += "                 <Company name=\"Mainsoft Corp.\"/>";
-            input += "                 <Price type=\"high\">";
-            input += "                         <Value>30.0</Value>";
-            input += "                         <Date>01/26/2000</Date>";
-            input += "                 </Price>";
-            input += "                 <Price type=\"low\">";
-            input += "                         <Value>1.0</Value>";
-            input += "                         <Date>03/26/2002</Date>";
-            input += "                 </Price>";
-            input += "                 <Price type=\"current\">";
-            input += "                         <Value>27.0</Value>";
-            input += "                         <Date>TODAY</Date>";
-            input += "                 </Price>";
-            input += "         </Stock>";
+            input += "        <Stock name=\"MSFT\">";
+            input += "            <Company name=\"Microsoft Corp.\" />";
+            input += "            <Company name=\"General Electric\"/>";
+            input += "            <Price type=\"high\">";
+            input += "                <Value>10.0</Value>";
+            input += "                <Date>01/20/2000</Date>";
+            input += "            </Price>";
+            input += "            <Price type=\"low\">";
+            input += "                <Value>1.0</Value>";
+            input += "                <Date>03/21/2002</Date>";
+            input += "            </Price>";
+            input += "            <Price type=\"current\">";
+            input += "                <Value>3.0</Value>";
+            input += "                <Date>TODAY</Date>";
+            input += "            </Price>";
+            input += "        </Stock>";
+            input += "        <Stock name=\"GE\">";
+            input += "            <Company name=\"GE company\"/>";
+            input += "            <Price type=\"high\">";
+            input += "                <Value>22.23</Value>";
+            input += "                <Date>02/12/2001</Date>";
+            input += "            </Price>";
+            input += "            <Price type=\"low\">";
+            input += "                <Value>1.97</Value>";
+            input += "                <Date>04/20/2003</Date>";
+            input += "            </Price>";
+            input += "            <Price type=\"current\">";
+            input += "                <Value>3.0</Value>";
+            input += "                <Date>TODAY</Date>";
+            input += "            </Price>";
+            input += "        </Stock>";
+            input += "        <Stock name=\"Intel\">";
+            input += "            <Company name=\"Intel Corp.\"/>";
+            input += "            <Company name=\"Test1\" />";
+            input += "            <Company name=\"Test2\"/>";
+            input += "            <Price type=\"high\">";
+            input += "                <Value>15.0</Value>";
+            input += "                <Date>01/25/2000</Date>";
+            input += "            </Price>";
+            input += "            <Price type=\"low\">";
+            input += "                <Value>1.0</Value>";
+            input += "                <Date>03/23/2002</Date>";
+            input += "            </Price>";
+            input += "            <Price type=\"current\">";
+            input += "                <Value>3.0</Value>";
+            input += "                <Date>TODAY</Date>";
+            input += "            </Price>";
+            input += "        </Stock>";
+            input += "        <Stock name=\"Mainsoft\">";
+            input += "            <Company name=\"Mainsoft Corp.\"/>";
+            input += "            <Price type=\"high\">";
+            input += "                <Value>30.0</Value>";
+            input += "                <Date>01/26/2000</Date>";
+            input += "            </Price>";
+            input += "            <Price type=\"low\">";
+            input += "                <Value>1.0</Value>";
+            input += "                <Date>03/26/2002</Date>";
+            input += "            </Price>";
+            input += "            <Price type=\"current\">";
+            input += "                <Value>27.0</Value>";
+            input += "                <Date>TODAY</Date>";
+            input += "            </Price>";
+            input += "        </Stock>";
             input += "</Stocks>";
 
             sr = new StringReader(input);
@@ -3034,30 +3034,30 @@ namespace System.Data.Tests
             }
             catch (InvalidOperationException e)
             {
-                //ok   
+                //ok     
             }
         }
 
         ///<?xml version="1.0" encoding="utf-16"?>
         ///<xs:schema id="NewDataSet" xmlns="" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
-        ///    <xs:element name="NewDataSet" msdata:IsDataSet="true">
-        ///            <xs:complexType>
-        ///                    <xs:choice maxOccurs="unbounded">
-        ///                            <xs:element name="Parent">
-        ///                                    <xs:complexType>
-        ///                                            <xs:sequence>
-        ///                                                    <xs:element name="ParentId" type="xs:int" minOccurs="0"/>
-        ///                                                    <xs:element name="String1" type="xs:string" minOccurs="0"/>
-        ///                                                    <xs:element name="String2" type="xs:string" minOccurs="0"/>
-        ///                                                    <xs:element name="ParentDateTime" type="xs:dateTime" minOccurs="0"/>
-        ///                                                    <xs:element name="ParentDouble" type="xs:double" minOccurs="0"/>
-        ///                                                    <xs:element name="ParentBool" type="xs:boolean" minOccurs="0"/>
-        ///                                            </xs:sequence>
-        ///                                    </xs:complexType>
-        ///                            </xs:element>
-        ///                    </xs:choice>
-        ///            </xs:complexType>
-        ///    </xs:element>
+        ///    <xs:element name="NewDataSet" msdata:IsDataSet="true">
+        ///        <xs:complexType>
+        ///            <xs:choice maxOccurs="unbounded">
+        ///                <xs:element name="Parent">
+        ///                    <xs:complexType>
+        ///                        <xs:sequence>
+        ///                            <xs:element name="ParentId" type="xs:int" minOccurs="0"/>
+        ///                            <xs:element name="String1" type="xs:string" minOccurs="0"/>
+        ///                            <xs:element name="String2" type="xs:string" minOccurs="0"/>
+        ///                            <xs:element name="ParentDateTime" type="xs:dateTime" minOccurs="0"/>
+        ///                            <xs:element name="ParentDouble" type="xs:double" minOccurs="0"/>
+        ///                            <xs:element name="ParentBool" type="xs:boolean" minOccurs="0"/>
+        ///                        </xs:sequence>
+        ///                    </xs:complexType>
+        ///                </xs:element>
+        ///            </xs:choice>
+        ///        </xs:complexType>
+        ///    </xs:element>
         ///</xs:schema>
 
         [Fact]
index 9c55046..0b08750 100644 (file)
@@ -659,7 +659,7 @@ namespace System.Data.Tests
             drOrders.ShipAddress = "Food Market";
             drOrders.ShipCity = "Baker Blvd.";
             drOrders.ShipRegion = "Eugene";
-            drOrders.ShipPostalCode = "OR      97403";
+            drOrders.ShipPostalCode = "OR 97403";
             drOrders.ShipCountry = "USA";
 
             i = tblOrders.Rows.Count;
index 2d1f800..d94c3ad 100644 (file)
@@ -57,19 +57,19 @@ namespace System.Data.Tests
         {
             string schema = @"<?xml version='1.0'?>
 <xsd:schema xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
-       <xsd:attribute name='foo' type='xsd:string'/>
-       <xsd:attribute name='bar' type='xsd:string'/>
-       <xsd:complexType name='attRef'>
-               <xsd:attribute name='att1' type='xsd:int'/>
-               <xsd:attribute name='att2' type='xsd:string'/>
-       </xsd:complexType>
-       <xsd:element name='doc'>
-               <xsd:complexType>
-                       <xsd:choice>
-                               <xsd:element name='elem' type='attRef'/>
-                       </xsd:choice>
-               </xsd:complexType>
-       </xsd:element>
+    <xsd:attribute name='foo' type='xsd:string'/>
+    <xsd:attribute name='bar' type='xsd:string'/>
+    <xsd:complexType name='attRef'>
+        <xsd:attribute name='att1' type='xsd:int'/>
+        <xsd:attribute name='att2' type='xsd:string'/>
+    </xsd:complexType>
+    <xsd:element name='doc'>
+        <xsd:complexType>
+            <xsd:choice>
+                <xsd:element name='elem' type='attRef'/>
+            </xsd:choice>
+        </xsd:complexType>
+    </xsd:element>
 </xsd:schema>";
             var ds = new DataSet();
             ds.Tables.Add(new DataTable("elem"));
@@ -81,18 +81,18 @@ namespace System.Data.Tests
         public void UnusedComplexTypesIgnored()
         {
             string xs = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' id='hoge'>
-       <xs:element name='Root'>
-               <xs:complexType>
-                       <xs:sequence>
-                               <xs:element name='Child' type='xs:string' />
-                       </xs:sequence>
-               </xs:complexType>
-       </xs:element>
-       <xs:complexType name='unusedType'>
-               <xs:sequence>
-                       <xs:element name='Orphan' type='xs:string' />
-               </xs:sequence>
-       </xs:complexType>
+    <xs:element name='Root'>
+        <xs:complexType>
+            <xs:sequence>
+                <xs:element name='Child' type='xs:string' />
+            </xs:sequence>
+        </xs:complexType>
+    </xs:element>
+    <xs:complexType name='unusedType'>
+        <xs:sequence>
+            <xs:element name='Orphan' type='xs:string' />
+        </xs:sequence>
+    </xs:complexType>
 </xs:schema>";
 
             AssertExtensions.Throws<ArgumentException>(null, () =>
@@ -111,13 +111,13 @@ namespace System.Data.Tests
         public void IsDataSetAndTypeIgnored()
         {
             string xsbase = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' xmlns:msdata='urn:schemas-microsoft-com:xml-msdata'>
-       <xs:element name='Root' type='unusedType' msdata:IsDataSet='{0}'>
-       </xs:element>
-       <xs:complexType name='unusedType'>
-               <xs:sequence>
-                       <xs:element name='Child' type='xs:string' />
-               </xs:sequence>
-       </xs:complexType>
+    <xs:element name='Root' type='unusedType' msdata:IsDataSet='{0}'>
+    </xs:element>
+    <xs:complexType name='unusedType'>
+        <xs:sequence>
+            <xs:element name='Child' type='xs:string' />
+        </xs:sequence>
+    </xs:complexType>
 </xs:schema>";
 
             AssertExtensions.Throws<ArgumentException>(null, () =>
@@ -143,20 +143,20 @@ namespace System.Data.Tests
         public void NestedReferenceNotAllowed()
         {
             string xs = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' xmlns:msdata='urn:schemas-microsoft-com:xml-msdata'>
-       <xs:element name='Root' type='unusedType' msdata:IsDataSet='true'>
-       </xs:element>
-       <xs:complexType name='unusedType'>
-               <xs:sequence>
-                       <xs:element name='Child' type='xs:string' />
-               </xs:sequence>
-       </xs:complexType>
-       <xs:element name='Foo'>
-               <xs:complexType>
-                       <xs:sequence>
-                               <xs:element ref='Root' />
-                       </xs:sequence>
-               </xs:complexType>
-       </xs:element>
+    <xs:element name='Root' type='unusedType' msdata:IsDataSet='true'>
+    </xs:element>
+    <xs:complexType name='unusedType'>
+        <xs:sequence>
+            <xs:element name='Child' type='xs:string' />
+        </xs:sequence>
+    </xs:complexType>
+    <xs:element name='Foo'>
+        <xs:complexType>
+            <xs:sequence>
+                <xs:element ref='Root' />
+            </xs:sequence>
+        </xs:complexType>
+    </xs:element>
 </xs:schema>";
 
             AssertExtensions.Throws<ArgumentException>(null, () =>
@@ -173,14 +173,14 @@ namespace System.Data.Tests
         public void LocaleOnRootWithoutIsDataSet()
         {
             string xs = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' xmlns:msdata='urn:schemas-microsoft-com:xml-msdata'>
-       <xs:element name='Root' msdata:Locale='ja-JP'>
-               <xs:complexType>
-                       <xs:sequence>
-                               <xs:element name='Child' type='xs:string' />
-                       </xs:sequence>
-                       <xs:attribute name='Attr' type='xs:integer' />
-               </xs:complexType>
-       </xs:element>
+    <xs:element name='Root' msdata:Locale='ja-JP'>
+        <xs:complexType>
+            <xs:sequence>
+                <xs:element name='Child' type='xs:string' />
+            </xs:sequence>
+            <xs:attribute name='Attr' type='xs:integer' />
+        </xs:complexType>
+    </xs:element>
 </xs:schema>";
 
             var ds = new DataSet();
@@ -197,49 +197,49 @@ namespace System.Data.Tests
         public void PrefixedTargetNS()
         {
             string xs = @"<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' xmlns:msdata='urn:schemas-microsoft-com:xml-msdata' xmlns:x='urn:foo' targetNamespace='urn:foo' elementFormDefault='qualified'>
-       <xs:element name='DS' msdata:IsDataSet='true'>
-               <xs:complexType>
-                       <xs:choice>
-                               <xs:element ref='x:R1' />
-                               <xs:element ref='x:R2' />
-                       </xs:choice>
-               </xs:complexType>
-               <xs:key name='key'>
-                       <xs:selector xpath='./any/string_is_OK/x:R1'/>
-                       <xs:field xpath='x:Child2'/>
-               </xs:key>
-               <xs:keyref name='kref' refer='x:key'>
-                       <xs:selector xpath='.//x:R2'/>
-                       <xs:field xpath='x:Child2'/>
-               </xs:keyref>
-       </xs:element>
-       <xs:element name='R3' type='x:RootType' />
-       <xs:complexType name='extracted'>
-               <xs:choice>
-                       <xs:element ref='x:R1' />
-                       <xs:element ref='x:R2' />
-               </xs:choice>
-       </xs:complexType>
-       <xs:element name='R1' type='x:RootType'>
-               <xs:unique name='Rkey'>
-                       <xs:selector xpath='.//x:Child1'/>
-                       <xs:field xpath='.'/>
-               </xs:unique>
-               <xs:keyref name='Rkref' refer='x:Rkey'>
-                       <xs:selector xpath='.//x:Child2'/>
-                       <xs:field xpath='.'/>
-               </xs:keyref>
-       </xs:element>
-       <xs:element name='R2' type='x:RootType'>
-       </xs:element>
-       <xs:complexType name='RootType'>
-               <xs:choice>
-                       <xs:element name='Child1' type='xs:string'>
-                       </xs:element>
-                       <xs:element name='Child2' type='xs:string' />
-               </xs:choice>
-               <xs:attribute name='Attr' type='xs:integer' />
-       </xs:complexType>
+    <xs:element name='DS' msdata:IsDataSet='true'>
+        <xs:complexType>
+            <xs:choice>
+                <xs:element ref='x:R1' />
+                <xs:element ref='x:R2' />
+            </xs:choice>
+        </xs:complexType>
+        <xs:key name='key'>
+            <xs:selector xpath='./any/string_is_OK/x:R1'/>
+            <xs:field xpath='x:Child2'/>
+        </xs:key>
+        <xs:keyref name='kref' refer='x:key'>
+            <xs:selector xpath='.//x:R2'/>
+            <xs:field xpath='x:Child2'/>
+        </xs:keyref>
+    </xs:element>
+    <xs:element name='R3' type='x:RootType' />
+    <xs:complexType name='extracted'>
+        <xs:choice>
+            <xs:element ref='x:R1' />
+            <xs:element ref='x:R2' />
+        </xs:choice>
+    </xs:complexType>
+    <xs:element name='R1' type='x:RootType'>
+        <xs:unique name='Rkey'>
+            <xs:selector xpath='.//x:Child1'/>
+            <xs:field xpath='.'/>
+        </xs:unique>
+        <xs:keyref name='Rkref' refer='x:Rkey'>
+            <xs:selector xpath='.//x:Child2'/>
+            <xs:field xpath='.'/>
+        </xs:keyref>
+    </xs:element>
+    <xs:element name='R2' type='x:RootType'>
+    </xs:element>
+    <xs:complexType name='RootType'>
+        <xs:choice>
+            <xs:element name='Child1' type='xs:string'>
+            </xs:element>
+            <xs:element name='Child2' type='xs:string' />
+        </xs:choice>
+        <xs:attribute name='Attr' type='xs:integer' />
+    </xs:complexType>
 </xs:schema>";
             // No prefixes on tables and columns
             var ds = new DataSet();
@@ -315,21 +315,21 @@ namespace System.Data.Tests
             ds.Tables[0].ReadXmlSchema(new StringReader(
                 @"<!-- Modified w3ctests attQ014.xsd -->
                 <xsd:schema xmlns:xsd=""http://www.w3.org/2001/XMLSchema"" targetNamespace=""http://xsdtesting"" xmlns:x=""http://xsdtesting"">
-                       <xsd:element name=""root"">
-                               <xsd:complexType>
-                                       <xsd:sequence>
-                                               <xsd:element name=""e"">
-                                                       <xsd:complexType>
-                                                               <xsd:simpleContent>
-                                                                       <xsd:extension base=""xsd:decimal"">
-                                                                               <xsd:attribute name=""a"" type=""xsd:string""/>
-                                                                       </xsd:extension>
-                                                               </xsd:simpleContent>
-                                                       </xsd:complexType>
-                                               </xsd:element>
-                                       </xsd:sequence>
-                               </xsd:complexType>
-                       </xsd:element>
+                    <xsd:element name=""root"">
+                        <xsd:complexType>
+                            <xsd:sequence>
+                                <xsd:element name=""e"">
+                                    <xsd:complexType>
+                                        <xsd:simpleContent>
+                                            <xsd:extension base=""xsd:decimal"">
+                                                <xsd:attribute name=""a"" type=""xsd:string""/>
+                                            </xsd:extension>
+                                        </xsd:simpleContent>
+                                    </xsd:complexType>
+                                </xsd:element>
+                            </xsd:sequence>
+                        </xsd:complexType>
+                    </xsd:element>
                 </xsd:schema>"));
             DataTable dt = ds.Tables[0];
             DataSetAssertion.AssertDataTable("root", dt, "e", 2, 0, 0, 0, 0, 0);
@@ -345,38 +345,38 @@ namespace System.Data.Tests
             ds.Tables[0].ReadXmlSchema(new StringReader(
                 @"<?xml version=""1.0"" encoding=""utf-8"" ?>
                     <xs:schema targetNamespace=""http://neurosaudio.com/Tracks.xsd"" xmlns=""http://neurosaudio.com/Tracks.xsd"" xmlns:mstns=""http://neurosaudio.com/Tracks.xsd"" xmlns:xs=""http://www.w3.org/2001/XMLSchema"" xmlns:msdata=""urn:schemas-microsoft-com:xml-msdata"" elementFormDefault=""qualified"" id=""Tracks"">
-                           <xs:element name=""Tracks"">
-                                   <xs:complexType>
-                                           <xs:sequence>
-                                                   <xs:element name=""Track"" minOccurs=""0"" maxOccurs=""unbounded"">
-                                                           <xs:complexType>
-                                                                   <xs:sequence>
-                                                                           <xs:element name=""Title"" type=""xs:string"" />
-                                                                           <xs:element name=""Artist"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""Album"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""Performer"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""Sequence"" type=""xs:unsignedInt"" minOccurs=""0"" />
-                                                                           <xs:element name=""Genre"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""Comment"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""Year"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""Duration"" type=""xs:unsignedInt"" minOccurs=""0"" />
-                                                                           <xs:element name=""Path"" type=""xs:string"" />
-                                                                           <xs:element name=""DevicePath"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""FileSize"" type=""xs:unsignedInt"" minOccurs=""0"" />
-                                                                           <xs:element name=""Source"" type=""xs:string"" minOccurs=""0"" />
-                                                                           <xs:element name=""FlashStatus"" type=""xs:unsignedInt"" />
-                                                                           <xs:element name=""HDStatus"" type=""xs:unsignedInt"" />
-                                                                   </xs:sequence>
-                                                                   <xs:attribute name=""ID"" type=""xs:unsignedInt"" msdata:AutoIncrement=""true"" msdata:AutoIncrementSeed=""1"" />
-                                                           </xs:complexType>
-                                                   </xs:element>
-                                           </xs:sequence>
-                                   </xs:complexType>
-                                   <xs:key name=""TrackPK"" msdata:PrimaryKey=""true"">
-                                           <xs:selector xpath="".//mstns:Track"" />
-                                           <xs:field xpath=""@ID"" />
-                                   </xs:key>
-                           </xs:element>
+                        <xs:element name=""Tracks"">
+                            <xs:complexType>
+                                <xs:sequence>
+                                    <xs:element name=""Track"" minOccurs=""0"" maxOccurs=""unbounded"">
+                                        <xs:complexType>
+                                            <xs:sequence>
+                                                <xs:element name=""Title"" type=""xs:string"" />
+                                                <xs:element name=""Artist"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""Album"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""Performer"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""Sequence"" type=""xs:unsignedInt"" minOccurs=""0"" />
+                                                <xs:element name=""Genre"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""Comment"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""Year"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""Duration"" type=""xs:unsignedInt"" minOccurs=""0"" />
+                                                <xs:element name=""Path"" type=""xs:string"" />
+                                                <xs:element name=""DevicePath"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""FileSize"" type=""xs:unsignedInt"" minOccurs=""0"" />
+                                                <xs:element name=""Source"" type=""xs:string"" minOccurs=""0"" />
+                                                <xs:element name=""FlashStatus"" type=""xs:unsignedInt"" />
+                                                <xs:element name=""HDStatus"" type=""xs:unsignedInt"" />
+                                            </xs:sequence>
+                                            <xs:attribute name=""ID"" type=""xs:unsignedInt"" msdata:AutoIncrement=""true"" msdata:AutoIncrementSeed=""1"" />
+                                        </xs:complexType>
+                                    </xs:element>
+                                </xs:sequence>
+                            </xs:complexType>
+                            <xs:key name=""TrackPK"" msdata:PrimaryKey=""true"">
+                                <xs:selector xpath="".//mstns:Track"" />
+                                <xs:field xpath=""@ID"" />
+                            </xs:key>
+                        </xs:element>
                     </xs:schema>"));
         }
 
index 6eb0951..bb0cf63 100644 (file)
@@ -762,7 +762,7 @@ namespace System.Data.Tests
             {
                 // Never premise English.
                 //Assert.Equal ("Schema of current DataTable '" + table.TableName + 
-                //             "' in DataTableReader has changed, DataTableReader is invalid.", e.Message, "#1");
+                //        "' in DataTableReader has changed, DataTableReader is invalid.", e.Message, "#1");
             }
 
             rdr = table.CreateDataReader();
@@ -777,7 +777,7 @@ namespace System.Data.Tests
             {
                 // Never premise English.
                 //Assert.Equal ("Schema of current DataTable '" + table.TableName + 
-                //             "' in DataTableReader has changed, DataTableReader is invalid.", e.Message, "#1");
+                //        "' in DataTableReader has changed, DataTableReader is invalid.", e.Message, "#1");
             }
         }
 
@@ -826,7 +826,7 @@ namespace System.Data.Tests
             {
                 // Never premise English.
                 //Assert.Equal ("Unable to cast object of type 'System.String'" +
-                //     " to type 'System.Char[]'.", e.Message, "#1");
+                //    " to type 'System.Char[]'.", e.Message, "#1");
             }
             char[] char_arr = null;
             long len = 0;
index 4f72f4a..a188903 100644 (file)
@@ -698,14 +698,14 @@ namespace System.Data.Tests
             Assert.Equal(1, Rows.Length);
 
             /*
-                       try {
-                               Mom.Select ("Child.Name = 'Jack'");
+            try {
+                Mom.Select ("Child.Name = 'Jack'");
 Assert.False(true);
-                       } catch (Exception e) {
-                               Assert.Equal (typeof (SyntaxErrorException), e.GetType ());
-                               Assert.Equal ("Cannot interpret token 'Child' at position 1.", e.Message);
-                       }
-                       */
+            } catch (Exception e) {
+                Assert.Equal (typeof (SyntaxErrorException), e.GetType ());
+                Assert.Equal ("Cannot interpret token 'Child' at position 1.", e.Message);
+            }
+            */
 
             Rows = Child.Select("Parent.name = 'Laura'");
             Assert.Equal(3, Rows.Length);
@@ -2938,10 +2938,10 @@ Assert.False(true);
             DataTableReader dtr = _dt.CreateDataReader();
             DataRowAction[] dra = new DataRowAction[] {
                 DataRowAction.Nothing,// REAL action
-                               DataRowAction.Nothing,// dummy  
-                               DataRowAction.Nothing,// dummy  
-                               DataRowAction.Nothing,// dummy  
-                               DataRowAction.Nothing};// dummy  
+                DataRowAction.Nothing,// dummy  
+                DataRowAction.Nothing,// dummy  
+                DataRowAction.Nothing,// dummy  
+                DataRowAction.Nothing};// dummy  
             rowActionInit(dra);
             dtLoad.Load(dtr, LoadOption.Upsert);
             rowActionEnd();
@@ -3988,22 +3988,22 @@ Assert.False(true);
         public void ReadXmlSchemeWithScheme()
         {
             const string xml = @"<CustomElement>
-                                 <xs:schema id='NewDataSet' xmlns='' xmlns:xs='http://www.w3.org/2001/XMLSchema' xmlns:msdata='urn:schemas-microsoft-com:xml-msdata'>
-                                       <xs:element name='NewDataSet' msdata:IsDataSet='true' msdata:MainDataTable='row' msdata:Locale=''>
-                                         <xs:complexType>
-                                               <xs:choice minOccurs='0' maxOccurs='unbounded'>
-                                                 <xs:element name='row' msdata:Locale=''>
-                                                       <xs:complexType>
-                                                         <xs:sequence>
-                                                               <xs:element name='Text' type='xs:string' minOccurs='0' />
-                                                         </xs:sequence>
-                                                       </xs:complexType>
-                                                 </xs:element>
-                                               </xs:choice>
-                                         </xs:complexType>
-                                       </xs:element>
-                                 </xs:schema>
-                               </CustomElement>";
+                  <xs:schema id='NewDataSet' xmlns='' xmlns:xs='http://www.w3.org/2001/XMLSchema' xmlns:msdata='urn:schemas-microsoft-com:xml-msdata'>
+                    <xs:element name='NewDataSet' msdata:IsDataSet='true' msdata:MainDataTable='row' msdata:Locale=''>
+                      <xs:complexType>
+                        <xs:choice minOccurs='0' maxOccurs='unbounded'>
+                          <xs:element name='row' msdata:Locale=''>
+                            <xs:complexType>
+                              <xs:sequence>
+                                <xs:element name='Text' type='xs:string' minOccurs='0' />
+                              </xs:sequence>
+                            </xs:complexType>
+                          </xs:element>
+                        </xs:choice>
+                      </xs:complexType>
+                    </xs:element>
+                  </xs:schema>
+                </CustomElement>";
             using (var s = new StringReader(xml))
             {
                 DataTable dt = new DataTable();
@@ -4016,9 +4016,9 @@ Assert.False(true);
         public void ReadXmlSchemeWithBadScheme()
         {
             const string xml = @"<CustomElement>
-                                 <xs:schema id='NewDataSet' xmlns='' xmlns:xs='http://www.w3.org/2001/BAD' xmlns:msdata='urn:schemas-microsoft-com:xml-msdata'>
-                                 </xs:schema>
-                               </CustomElement>";
+                  <xs:schema id='NewDataSet' xmlns='' xmlns:xs='http://www.w3.org/2001/BAD' xmlns:msdata='urn:schemas-microsoft-com:xml-msdata'>
+                  </xs:schema>
+                </CustomElement>";
             AssertExtensions.Throws<ArgumentException>(null, () =>
             {
                 using (var s = new StringReader(xml))
index c8ac7a6..abc80b7 100644 (file)
@@ -861,10 +861,10 @@ namespace System.Data.Tests
         [Fact]
         public void MinimumCapacity()
         {
-            //                         i get default=50, according to MSDN the value should be 25 
-            //                         // Checking MinimumCapacity default = 25 
-            //                         Assert.Equal(25, dtParent.MinimumCapacity);
-            //                         EndCase(null);
+            //                i get default=50, according to MSDN the value should be 25 
+            //                // Checking MinimumCapacity default = 25 
+            //                Assert.Equal(25, dtParent.MinimumCapacity);
+            //                EndCase(null);
             DataTable dt = new DataTable();
 
             // Checking MinimumCapacity get/set int.MaxValue 
@@ -875,10 +875,10 @@ namespace System.Data.Tests
             dt.MinimumCapacity = 0;
             Assert.Equal(0, dt.MinimumCapacity);
 
-            //                         // Checking MinimumCapacity get/set int.MinValue 
-            //                         dtParent.MinimumCapacity = int.MinValue;
-            //                         Assert.Equal(int.MinValue, dtParent.MinimumCapacity);
-            //                         EndCase(null);
+            //                // Checking MinimumCapacity get/set int.MinValue 
+            //                dtParent.MinimumCapacity = int.MinValue;
+            //                Assert.Equal(int.MinValue, dtParent.MinimumCapacity);
+            //                EndCase(null);
         }
 
         [Fact]
@@ -1390,14 +1390,14 @@ namespace System.Data.Tests
             CompareUnSorted(drSelect, al.ToArray());
 
 #if LATER
-                       //-------------------------------------------------------------
-                       al.Clear();
-                       foreach (DataRow dr in dt.Rows)
-                               if (dr["ChildDouble"].ToString().Length > 10)
-                                       al.Add(dr);
-                               // Select_S - Len(Convert(ChildDouble,'System.String')) > 10
-                               drSelect = dt.Select ("Len(Convert(ChildDouble,'System.String')) > 10");
-                               Assert.Equal (al.ToArray(), drSelect);
+            //-------------------------------------------------------------
+            al.Clear();
+            foreach (DataRow dr in dt.Rows)
+                if (dr["ChildDouble"].ToString().Length > 10)
+                    al.Add(dr);
+                // Select_S - Len(Convert(ChildDouble,'System.String')) > 10
+                drSelect = dt.Select ("Len(Convert(ChildDouble,'System.String')) > 10");
+                Assert.Equal (al.ToArray(), drSelect);
 #endif
             //-------------------------------------------------------------
             al.Clear();
@@ -1409,14 +1409,14 @@ namespace System.Data.Tests
             Assert.Equal(al.ToArray(), drSelect);
             //-------------------------------------------------------------
             /*
-                       al.Clear();
-                       foreach (DataRow dr in ds.Tables[0].Rows)
-                               if (dr.IsNull("ParentBool") || (bool)dr["ParentBool"])
-                                       al.Add(dr);
-                               // Select_S - IsNull(ParentBool,true)
-                               drSelect = ds.Tables[0].Select("IsNull(ParentBool,true) ");
-                               Assert.Equal (al.ToArray(), drSelect);
-                       */
+            al.Clear();
+            foreach (DataRow dr in ds.Tables[0].Rows)
+                if (dr.IsNull("ParentBool") || (bool)dr["ParentBool"])
+                    al.Add(dr);
+                // Select_S - IsNull(ParentBool,true)
+                drSelect = ds.Tables[0].Select("IsNull(ParentBool,true) ");
+                Assert.Equal (al.ToArray(), drSelect);
+            */
             //-------------------------------------------------------------
             al.Clear();
             // Select_S - Relation not exists, Exception
@@ -1499,11 +1499,11 @@ namespace System.Data.Tests
             ArrayList al = new ArrayList();
             DataRowVersion drVer = DataRowVersion.Current;
 
-            //From MSDN -      The row the default version for the current DataRowState.
-            //                         For a DataRowState value of Added, Modified or Current, 
-            //                         the default version is Current. 
-            //                         For a DataRowState of Deleted, the version is Original.
-            //                         For a DataRowState value of Detached, the version is Proposed.
+            //From MSDN -    The row the default version for the current DataRowState.
+            //                For a DataRowState value of Added, Modified or Current, 
+            //                the default version is Current. 
+            //                For a DataRowState of Deleted, the version is Original.
+            //                For a DataRowState value of Detached, the version is Proposed.
 
             if (((State & DataRowState.Added) > 0)
                 | ((State & DataRowState.Modified) > 0)
@@ -1851,7 +1851,7 @@ namespace System.Data.Tests
             table.PrimaryKey = new DataColumn[] { col };
             table.AcceptChanges();
 
-            // ms.net behavior.        
+            // ms.net behavior.    
             table.BeginInit();
             DataColumn col1 = new DataColumn("col1", typeof(int));
             table.Columns.AddRange(new DataColumn[] { col1 });
@@ -2226,13 +2226,13 @@ namespace System.Data.Tests
             // ms.net throws a nullreference exception.
             // If any data is merged, exception is anyways raised.
             /*
-                       table1.PrimaryKey = new DataColumn[] {table1.Columns[0]};
-                       table3 = table1.Clone ();
-                       try {
-                               table3.Merge(table2);
+            table1.PrimaryKey = new DataColumn[] {table1.Columns[0]};
+            table3 = table1.Clone ();
+            try {
+                table3.Merge(table2);
 Assert.False(true);
-                       } catch (DataException e) {}
-                       */
+            } catch (DataException e) {}
+            */
 
             table3.Merge(table2, false, MissingSchemaAction.Ignore);
             table1.PrimaryKey = null;
index e21c9ad..da472c4 100644 (file)
@@ -1298,7 +1298,7 @@ namespace System.Data.Tests
 
             using (FileStream stream = new FileStream(_tempFile, FileMode.Open))
             {
-                //This should not read anything as table name is not set       
+                //This should not read anything as table name is not set
                 mode = table.ReadXml(stream);
             }
 
index f8d706a..bc0765e 100644 (file)
@@ -70,7 +70,7 @@ namespace System.Data.Tests
             // RowFilter is not examined.
             m.DataViewSettingCollectionString = "<DataViewSettingCollectionString>blah<table2-1 RowFilter='a=b' ApplyDefaultSort='true' /></DataViewSettingCollectionString>";
             // MS.NET ignores ApplyDefaultSort.
-            //                 Assert.Equal (@"<DataViewSettingCollectionString><table2-1 Sort="""" RowFilter=""a=b"" RowStateFilter=""Deleted""/></DataViewSettingCollectionString>", m.DataViewSettingCollectionString);
+            //            Assert.Equal (@"<DataViewSettingCollectionString><table2-1 Sort="""" RowFilter=""a=b"" RowStateFilter=""Deleted""/></DataViewSettingCollectionString>", m.DataViewSettingCollectionString);
         }
 
         [Fact]
index bcdaaa3..347466b 100644 (file)
@@ -690,15 +690,15 @@ namespace System.Data.Tests
         public void RowStateFilter()
         {
             /*
-                               Added                   A new row. 4 
-                               CurrentRows             Current rows including unchanged, new, and modified rows. 22 
-                               Deleted                 A deleted row. 8 
-                               ModifiedCurrent A current version, which is a modified version of original data (see ModifiedOriginal). 16 
-                               ModifiedOriginal The original version (although it has since been modified and is available as ModifiedCurrent). 32 
-                               None                    None. 0 
-                               OriginalRows    Original rows including unchanged and deleted rows. 42 
-                               Unchanged               An unchanged row. 2 
-                        */
+                Added           A new row. 4 
+                CurrentRows     Current rows including unchanged, new, and modified rows. 22 
+                Deleted         A deleted row. 8 
+                ModifiedCurrent A current version, which is a modified version of original data (see ModifiedOriginal). 16 
+                ModifiedOriginal The original version (although it has since been modified and is available as ModifiedCurrent). 32 
+                None            None. 0 
+                OriginalRows    Original rows including unchanged and deleted rows. 42 
+                Unchanged       An unchanged row. 2 
+             */
 
             //DataRowView[] drvResult = null;
             ArrayList al = new ArrayList();
@@ -748,12 +748,12 @@ namespace System.Data.Tests
             // Deleted
             Assert.True(CompareSortedRowsByParentId(dv, drResult));
             /*
-                                       //---------- OriginalRows -------- 
-                                       dv.RowStateFilter = DataViewRowState.OriginalRows ;
-                                       drResult = GetResultRows(dt,DataRowState.Unchanged | DataRowState.Deleted );
-                                               // OriginalRows
-                                               Assert.Equal(true , CompareSortedRowsByParentId(dv,drResult));
-                       */
+                    //---------- OriginalRows -------- 
+                    dv.RowStateFilter = DataViewRowState.OriginalRows ;
+                    drResult = GetResultRows(dt,DataRowState.Unchanged | DataRowState.Deleted );
+                        // OriginalRows
+                        Assert.Equal(true , CompareSortedRowsByParentId(dv,drResult));
+            */
         }
 
         private DataRow[] GetResultRows(DataTable dt, DataRowState State)
@@ -762,11 +762,11 @@ namespace System.Data.Tests
             ArrayList al = new ArrayList();
             DataRowVersion drVer = DataRowVersion.Current;
 
-            //From MSDN -      The row the default version for the current DataRowState.
-            //                         For a DataRowState value of Added, Modified or Current, 
-            //                         the default version is Current. 
-            //                         For a DataRowState of Deleted, the version is Original.
-            //                         For a DataRowState value of Detached, the version is Proposed.
+            //From MSDN -    The row the default version for the current DataRowState.
+            //                For a DataRowState value of Added, Modified or Current, 
+            //                the default version is Current. 
+            //                For a DataRowState of Deleted, the version is Original.
+            //                For a DataRowState value of Detached, the version is Proposed.
 
             if (((State & DataRowState.Added) > 0)
                 | ((State & DataRowState.Modified) > 0)
@@ -991,9 +991,9 @@ namespace System.Data.Tests
 
             dv = dt.DefaultView;
 
-            // public DataViewManager DataViewManager {get;} - The DataViewManager that created this view. 
-            // If this is the default DataView for a DataTable, the DataViewManager property returns the default DataViewManager for the DataSet.
-            // Otherwise, if the DataView was created without a DataViewManager, this property is a null reference (Nothing in Visual Basic).
+            //    public DataViewManager DataViewManager {get;} -    The DataViewManager that created this view. 
+            //    If this is the default DataView for a DataTable, the DataViewManager property returns the default DataViewManager for the DataSet.
+            //    Otherwise, if the DataView was created without a DataViewManager, this property is a null reference (Nothing in Visual Basic).
 
             dvm = dv.DataViewManager;
             Assert.Same(ds.DefaultViewManager, dvm);
@@ -1204,7 +1204,7 @@ namespace System.Data.Tests
             {
                 // Never premise English.
                 //Assert.Equal ("'columnNames' argument cannot be null." + Environment.NewLine + 
-                //             "Parameter name: columnNames", e.Message, "#1");
+                //        "Parameter name: columnNames", e.Message, "#1");
             }
             DataTable newTable1 = view.ToTable(false, new string[] { });
             Assert.Equal(10, newTable1.Rows.Count);
index ee605fe..aef09e4 100644 (file)
@@ -138,7 +138,7 @@ namespace System.Data.Tests
             Assert.Equal(typeof(UniqueConstraint), Table.Constraints[0].GetType());
         }
 
-        // Tests ctor (string, DataColumn [], DataColumn [])   
+        // Tests ctor (string, DataColumn [], DataColumn [])
         [Fact]
         public void Ctor4()
         {
@@ -228,7 +228,7 @@ namespace System.Data.Tests
 #if false // FIXME: Here this test crashes under MS.NET.
                         // OK - So AddRange() is the only way!
                         table2.Constraints.AddRange (constraints);
-                          // After AddRange(), Check the properties of ForeignKeyConstraint object
+               // After AddRange(), Check the properties of ForeignKeyConstraint object
                         Assert.True(fkc.RelatedColumns [0].ColumnName.Equals ("col1"));
                         Assert.True(fkc.RelatedColumns [1].ColumnName.Equals ("col2"));
                         Assert.True(fkc.RelatedColumns [2].ColumnName.Equals ("col3"));
index b7de0e8..5dba677 100644 (file)
@@ -157,7 +157,7 @@ namespace System.Data.Tests
             DataSet ds1 = new DataSet();
             ds1.Tables.Add(DataProvider.CreateParentDataTable());
             ds1.Tables.Add(DataProvider.CreateChildDataTable());
-            // ds1.Tables.Add(DataProvider.CreateChildDataTable());
+            //    ds1.Tables.Add(DataProvider.CreateChildDataTable());
             ds1.Tables[0].PrimaryKey = new DataColumn[] { ds1.Tables[0].Columns[0] };
 
             return ds1;
@@ -376,9 +376,9 @@ namespace System.Data.Tests
             DataRow[] arr = ds1.Tables[1].Select("ChildId is null");
 
             /*foreach (DataRow dr in arr)
-                                       {
-                                               Assert.Null(dr["ChildId"]);
-                                       }*/
+                    {
+                        Assert.Null(dr["ChildId"]);
+                    }*/
 
             Assert.Equal(4, arr.Length);
 
index b1901b9..279ea7f 100644 (file)
@@ -35,14 +35,14 @@ namespace System.Data.Tests.SqlTypes
     public class SqlDateTimeTest
     {
         private long[] _myTicks = {
-            631501920000000000L,       // 25 Feb 2002 - 00:00:00
-                       631502475130080000L,    // 25 Feb 2002 - 15:25:13,8
-                       631502115130080000L,    // 25 Feb 2002 - 05:25:13,8
-                       631502115000000000L,    // 25 Feb 2002 - 05:25:00
-                       631502115130000000L,    // 25 Feb 2002 - 05:25:13
-                       631502079130000000L,    // 25 Feb 2002 - 04:25:13
-                       629197085770000000L     // 06 Nov 1994 - 08:49:37 
-               };
+            631501920000000000L,    // 25 Feb 2002 - 00:00:00
+            631502475130080000L,    // 25 Feb 2002 - 15:25:13,8
+            631502115130080000L,    // 25 Feb 2002 - 05:25:13,8
+            631502115000000000L,    // 25 Feb 2002 - 05:25:00
+            631502115130000000L,    // 25 Feb 2002 - 05:25:13
+            631502079130000000L,    // 25 Feb 2002 - 04:25:13
+            629197085770000000L     // 06 Nov 1994 - 08:49:37 
+        };
 
         private SqlDateTime _test1;
         private SqlDateTime _test2;
index b93038c..df237ff 100644 (file)
@@ -194,16 +194,16 @@ namespace System.Data.Tests.SqlTypes
 
             // Divide() => Notworking
             /*
-                       Assert.Equal ((SqlDecimal)(-1077.441066m), SqlDecimal.Divide (Test1, Test4));
-                       Assert.Equal (1.54687501546m, SqlDecimal.Divide (Test2, Test1).Value);
+            Assert.Equal ((SqlDecimal)(-1077.441066m), SqlDecimal.Divide (Test1, Test4));
+            Assert.Equal (1.54687501546m, SqlDecimal.Divide (Test2, Test1).Value);
 
-                       try {
-                               SqlDecimal test = SqlDecimal.Divide(Test1, new SqlDecimal(0)).Value;
+            try {
+                SqlDecimal test = SqlDecimal.Divide(Test1, new SqlDecimal(0)).Value;
 Assert.False(true);
-                       } catch (DivideByZeroException e) {
-                               Assert.Equal (typeof (DivideByZeroException), e.GetType ());
-                       }
-                       */
+            } catch (DivideByZeroException e) {
+                Assert.Equal (typeof (DivideByZeroException), e.GetType ());
+            }
+            */
 
             Assert.Equal(6464m, SqlDecimal.Floor(_test1));
 
@@ -329,13 +329,13 @@ Assert.False(true);
         }
 
         /* Don't do such environment-dependent test. It will never succeed under Portable.NET and MS.NET
-               [Fact]
-               public void GetHashCodeTest()
-               {
-                       // FIXME: Better way to test HashCode
-                       Assert.Equal (-1281249885, Test1.GetHashCode ());
-               }
-               */
+        [Fact]
+        public void GetHashCodeTest()
+        {
+            // FIXME: Better way to test HashCode
+            Assert.Equal (-1281249885, Test1.GetHashCode ());
+        }
+        */
 
         [Fact]
         public void GetTypeTest()
@@ -423,8 +423,8 @@ Assert.False(true);
             // 6464.6464 --> 64646464 ??? with windows
             // MS.NET seems to return the first 32 bit integer (i.e. 
             // Data [0]) but we don't have to follow such stupidity.
-            //                 Assert.Equal ((int)64646464, Test1.ToSqlInt32 ().Value);
-            //                 Assert.Equal ((int)1212, new SqlDecimal(12.12m).ToSqlInt32 ().Value);
+            //            Assert.Equal ((int)64646464, Test1.ToSqlInt32 ().Value);
+            //            Assert.Equal ((int)1212, new SqlDecimal(12.12m).ToSqlInt32 ().Value);
 
             try
             {
index aab1b2a..851239d 100644 (file)
@@ -115,7 +115,7 @@ namespace MonoTests.System.Data
                         Assert.True(false, "should match only one raw");
                         break;
                 }
-                   prevID = ql.StudentID;
+                prevID = ql.StudentID;
             }
         }
 
index a401609..f3f8a75 100644 (file)
@@ -344,7 +344,7 @@ namespace System.Data.Odbc
                         }
                         else if (value is string)
                         {
-                            cch = ((String)value).Length - offset;
+                            cch = ((string)value).Length - offset;
 
                             if ((0 != (ParameterDirection.Output & _internalDirection)) && (0x3fffffff <= _internalSize))
                             {
@@ -490,7 +490,7 @@ namespace System.Data.Odbc
                         }
                         else if (value is string)
                         {
-                            ccb = (((String)value).Length - offset) * 2 + 2;
+                            ccb = (((string)value).Length - offset) * 2 + 2;
                         }
                         else if (value is char[])
                         {
@@ -512,10 +512,10 @@ namespace System.Data.Odbc
                     }
                     else if (ODBC32.SQL_C.WCHAR == _bindtype._sql_c)
                     {
-                        if ((value is string) && (ccb < ((String)value).Length) && (_bindtype == _originalbindtype))
+                        if ((value is string) && (ccb < ((string)value).Length) && (_bindtype == _originalbindtype))
                         {
                             // silently truncate ... MDAC 84408 ... do not truncate upgraded values ... MDAC 84706
-                            ccb = ((String)value).Length;
+                            ccb = ((string)value).Length;
                         }
                         ccb = (ccb * 2) + 2; // allow for null termination
                     }
@@ -679,7 +679,7 @@ namespace System.Data.Odbc
                         _bindtype = TypeMap._VarChar;
                         if ((null != value) && !Convert.IsDBNull(value))
                         {
-                            value = ((Decimal)value).ToString(CultureInfo.CurrentCulture);
+                            value = ((decimal)value).ToString(CultureInfo.CurrentCulture);
                             size = ((string)value).Length;
                             offset = 0;
                         }
@@ -693,7 +693,7 @@ namespace System.Data.Odbc
                         _bindtype = TypeMap._VarChar;
                         if ((null != value) && !Convert.IsDBNull(value))
                         {
-                            value = ((Int64)value).ToString(CultureInfo.CurrentCulture);
+                            value = ((long)value).ToString(CultureInfo.CurrentCulture);
                             size = ((string)value).Length;
                             offset = 0;
                         }
index 72f7bc7..361b479 100644 (file)
@@ -219,7 +219,7 @@ namespace System.Data.Odbc
         {
             if (value is decimal)
             {
-                return ((System.Data.SqlTypes.SqlDecimal)(Decimal)value).Precision;
+                return ((System.Data.SqlTypes.SqlDecimal)(decimal)value).Precision;
             }
             return 0;
         }
index 607052b..1057b6c 100644 (file)
@@ -12,7 +12,7 @@ using System.Threading;
 
 namespace System.Data.OleDb
 {
-    sealed internal class ColumnBinding
+    internal sealed class ColumnBinding
     {
         // shared with other ColumnBindings
         private readonly OleDbDataReader _dataReader; // HCHAPTER
@@ -273,7 +273,7 @@ namespace System.Data.OleDb
             RowBinding.WriteInt64(ValueOffset, 0); // safe because AlignDataSize forces 8 byte blocks
         }
 
-        internal Object Value()
+        internal object Value()
         {
             object value = _value;
             if (null == value)
@@ -342,7 +342,7 @@ namespace System.Data.OleDb
                                 value = Value_I8(); // Int64
                                 break;
                             case NativeDBType.UI8:
-                                value = (Decimal)Value_UI8(); // UInt64->Decimal
+                                value = (decimal)Value_UI8(); // UInt64->Decimal
                                 break;
                             case NativeDBType.FILETIME:
                                 value = Value_FILETIME(); // DateTime
@@ -456,34 +456,34 @@ namespace System.Data.OleDb
                         SetValueDBNull();
                         break;
                     case NativeDBType.I2:
-                        Value_I2((Int16)value);
+                        Value_I2((short)value);
                         break;
                     case NativeDBType.I4:
-                        Value_I4((Int32)value);
+                        Value_I4((int)value);
                         break;
                     case NativeDBType.R4:
-                        Value_R4((Single)value);
+                        Value_R4((float)value);
                         break;
                     case NativeDBType.R8:
-                        Value_R8((Double)value);
+                        Value_R8((double)value);
                         break;
                     case NativeDBType.CY:
-                        Value_CY((Decimal)value);
+                        Value_CY((decimal)value);
                         break;
                     case NativeDBType.DATE:
                         Value_DATE((DateTime)value);
                         break;
                     case NativeDBType.BSTR:
-                        Value_BSTR((String)value);
+                        Value_BSTR((string)value);
                         break;
                     case NativeDBType.IDISPATCH:
                         Value_IDISPATCH(value);
                         break;
                     case NativeDBType.ERROR:
-                        Value_ERROR((Int32)value);
+                        Value_ERROR((int)value);
                         break;
                     case NativeDBType.BOOL:
-                        Value_BOOL((Boolean)value);
+                        Value_BOOL((bool)value);
                         break;
                     case NativeDBType.VARIANT:
                         Value_VARIANT(value);
@@ -492,52 +492,52 @@ namespace System.Data.OleDb
                         Value_IUNKNOWN(value);
                         break;
                     case NativeDBType.DECIMAL:
-                        Value_DECIMAL((Decimal)value);
+                        Value_DECIMAL((decimal)value);
                         break;
                     case NativeDBType.I1:
-                        if (value is Int16)
+                        if (value is short)
                         {
-                            Value_I1(Convert.ToSByte((Int16)value, CultureInfo.InvariantCulture));
+                            Value_I1(Convert.ToSByte((short)value, CultureInfo.InvariantCulture));
                         }
                         else
                         {
-                            Value_I1((SByte)value);
+                            Value_I1((sbyte)value);
                         }
                         break;
                     case NativeDBType.UI1:
-                        Value_UI1((Byte)value);
+                        Value_UI1((byte)value);
                         break;
                     case NativeDBType.UI2:
-                        if (value is Int32)
+                        if (value is int)
                         {
-                            Value_UI2(Convert.ToUInt16((Int32)value, CultureInfo.InvariantCulture));
+                            Value_UI2(Convert.ToUInt16((int)value, CultureInfo.InvariantCulture));
                         }
                         else
                         {
-                            Value_UI2((UInt16)value);
+                            Value_UI2((ushort)value);
                         }
                         break;
                     case NativeDBType.UI4:
-                        if (value is Int64)
+                        if (value is long)
                         {
-                            Value_UI4(Convert.ToUInt32((Int64)value, CultureInfo.InvariantCulture));
+                            Value_UI4(Convert.ToUInt32((long)value, CultureInfo.InvariantCulture));
                         }
                         else
                         {
-                            Value_UI4((UInt32)value);
+                            Value_UI4((uint)value);
                         }
                         break;
                     case NativeDBType.I8:
-                        Value_I8((Int64)value);
+                        Value_I8((long)value);
                         break;
                     case NativeDBType.UI8:
-                        if (value is Decimal)
+                        if (value is decimal)
                         {
-                            Value_UI8(Convert.ToUInt64((Decimal)value, CultureInfo.InvariantCulture));
+                            Value_UI8(Convert.ToUInt64((decimal)value, CultureInfo.InvariantCulture));
                         }
                         else
                         {
-                            Value_UI8((UInt64)value);
+                            Value_UI8((ulong)value);
                         }
                         break;
                     case NativeDBType.FILETIME:
@@ -547,12 +547,12 @@ namespace System.Data.OleDb
                         Value_GUID((Guid)value);
                         break;
                     case NativeDBType.BYTES:
-                        Value_BYTES((Byte[])value);
+                        Value_BYTES((byte[])value);
                         break;
                     case NativeDBType.WSTR:
                         if (value is string)
                         {
-                            Value_WSTR((String)value);
+                            Value_WSTR((string)value);
                         }
                         else
                         {
@@ -560,7 +560,7 @@ namespace System.Data.OleDb
                         }
                         break;
                     case NativeDBType.NUMERIC:
-                        Value_NUMERIC((Decimal)value);
+                        Value_NUMERIC((decimal)value);
                         break;
                     case NativeDBType.DBDATE:
                         Value_DBDATE((DateTime)value);
@@ -575,12 +575,12 @@ namespace System.Data.OleDb
                         Value_VARIANT(value);
                         break;
                     case (NativeDBType.BYREF | NativeDBType.BYTES):
-                        Value_ByRefBYTES((Byte[])value);
+                        Value_ByRefBYTES((byte[])value);
                         break;
                     case (NativeDBType.BYREF | NativeDBType.WSTR):
                         if (value is string)
                         {
-                            Value_ByRefWSTR((String)value);
+                            Value_ByRefWSTR((string)value);
                         }
                         else
                         {
@@ -610,14 +610,14 @@ namespace System.Data.OleDb
                 }
         }
 
-        internal Boolean Value_BOOL()
+        internal bool Value_BOOL()
         {
             Debug.Assert((NativeDBType.BOOL == DbType), "Value_BOOL");
             Debug.Assert((DBStatus.S_OK == StatusValue()), "Value_BOOL");
-            Int16 value = RowBinding.ReadInt16(ValueOffset);
+            short value = RowBinding.ReadInt16(ValueOffset);
             return (0 != value);
         }
-        private void Value_BOOL(Boolean value)
+        private void Value_BOOL(bool value)
         {
             Debug.Assert((NativeDBType.BOOL == DbType), "Value_BOOL");
             LengthValue(0);
@@ -625,7 +625,7 @@ namespace System.Data.OleDb
             RowBinding.WriteInt16(ValueOffset, (short)(value ? ODB.VARIANT_TRUE : ODB.VARIANT_FALSE));
         }
 
-        private String Value_BSTR()
+        private string Value_BSTR()
         {
             Debug.Assert((NativeDBType.BSTR == DbType), "Value_BSTR");
             Debug.Assert((DBStatus.S_OK == StatusValue()), "Value_BSTR");
@@ -651,7 +651,7 @@ namespace System.Data.OleDb
             }
             return value;
         }
-        private void Value_BSTR(String value)
+        private void Value_BSTR(string value)
         {
             Debug.Assert((null != value), "Value_BSTR null");
             Debug.Assert((NativeDBType.BSTR == DbType), "Value_BSTR");
@@ -660,7 +660,7 @@ namespace System.Data.OleDb
             RowBinding.SetBstrValue(ValueOffset, value);
         }
 
-        private Byte[] Value_ByRefBYTES()
+        private byte[] Value_ByRefBYTES()
         {
             Debug.Assert(((NativeDBType.BYREF | NativeDBType.BYTES) == DbType), "Value_ByRefBYTES");
             Debug.Assert((DBStatus.S_OK == StatusValue()), "Value_ByRefBYTES");
@@ -687,7 +687,7 @@ namespace System.Data.OleDb
             }
             return ((null != value) ? value : Array.Empty<byte>());
         }
-        private void Value_ByRefBYTES(Byte[] value)
+        private void Value_ByRefBYTES(byte[] value)
         {
             Debug.Assert(null != value, "Value_ByRefBYTES null");
             Debug.Assert((NativeDBType.BYREF | NativeDBType.BYTES) == DbType, "Value_ByRefBYTES");
@@ -708,7 +708,7 @@ namespace System.Data.OleDb
             RowBinding.SetByRefValue(ValueOffset, ptr);
         }
 
-        private String Value_ByRefWSTR()
+        private string Value_ByRefWSTR()
         {
             Debug.Assert((NativeDBType.BYREF | NativeDBType.WSTR) == DbType, "Value_ByRefWSTR");
             Debug.Assert((DBStatus.S_OK == StatusValue()) || (DBStatus.S_TRUNCATED == StatusValue()), "Value_ByRefWSTR");
@@ -735,7 +735,7 @@ namespace System.Data.OleDb
             }
             return value;
         }
-        private void Value_ByRefWSTR(String value)
+        private void Value_ByRefWSTR(string value)
         {
             Debug.Assert(null != value, "Value_ByRefWSTR null");
             Debug.Assert((NativeDBType.BYREF | NativeDBType.WSTR) == DbType, "Value_ByRefWSTR");
@@ -774,7 +774,7 @@ namespace System.Data.OleDb
             RowBinding.SetByRefValue(ValueOffset, ptr);
         }
 
-        private Byte[] Value_BYTES()
+        private byte[] Value_BYTES()
         {
             Debug.Assert(NativeDBType.BYTES == DbType, "Value_BYTES");
             Debug.Assert((DBStatus.S_OK == StatusValue()) || (DBStatus.S_TRUNCATED == StatusValue()), "Value_BYTES");
@@ -783,7 +783,7 @@ namespace System.Data.OleDb
             RowBinding.ReadBytes(ValueOffset, value, 0, byteCount);
             return value;
         }
-        private void Value_BYTES(Byte[] value)
+        private void Value_BYTES(byte[] value)
         {
             Debug.Assert(null != value, "Value_BYTES null");
             // we silently truncate when the user has specified a given Size
@@ -796,18 +796,18 @@ namespace System.Data.OleDb
             }
         }
 
-        private Decimal Value_CY()
+        private decimal Value_CY()
         {
             Debug.Assert(NativeDBType.CY == DbType, "Value_CY");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_CY");
-            return Decimal.FromOACurrency(RowBinding.ReadInt64(ValueOffset));
+            return decimal.FromOACurrency(RowBinding.ReadInt64(ValueOffset));
         }
-        private void Value_CY(Decimal value)
+        private void Value_CY(decimal value)
         {
             Debug.Assert(NativeDBType.CY == DbType, "Value_CY");
             LengthValue(0);
             StatusValue(DBStatus.S_OK);
-            RowBinding.WriteInt64(ValueOffset, Decimal.ToOACurrency(value));
+            RowBinding.WriteInt64(ValueOffset, decimal.ToOACurrency(value));
         }
 
         private DateTime Value_DATE()
@@ -866,20 +866,20 @@ namespace System.Data.OleDb
             RowBinding.WriteDateTime(ValueOffset, value);
         }
 
-        private Decimal Value_DECIMAL()
+        private decimal Value_DECIMAL()
         {
             Debug.Assert(NativeDBType.DECIMAL == DbType, "Value_DECIMAL");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_DECIMAL");
             int[] buffer = new int[4];
             RowBinding.ReadInt32Array(ValueOffset, buffer, 0, 4);
-            return new Decimal(
+            return new decimal(
                 buffer[2],  // low
                 buffer[3],  // mid
                 buffer[1],  // high
                 (0 != (buffer[0] & unchecked((int)0x80000000))), // sign
                 unchecked((byte)((buffer[0] & unchecked((int)0x00FF0000)) >> 16))); // scale
         }
-        private void Value_DECIMAL(Decimal value)
+        private void Value_DECIMAL(decimal value)
         {
             Debug.Assert(NativeDBType.DECIMAL == DbType, "Value_DECIMAL");
 
@@ -892,20 +892,20 @@ namespace System.Data.OleDb
             LengthValue(0);
             StatusValue(DBStatus.S_OK);
 
-            int[] tmp = Decimal.GetBits(value);
+            int[] tmp = decimal.GetBits(value);
             int[] buffer = new int[4] {
                 tmp[3], tmp[2], tmp[0], tmp[1]
             };
             RowBinding.WriteInt32Array(ValueOffset, buffer, 0, 4);
         }
 
-        private Int32 Value_ERROR()
+        private int Value_ERROR()
         {
             Debug.Assert(NativeDBType.ERROR == DbType, "Value_ERROR");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_ERROR");
             return RowBinding.ReadInt32(ValueOffset);
         }
-        private void Value_ERROR(Int32 value)
+        private void Value_ERROR(int value)
         {
             Debug.Assert(NativeDBType.ERROR == DbType, "Value_ERROR");
             LengthValue(0);
@@ -917,7 +917,7 @@ namespace System.Data.OleDb
         {
             Debug.Assert(NativeDBType.FILETIME == DbType, "Value_FILETIME");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_FILETIME");
-            Int64 tmp = RowBinding.ReadInt64(ValueOffset);
+            long tmp = RowBinding.ReadInt64(ValueOffset);
             return DateTime.FromFileTime(tmp);
         }
         private void Value_FILETIME(DateTime value)
@@ -925,7 +925,7 @@ namespace System.Data.OleDb
             Debug.Assert(NativeDBType.FILETIME == DbType, "Value_FILETIME");
             LengthValue(0);
             StatusValue(DBStatus.S_OK);
-            Int64 tmp = value.ToFileTime();
+            long tmp = value.ToFileTime();
             RowBinding.WriteInt64(ValueOffset, tmp);
         }
 
@@ -952,28 +952,28 @@ namespace System.Data.OleDb
             return DataReader().ResetChapter(IndexForAccessor, IndexWithinAccessor, RowBinding, ValueOffset);
         }
 
-        private SByte Value_I1()
+        private sbyte Value_I1()
         {
             Debug.Assert(NativeDBType.I1 == DbType, "Value_I1");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_I1");
             byte value = RowBinding.ReadByte(ValueOffset);
-            return unchecked((SByte)value);
+            return unchecked((sbyte)value);
         }
-        private void Value_I1(SByte value)
+        private void Value_I1(sbyte value)
         {
             Debug.Assert(NativeDBType.I1 == DbType, "Value_I1");
             LengthValue(0);
             StatusValue(DBStatus.S_OK);
-            RowBinding.WriteByte(ValueOffset, unchecked((Byte)value));
+            RowBinding.WriteByte(ValueOffset, unchecked((byte)value));
         }
 
-        internal Int16 Value_I2()
+        internal short Value_I2()
         {
             Debug.Assert(NativeDBType.I2 == DbType, "Value_I2");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_I2");
             return RowBinding.ReadInt16(ValueOffset);
         }
-        private void Value_I2(Int16 value)
+        private void Value_I2(short value)
         {
             Debug.Assert(NativeDBType.I2 == DbType, "Value_I2");
             LengthValue(0);
@@ -981,13 +981,13 @@ namespace System.Data.OleDb
             RowBinding.WriteInt16(ValueOffset, value);
         }
 
-        private Int32 Value_I4()
+        private int Value_I4()
         {
             Debug.Assert(NativeDBType.I4 == DbType, "Value_I4");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_I4");
             return RowBinding.ReadInt32(ValueOffset);
         }
-        private void Value_I4(Int32 value)
+        private void Value_I4(int value)
         {
             Debug.Assert(NativeDBType.I4 == DbType, "Value_I4");
             LengthValue(0);
@@ -995,13 +995,13 @@ namespace System.Data.OleDb
             RowBinding.WriteInt32(ValueOffset, value);
         }
 
-        private Int64 Value_I8()
+        private long Value_I8()
         {
             Debug.Assert(NativeDBType.I8 == DbType, "Value_I8");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_I8");
             return RowBinding.ReadInt64(ValueOffset);
         }
-        private void Value_I8(Int64 value)
+        private void Value_I8(long value)
         {
             Debug.Assert(NativeDBType.I8 == DbType, "Value_I8");
             LengthValue(0);
@@ -1089,13 +1089,13 @@ namespace System.Data.OleDb
             RowBinding.WriteIntPtr(ValueOffset, ptr);
         }
 
-        private Decimal Value_NUMERIC()
+        private decimal Value_NUMERIC()
         {
             Debug.Assert(NativeDBType.NUMERIC == DbType, "Value_NUMERIC");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_NUMERIC");
             return RowBinding.ReadNumeric(ValueOffset);
         }
-        private void Value_NUMERIC(Decimal value)
+        private void Value_NUMERIC(decimal value)
         {
             Debug.Assert(NativeDBType.NUMERIC == DbType, "Value_NUMERIC");
 
@@ -1110,14 +1110,14 @@ namespace System.Data.OleDb
             RowBinding.WriteNumeric(ValueOffset, value, ColumnBindingPrecision);
         }
 
-        private Single Value_R4()
+        private float Value_R4()
         {
             Debug.Assert(NativeDBType.R4 == DbType, "Value_R4");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_R4");
 
             return RowBinding.ReadSingle(ValueOffset);
         }
-        private void Value_R4(Single value)
+        private void Value_R4(float value)
         {
             Debug.Assert(NativeDBType.R4 == DbType, "Value_R4");
             LengthValue(0);
@@ -1125,14 +1125,14 @@ namespace System.Data.OleDb
             RowBinding.WriteSingle(ValueOffset, value);
         }
 
-        private Double Value_R8()
+        private double Value_R8()
         {
             Debug.Assert(NativeDBType.R8 == DbType, "Value_R8");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_R8");
 
             return RowBinding.ReadDouble(ValueOffset);
         }
-        private void Value_R8(Double value)
+        private void Value_R8(double value)
         {
             Debug.Assert(NativeDBType.R8 == DbType, "Value_I4");
             LengthValue(0);
@@ -1140,13 +1140,13 @@ namespace System.Data.OleDb
             RowBinding.WriteDouble(ValueOffset, value);
         }
 
-        private Byte Value_UI1()
+        private byte Value_UI1()
         {
             Debug.Assert(NativeDBType.UI1 == DbType, "Value_UI1");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_UI1");
             return RowBinding.ReadByte(ValueOffset);
         }
-        private void Value_UI1(Byte value)
+        private void Value_UI1(byte value)
         {
             Debug.Assert(NativeDBType.UI1 == DbType, "Value_UI1");
             LengthValue(0);
@@ -1154,49 +1154,49 @@ namespace System.Data.OleDb
             RowBinding.WriteByte(ValueOffset, value);
         }
 
-        internal UInt16 Value_UI2()
+        internal ushort Value_UI2()
         {
             Debug.Assert(NativeDBType.UI2 == DbType, "Value_UI2");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_UI2");
-            return unchecked((UInt16)RowBinding.ReadInt16(ValueOffset));
+            return unchecked((ushort)RowBinding.ReadInt16(ValueOffset));
         }
-        private void Value_UI2(UInt16 value)
+        private void Value_UI2(ushort value)
         {
             Debug.Assert(NativeDBType.UI2 == DbType, "Value_UI2");
             LengthValue(0);
             StatusValue(DBStatus.S_OK);
-            RowBinding.WriteInt16(ValueOffset, unchecked((Int16)value));
+            RowBinding.WriteInt16(ValueOffset, unchecked((short)value));
         }
 
-        internal UInt32 Value_UI4()
+        internal uint Value_UI4()
         {
             Debug.Assert(NativeDBType.UI4 == DbType, "Value_UI4");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_UI4");
-            return unchecked((UInt32)RowBinding.ReadInt32(ValueOffset));
+            return unchecked((uint)RowBinding.ReadInt32(ValueOffset));
         }
-        private void Value_UI4(UInt32 value)
+        private void Value_UI4(uint value)
         {
             Debug.Assert(NativeDBType.UI4 == DbType, "Value_UI4");
             LengthValue(0);
             StatusValue(DBStatus.S_OK);
-            RowBinding.WriteInt32(ValueOffset, unchecked((Int32)value));
+            RowBinding.WriteInt32(ValueOffset, unchecked((int)value));
         }
 
-        internal UInt64 Value_UI8()
+        internal ulong Value_UI8()
         {
             Debug.Assert(NativeDBType.UI8 == DbType, "Value_UI8");
             Debug.Assert(DBStatus.S_OK == StatusValue(), "Value_UI8");
-            return unchecked((UInt64)RowBinding.ReadInt64(ValueOffset));
+            return unchecked((ulong)RowBinding.ReadInt64(ValueOffset));
         }
-        private void Value_UI8(UInt64 value)
+        private void Value_UI8(ulong value)
         {
             Debug.Assert(NativeDBType.UI8 == DbType, "Value_UI8");
             LengthValue(0);
             StatusValue(DBStatus.S_OK);
-            RowBinding.WriteInt64(ValueOffset, unchecked((Int64)value));
+            RowBinding.WriteInt64(ValueOffset, unchecked((long)value));
         }
 
-        private String Value_WSTR()
+        private string Value_WSTR()
         {
             Debug.Assert(NativeDBType.WSTR == DbType, "Value_WSTR");
             Debug.Assert((DBStatus.S_OK == StatusValue()) || (DBStatus.S_TRUNCATED == StatusValue()), "Value_WSTR");
@@ -1204,7 +1204,7 @@ namespace System.Data.OleDb
             int byteCount = Math.Min(LengthValue(), ColumnBindingMaxLen - 2);
             return RowBinding.PtrToStringUni(ValueOffset, byteCount / 2);
         }
-        private void Value_WSTR(String value)
+        private void Value_WSTR(string value)
         {
             Debug.Assert(null != value, "Value_BYTES null");
             Debug.Assert(NativeDBType.WSTR == DbType, "Value_WSTR");
@@ -1247,9 +1247,9 @@ namespace System.Data.OleDb
             RowBinding.SetVariantValue(ValueOffset, value);
         }
 
-        internal Boolean ValueBoolean()
+        internal bool ValueBoolean()
         {
-            Boolean value;
+            bool value;
             switch (StatusValue())
             {
                 case DBStatus.S_OK:
@@ -1259,14 +1259,14 @@ namespace System.Data.OleDb
                             value = Value_BOOL();
                             break;
                         case NativeDBType.VARIANT:
-                            value = (Boolean)ValueVariant();
+                            value = (bool)ValueVariant();
                             break;
                         default:
                             throw ODB.ConversionRequired();
                     }
                     break;
                 default:
-                    throw CheckTypeValueStatusValue(typeof(Boolean));
+                    throw CheckTypeValueStatusValue(typeof(bool));
             }
             return value;
         }
@@ -1315,9 +1315,9 @@ namespace System.Data.OleDb
             return value;
         }
 
-        internal Byte ValueByte()
+        internal byte ValueByte()
         {
-            Byte value;
+            byte value;
             switch (StatusValue())
             {
                 case DBStatus.S_OK:
@@ -1327,14 +1327,14 @@ namespace System.Data.OleDb
                             value = Value_UI1();
                             break;
                         case NativeDBType.VARIANT:
-                            value = (Byte)ValueVariant();
+                            value = (byte)ValueVariant();
                             break;
                         default:
                             throw ODB.ConversionRequired();
                     }
                     break;
                 default:
-                    throw CheckTypeValueStatusValue(typeof(Byte));
+                    throw CheckTypeValueStatusValue(typeof(byte));
             }
             return value;
         }
@@ -1357,7 +1357,7 @@ namespace System.Data.OleDb
                         }
                         break;
                     default:
-                        throw CheckTypeValueStatusValue(typeof(String));
+                        throw CheckTypeValueStatusValue(typeof(string));
                 }
                 _value = value;
             }
@@ -1392,14 +1392,14 @@ namespace System.Data.OleDb
                     }
                     break;
                 default:
-                    throw CheckTypeValueStatusValue(typeof(Int16));
+                    throw CheckTypeValueStatusValue(typeof(short));
             }
             return value;
         }
 
-        internal Decimal ValueDecimal()
+        internal decimal ValueDecimal()
         {
-            Decimal value;
+            decimal value;
             switch (StatusValue())
             {
                 case DBStatus.S_OK:
@@ -1415,17 +1415,17 @@ namespace System.Data.OleDb
                             value = Value_NUMERIC();
                             break;
                         case NativeDBType.UI8:
-                            value = (Decimal)Value_UI8();
+                            value = (decimal)Value_UI8();
                             break;
                         case NativeDBType.VARIANT:
-                            value = (Decimal)ValueVariant();
+                            value = (decimal)ValueVariant();
                             break;
                         default:
                             throw ODB.ConversionRequired();
                     }
                     break;
                 default:
-                    throw CheckTypeValueStatusValue(typeof(Int16));
+                    throw CheckTypeValueStatusValue(typeof(short));
             }
             return value;
         }
@@ -1446,14 +1446,14 @@ namespace System.Data.OleDb
                     }
                     break;
                 default:
-                    throw CheckTypeValueStatusValue(typeof(Int16));
+                    throw CheckTypeValueStatusValue(typeof(short));
             }
             return value;
         }
 
-        internal Int16 ValueInt16()
+        internal short ValueInt16()
         {
-            Int16 value;
+            short value;
             switch (StatusValue())
             {
                 case DBStatus.S_OK:
@@ -1463,17 +1463,17 @@ namespace System.Data.OleDb
                             value = Value_I2();
                             break;
                         case NativeDBType.I1:
-                            value = (Int16)Value_I1();
+                            value = (short)Value_I1();
                             break;
                         case NativeDBType.VARIANT:
                             object variant = ValueVariant();
-                            if (variant is SByte)
+                            if (variant is sbyte)
                             {
-                                value = (Int16)(SByte)variant;
+                                value = (short)(sbyte)variant;
                             }
                             else
                             {
-                                value = (Int16)variant;
+                                value = (short)variant;
                             }
                             break;
                         default:
@@ -1481,14 +1481,14 @@ namespace System.Data.OleDb
                     }
                     break;
                 default:
-                    throw CheckTypeValueStatusValue(typeof(Int16));
+                    throw CheckTypeValueStatusValue(typeof(short));
             }
             return value;
         }
 
-        internal Int32 ValueInt32()
+        internal int ValueInt32()
         {
-            Int32 value;
+            int value;
             switch (StatusValue())
             {
                 case DBStatus.S_OK:
@@ -1498,17 +1498,17 @@ namespace System.Data.OleDb
                             value = Value_I4();
                             break;
                         case NativeDBType.UI2:
-                            value = (Int32)Value_UI2();
+                            value = (int)Value_UI2();
                             break;
                         case NativeDBType.VARIANT:
                             object variant = ValueVariant();
-                            if (variant is UInt16)
+                            if (variant is ushort)
                             {
-                                value = (Int32)(UInt16)variant;
+                                value = (int)(ushort)variant;
                             }
                             else
                             {
-                                value = (Int32)variant;
+                                value = (int)variant;
                             }
                             break;
                         default:
@@ -1516,14 +1516,14 @@ namespace System.Data.OleDb
                     }
                     break;
                 default:
-                    throw CheckTypeValueStatusValue(typeof(Int32));
+                    throw CheckTypeValueStatusValue(typeof(int));
             }
             return value;
         }
 
-        internal Int64 ValueInt64()
+        internal long ValueInt64()
         {
-            Int64 value;
+            long value;
             switch (StatusValue())
             {
                 case DBStatus.S_OK:
@@ -1533,17 +1533,17 @@ namespace System.Data.OleDb
                             value = Value_I8();
                             break;
                         case NativeDBType.UI4:
-                            value = (Int64)Value_UI4();
+                            value = (long)Value_UI4();
                             break;
                         case NativeDBType.VARIANT:
                             object variant = ValueVariant();
-                            if (variant is UInt32)
+                            if (variant is uint)
                             {
-                                value = (Int64)(UInt32)variant;
+                                value = (long)(uint)variant;
                             }
                             else
                             {
-                                value = (Int64)variant;
+                                value = (long)variant;
                             }
                             break;
                         default:
@@ -1551,14 +1551,14 @@ namespace System.Data.OleDb
                     }
                     break;
                 default:
-                    throw CheckTypeValueStatusValue(typeof(Int64));
+                    throw CheckTypeValueStatusValue(typeof(long));
             }
             return value;
         }
 
-        internal Single ValueSingle()
+        internal float ValueSingle()
         {
-            Single value;
+            float value;
             switch (StatusValue())
             {
                 case DBStatus.S_OK:
@@ -1568,21 +1568,21 @@ namespace System.Data.OleDb
                             value = Value_R4();
                             break;
                         case NativeDBType.VARIANT:
-                            value = (Single)ValueVariant();
+                            value = (float)ValueVariant();
                             break;
                         default:
                             throw ODB.ConversionRequired();
                     }
                     break;
                 default:
-                    throw CheckTypeValueStatusValue(typeof(Single));
+                    throw CheckTypeValueStatusValue(typeof(float));
             }
             return value;
         }
 
-        internal Double ValueDouble()
+        internal double ValueDouble()
         {
-            Double value;
+            double value;
             switch (StatusValue())
             {
                 case DBStatus.S_OK:
@@ -1592,21 +1592,21 @@ namespace System.Data.OleDb
                             value = Value_R8();
                             break;
                         case NativeDBType.VARIANT:
-                            value = (Double)ValueVariant();
+                            value = (double)ValueVariant();
                             break;
                         default:
                             throw ODB.ConversionRequired();
                     }
                     break;
                 default:
-                    throw CheckTypeValueStatusValue(typeof(Double));
+                    throw CheckTypeValueStatusValue(typeof(double));
             }
             return value;
         }
 
         internal string ValueString()
         {
-            string value = (String)_value;
+            string value = (string)_value;
             if (null == value)
             {
                 switch (StatusValue())
@@ -1618,7 +1618,7 @@ namespace System.Data.OleDb
                                 value = Value_BSTR(); // String
                                 break;
                             case NativeDBType.VARIANT:
-                                value = (String)ValueVariant(); // Object
+                                value = (string)ValueVariant(); // Object
                                 break;
                             case NativeDBType.WSTR:
                                 value = Value_WSTR(); // String
@@ -1644,7 +1644,7 @@ namespace System.Data.OleDb
                         }
                         break;
                     default:
-                        throw CheckTypeValueStatusValue(typeof(String));
+                        throw CheckTypeValueStatusValue(typeof(string));
                 }
                 _value = value;
             }
index 5b99667..6af2dd9 100644 (file)
@@ -8,7 +8,7 @@ using System.Text;
 
 namespace System.Data.OleDb
 {
-    sealed internal class Bindings
+    internal sealed class Bindings
     {
         private readonly tagDBPARAMBINDINFO[] _bindInfo;
         private readonly tagDBBINDING[] _dbbindings;
index 92c0afb..9e5a7e0 100644 (file)
@@ -211,7 +211,7 @@ namespace System.Data.Common
                 if (useOdbcRules)
                 {
                     if ((0 < keyValue.Length) &&
-                        (('{' == keyValue[0]) || (0 <= keyValue.IndexOf(';')) || (0 == String.Compare(DbConnectionStringKeywords.Driver, keyName, StringComparison.OrdinalIgnoreCase))) &&
+                        (('{' == keyValue[0]) || (0 <= keyValue.IndexOf(';')) || (0 == string.Compare(DbConnectionStringKeywords.Driver, keyName, StringComparison.OrdinalIgnoreCase))) &&
                         !ConnectionStringQuoteOdbcValueRegex.IsMatch(keyValue))
                     {
                         // always quote Driver value (required for ODBC Version 2.65 and earlier)
@@ -294,7 +294,7 @@ namespace System.Data.Common
         {
             try
             {
-                return System.Int32.Parse(stringValue, System.Globalization.NumberStyles.Integer, CultureInfo.InvariantCulture);
+                return int.Parse(stringValue, System.Globalization.NumberStyles.Integer, CultureInfo.InvariantCulture);
             }
             catch (FormatException e)
             {
@@ -501,7 +501,7 @@ namespace System.Data.Common
         static private string GetKeyName(StringBuilder buffer)
         {
             int count = buffer.Length;
-            while ((0 < count) && Char.IsWhiteSpace(buffer[count - 1]))
+            while ((0 < count) && char.IsWhiteSpace(buffer[count - 1]))
             {
                 count--; // trailing whitespace
             }
@@ -514,11 +514,11 @@ namespace System.Data.Common
             int index = 0;
             if (trimWhitespace)
             {
-                while ((index < count) && Char.IsWhiteSpace(buffer[index]))
+                while ((index < count) && char.IsWhiteSpace(buffer[index]))
                 {
                     index++; // leading whitespace
                 }
-                while ((0 < count) && Char.IsWhiteSpace(buffer[count - 1]))
+                while ((0 < count) && char.IsWhiteSpace(buffer[count - 1]))
                 {
                     count--; // trailing whitespace
                 }
@@ -563,13 +563,13 @@ namespace System.Data.Common
                 switch (parserState)
                 {
                     case ParserState.NothingYet: // [\\s;]*
-                        if ((';' == currentChar) || Char.IsWhiteSpace(currentChar))
+                        if ((';' == currentChar) || char.IsWhiteSpace(currentChar))
                         {
                             continue;
                         }
                         if ('\0' == currentChar)
                         { parserState = ParserState.NullTermination; continue; }
-                        if (Char.IsControl(currentChar))
+                        if (char.IsControl(currentChar))
                         { throw ADP.ConnectionStringSyntax(startposition); }
                         startposition = currentPosition;
                         if ('=' != currentChar)
@@ -586,9 +586,9 @@ namespace System.Data.Common
                     case ParserState.Key: // (?<key>([^=\\s\\p{Cc}]|\\s+[^=\\s\\p{Cc}]|\\s+==|==)+)
                         if ('=' == currentChar)
                         { parserState = ParserState.KeyEqual; continue; }
-                        if (Char.IsWhiteSpace(currentChar))
+                        if (char.IsWhiteSpace(currentChar))
                         { break; }
-                        if (Char.IsControl(currentChar))
+                        if (char.IsControl(currentChar))
                         { throw ADP.ConnectionStringSyntax(startposition); }
                         break;
 
@@ -603,7 +603,7 @@ namespace System.Data.Common
                         goto case ParserState.KeyEnd;
 
                     case ParserState.KeyEnd:
-                        if (Char.IsWhiteSpace(currentChar))
+                        if (char.IsWhiteSpace(currentChar))
                         { continue; }
                         if (useOdbcRules)
                         {
@@ -621,15 +621,15 @@ namespace System.Data.Common
                         { goto ParserExit; }
                         if ('\0' == currentChar)
                         { goto ParserExit; }
-                        if (Char.IsControl(currentChar))
+                        if (char.IsControl(currentChar))
                         { throw ADP.ConnectionStringSyntax(startposition); }
                         parserState = ParserState.UnquotedValue;
                         break;
 
                     case ParserState.UnquotedValue: // "((?![\"'\\s])" + "([^;\\s\\p{Cc}]|\\s+[^;\\s\\p{Cc}])*" + "(?<![\"']))"
-                        if (Char.IsWhiteSpace(currentChar))
+                        if (char.IsWhiteSpace(currentChar))
                         { break; }
-                        if (Char.IsControl(currentChar) || ';' == currentChar)
+                        if (char.IsControl(currentChar) || ';' == currentChar)
                         { goto ParserExit; }
                         break;
 
@@ -676,7 +676,7 @@ namespace System.Data.Common
                         goto case ParserState.QuotedValueEnd;
 
                     case ParserState.QuotedValueEnd:
-                        if (Char.IsWhiteSpace(currentChar))
+                        if (char.IsWhiteSpace(currentChar))
                         { continue; }
                         if (';' == currentChar)
                         { goto ParserExit; }
@@ -687,7 +687,7 @@ namespace System.Data.Common
                     case ParserState.NullTermination: // [\\s;\u0000]*
                         if ('\0' == currentChar)
                         { continue; }
-                        if (Char.IsWhiteSpace(currentChar))
+                        if (char.IsWhiteSpace(currentChar))
                         { continue; }
                         throw ADP.ConnectionStringSyntax(currentPosition);
 
@@ -767,9 +767,9 @@ namespace System.Data.Common
             {
 #if DEBUG
                 bool compValue = ConnectionStringValidKeyRegex.IsMatch(keyname);
-                Debug.Assert(((0 < keyname.Length) && (';' != keyname[0]) && !Char.IsWhiteSpace(keyname[0]) && (-1 == keyname.IndexOf('\u0000'))) == compValue, "IsValueValid mismatch with regex");
+                Debug.Assert(((0 < keyname.Length) && (';' != keyname[0]) && !char.IsWhiteSpace(keyname[0]) && (-1 == keyname.IndexOf('\u0000'))) == compValue, "IsValueValid mismatch with regex");
 #endif
-                return ((0 < keyname.Length) && (';' != keyname[0]) && !Char.IsWhiteSpace(keyname[0]) && (-1 == keyname.IndexOf('\u0000')));
+                return ((0 < keyname.Length) && (';' != keyname[0]) && !char.IsWhiteSpace(keyname[0]) && (-1 == keyname.IndexOf('\u0000')));
             }
             return false;
         }
index ae318e8..778abea 100644 (file)
@@ -50,7 +50,7 @@ namespace System.Data.Common
             get { return false; }
         }
 
-        Object System.Collections.ICollection.SyncRoot
+        object System.Collections.ICollection.SyncRoot
         {
             get { return _items; }
         }
@@ -113,7 +113,7 @@ namespace System.Data.Common
                 }
             }
 
-            Object System.Collections.IEnumerator.Current
+            object System.Collections.IEnumerator.Current
             {
                 get
                 {
@@ -148,7 +148,7 @@ namespace System.Data.Common
                     else if (StringComparer.OrdinalIgnoreCase.Equals(tmp, "false") || StringComparer.OrdinalIgnoreCase.Equals(tmp, "no"))
                         return false;
                 }
-                return Boolean.Parse(svalue);
+                return bool.Parse(svalue);
             }
             try
             {
@@ -156,7 +156,7 @@ namespace System.Data.Common
             }
             catch (InvalidCastException e)
             {
-                throw ADP.ConvertFailed(value.GetType(), typeof(Boolean), e);
+                throw ADP.ConvertFailed(value.GetType(), typeof(bool), e);
             }
         }
 
@@ -168,7 +168,7 @@ namespace System.Data.Common
             }
             catch (InvalidCastException e)
             {
-                throw ADP.ConvertFailed(value.GetType(), typeof(Int32), e);
+                throw ADP.ConvertFailed(value.GetType(), typeof(int), e);
             }
         }
 
@@ -180,7 +180,7 @@ namespace System.Data.Common
             }
             catch (InvalidCastException e)
             {
-                throw ADP.ConvertFailed(value.GetType(), typeof(String), e);
+                throw ADP.ConvertFailed(value.GetType(), typeof(string), e);
             }
         }
     }
index 1ab9bf8..f5baccd 100644 (file)
@@ -227,18 +227,18 @@ namespace System.Data.OleDb
 
         private byte ValuePrecisionCore(object value)
         { // V1.2.3300
-            if (value is Decimal)
+            if (value is decimal)
             {
-                return ((System.Data.SqlTypes.SqlDecimal)(Decimal)value).Precision;
+                return ((System.Data.SqlTypes.SqlDecimal)(decimal)value).Precision;
             }
             return 0;
         }
 
         private byte ValueScaleCore(object value)
         { // V1.2.3300
-            if (value is Decimal)
+            if (value is decimal)
             {
-                return (byte)((Decimal.GetBits((Decimal)value)[3] & 0x00ff0000) >> 0x10);
+                return (byte)((decimal.GetBits((decimal)value)[3] & 0x00ff0000) >> 0x10);
             }
             return 0;
         }
index 6d87124..4d38531 100644 (file)
@@ -10,9 +10,9 @@ using System.Runtime.InteropServices;
 
 namespace System.Data.OleDb
 {
-    sealed internal class DBPropSet : SafeHandle
+    internal sealed class DBPropSet : SafeHandle
     {
-        private readonly Int32 propertySetCount;
+        private readonly int propertySetCount;
 
         // stores the exception with last error.HRESULT from IDBProperties.GetProperties
         private Exception lastErrorFromProvider;
@@ -101,7 +101,7 @@ namespace System.Data.OleDb
         {
             // note: OleDbHResult is actually a simple wrapper over HRESULT with OLEDB-specific codes
             UnsafeNativeMethods.IErrorInfo errorInfo = null;
-            string message = String.Empty;
+            string message = string.Empty;
 
             OleDbHResult errorInfoHr = UnsafeNativeMethods.GetErrorInfo(0, out errorInfo);  // 0 - IErrorInfo exists, 1 - no IErrorInfo
             if ((errorInfoHr == OleDbHResult.S_OK) && (errorInfo != null))
index 02d113d..e38a1af 100644 (file)
@@ -30,8 +30,8 @@ namespace System.Data.Common
 
             void JoinTransaction(
                 [In, MarshalAs(UnmanagedType.Interface)] object punkTransactionCoord,
-                [In] Int32 isoLevel,
-                [In] Int32 isoFlags,
+                [In] int isoLevel,
+                [In] int isoFlags,
                 [In] IntPtr pOtherOptions);
         }
 
index 4e35713..c1b81d8 100644 (file)
@@ -1142,7 +1142,7 @@ namespace System.Data.OleDb
             {
                 OleDbHResult hr;
 
-                String commandText = ExpandCommandText();
+                string commandText = ExpandCommandText();
 
                 hr = _icommandText.SetCommandText(ref ODB.DBGUID_DEFAULT, commandText);
 
index f1c3550..a276724 100644 (file)
@@ -156,13 +156,13 @@ namespace System.Data.OleDb
                 string quotePrefix, quoteSuffix;
                 connection.GetLiteralQuotes(ADP.DeriveParameters, out quotePrefix, out quoteSuffix);
 
-                Object[] parsed = MultipartIdentifier.ParseMultipartIdentifier(command.CommandText, quotePrefix, quoteSuffix, '.', 4, true, SR.OLEDB_OLEDBCommandText, false);
+                object[] parsed = MultipartIdentifier.ParseMultipartIdentifier(command.CommandText, quotePrefix, quoteSuffix, '.', 4, true, SR.OLEDB_OLEDBCommandText, false);
                 if (null == parsed[3])
                 {
                     throw ADP.NoStoredProcedureExists(command.CommandText);
                 }
 
-                Object[] restrictions = new object[4];
+                object[] restrictions = new object[4];
                 object value;
 
                 // Parse returns an enforced 4 part array
@@ -261,12 +261,12 @@ namespace System.Data.OleDb
                                 if ((null != numericPrecision) && !dataRow.IsNull(numericPrecision, DataRowVersion.Default))
                                 {
                                     // @devnote: unguarded cast from Int16 to Byte
-                                    parameter.PrecisionInternal = (Byte)Convert.ToInt16(dataRow[numericPrecision], CultureInfo.InvariantCulture);
+                                    parameter.PrecisionInternal = (byte)Convert.ToInt16(dataRow[numericPrecision], CultureInfo.InvariantCulture);
                                 }
                                 if ((null != numericScale) && !dataRow.IsNull(numericScale, DataRowVersion.Default))
                                 {
                                     // @devnote: unguarded cast from Int16 to Byte
-                                    parameter.ScaleInternal = (Byte)Convert.ToInt16(dataRow[numericScale], CultureInfo.InvariantCulture);
+                                    parameter.ScaleInternal = (byte)Convert.ToInt16(dataRow[numericScale], CultureInfo.InvariantCulture);
                                 }
                                 break;
                             case OleDbType.VarBinary:
@@ -317,7 +317,7 @@ namespace System.Data.OleDb
                 }
                 if ((0 == plist.Length) && connection.SupportSchemaRowset(OleDbSchemaGuid.Procedures))
                 {
-                    restrictions = new Object[4] { null, null, command.CommandText, null };
+                    restrictions = new object[4] { null, null, command.CommandText, null };
                     table = connection.GetSchemaRowset(OleDbSchemaGuid.Procedures, restrictions);
                     if (0 == table.Rows.Count)
                     {
@@ -327,7 +327,7 @@ namespace System.Data.OleDb
             }
             else if (connection.SupportSchemaRowset(OleDbSchemaGuid.Procedures))
             {
-                Object[] restrictions = new Object[4] { null, null, command.CommandText, null };
+                object[] restrictions = new object[4] { null, null, command.CommandText, null };
                 DataTable table = connection.GetSchemaRowset(OleDbSchemaGuid.Procedures, restrictions);
                 if (0 == table.Rows.Count)
                 {
@@ -443,7 +443,7 @@ namespace System.Data.OleDb
                 }
             }
 
-            String unquotedIdentifier;
+            string unquotedIdentifier;
             // ignoring the return value because it is acceptable for the quotedString to not be quoted in this
             // context.
             ADP.RemoveStringQuotes(quotePrefix, quoteSuffix, quotedIdentifier, out unquotedIdentifier);
index ba23a9b..8b96c2e 100644 (file)
@@ -171,7 +171,7 @@ namespace System.Data.OleDb
         Browsable(true),
         DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden),
         ]
-        public String Provider
+        public string Provider
         {
             get
             {
@@ -216,7 +216,7 @@ namespace System.Data.OleDb
             if (IsOpen)
             {
                 object value = GetDataSourcePropertyValue(OleDbPropertySetGuid.DataSourceInfo, ODB.DBPROP_CONNECTIONSTATUS);
-                if (value is Int32)
+                if (value is int)
                 {
                     int connectionStatus = (int)value;
                     switch (connectionStatus)
@@ -293,7 +293,7 @@ namespace System.Data.OleDb
 
             int quotedIdentifierCase;
             object value = GetDataSourcePropertyValue(OleDbPropertySetGuid.DataSourceInfo, ODB.DBPROP_QUOTEDIDENTIFIERCASE);
-            if (value is Int32)
+            if (value is int)
             {// not OleDbPropertyStatus
                 quotedIdentifierCase = (int)value;
             }
index ed61103..d2ca3c0 100644 (file)
@@ -12,7 +12,7 @@ using System.Runtime.Versioning;
 
 namespace System.Data.OleDb
 {
-    sealed internal class OleDbConnectionFactory : DbConnectionFactory
+    internal sealed class OleDbConnectionFactory : DbConnectionFactory
     {
         private OleDbConnectionFactory() : base() { }
         // At this time, the OleDb Managed Provider doesn't have any connection pool
@@ -56,7 +56,7 @@ namespace System.Data.OleDb
 
             NameValueCollection settings = (NameValueCollection)ConfigurationManager.GetSection("system.data.oledb");
             Stream XMLStream = null;
-            String providerFileName = oleDbOuterConnection.GetDataSourcePropertyValue(OleDbPropertySetGuid.DataSourceInfo, ODB.DBPROP_PROVIDERFILENAME) as string;
+            string providerFileName = oleDbOuterConnection.GetDataSourcePropertyValue(OleDbPropertySetGuid.DataSourceInfo, ODB.DBPROP_PROVIDERFILENAME) as string;
 
             if (settings != null)
             {
index 6c68e31..69d7281 100644 (file)
@@ -14,7 +14,7 @@ namespace System.Data.OleDb
 {
     using SysTx = Transactions;
 
-    sealed internal class OleDbConnectionInternal : DbConnectionInternal, IDisposable
+    internal sealed class OleDbConnectionInternal : DbConnectionInternal, IDisposable
     {
         static private volatile OleDbServicesWrapper idataInitialize;
         static private object dataInitializeLock = new object();
@@ -394,12 +394,12 @@ namespace System.Data.OleDb
 
                 DataTable table = new DataTable("DbInfoLiterals");
                 table.Locale = CultureInfo.InvariantCulture;
-                DataColumn literalName = new DataColumn("LiteralName", typeof(String));
-                DataColumn literalValue = new DataColumn("LiteralValue", typeof(String));
-                DataColumn invalidChars = new DataColumn("InvalidChars", typeof(String));
-                DataColumn invalidStart = new DataColumn("InvalidStartingChars", typeof(String));
-                DataColumn literal = new DataColumn("Literal", typeof(Int32));
-                DataColumn maxlen = new DataColumn("Maxlen", typeof(Int32));
+                DataColumn literalName = new DataColumn("LiteralName", typeof(string));
+                DataColumn literalValue = new DataColumn("LiteralValue", typeof(string));
+                DataColumn invalidChars = new DataColumn("InvalidChars", typeof(string));
+                DataColumn invalidStart = new DataColumn("InvalidStartingChars", typeof(string));
+                DataColumn literal = new DataColumn("Literal", typeof(int));
+                DataColumn maxlen = new DataColumn("Maxlen", typeof(int));
 
                 table.Columns.Add(literalName);
                 table.Columns.Add(literalValue);
@@ -451,7 +451,7 @@ namespace System.Data.OleDb
         {
             DataTable table = new DataTable(ODB.DbInfoKeywords);
             table.Locale = CultureInfo.InvariantCulture;
-            DataColumn keyword = new DataColumn(ODB.Keyword, typeof(String));
+            DataColumn keyword = new DataColumn(ODB.Keyword, typeof(string));
             table.Columns.Add(keyword);
 
             if (!AddInfoKeywordsToTable(table, keyword))
@@ -503,7 +503,7 @@ namespace System.Data.OleDb
             table.Locale = CultureInfo.InvariantCulture;
 
             DataColumn schemaGuid = new DataColumn(ODB.Schema, typeof(Guid));
-            DataColumn restrictionSupport = new DataColumn(ODB.RestrictionSupport, typeof(Int32));
+            DataColumn restrictionSupport = new DataColumn(ODB.RestrictionSupport, typeof(int));
 
             table.Columns.Add(schemaGuid);
             table.Columns.Add(restrictionSupport);
index 71421c1..ea6d15c 100644 (file)
@@ -91,7 +91,7 @@ namespace System.Data.OleDb
         internal OleDbConnectionString(string connectionString, bool validate) : base(connectionString)
         {
             string prompt = this[KEY.Prompt];
-            PossiblePrompt = ((!ADP.IsEmpty(prompt) && (0 != String.Compare(prompt, VALUES.NoPrompt, StringComparison.OrdinalIgnoreCase)))
+            PossiblePrompt = ((!ADP.IsEmpty(prompt) && (0 != string.Compare(prompt, VALUES.NoPrompt, StringComparison.OrdinalIgnoreCase)))
                               || !ADP.IsEmpty(this[KEY.WindowHandle]));
 
             if (!IsEmpty)
@@ -180,7 +180,7 @@ namespace System.Data.OleDb
             if (!_hasSqlSupport)
             {
                 object value = connection.GetDataSourcePropertyValue(OleDbPropertySetGuid.DataSourceInfo, ODB.DBPROP_SQLSUPPORT);
-                if (value is Int32)
+                if (value is int)
                 { // not OleDbPropertyStatus
                     sqlSupport = (int)value;
                 }
@@ -211,7 +211,7 @@ namespace System.Data.OleDb
             if (!_hasSupportMultipleResults)
             {
                 object value = connection.GetDataSourcePropertyValue(OleDbPropertySetGuid.DataSourceInfo, ODB.DBPROP_MULTIPLERESULTS);
-                if (value is Int32)
+                if (value is int)
                 {// not OleDbPropertyStatus
                     supportMultipleResults = (ODB.DBPROPVAL_MR_NOTSUPPORTED != (int)value);
                 }
@@ -230,7 +230,7 @@ namespace System.Data.OleDb
                 if (!UDL._PoolSizeInit)
                 {
                     object value = ADP.LocalMachineRegistryValue(UDL.Location, UDL.Pooling);
-                    if (value is Int32)
+                    if (value is int)
                     {
                         poolsize = (int)value;
                         poolsize = ((0 < poolsize) ? poolsize : 0);
@@ -310,7 +310,7 @@ namespace System.Data.OleDb
                     }
                     else
                     {
-                        byte[] bytes = new Byte[hdrlength];
+                        byte[] bytes = new byte[hdrlength];
                         int count = fstream.Read(bytes, 0, bytes.Length);
                         if (count < hdrlength)
                         {
@@ -322,7 +322,7 @@ namespace System.Data.OleDb
                         }
                         else
                         { // please verify header before allocating memory block for connection string
-                            bytes = new Byte[length - hdrlength];
+                            bytes = new byte[length - hdrlength];
                             count = fstream.Read(bytes, 0, bytes.Length);
                             connectionString = System.Text.Encoding.Unicode.GetString(bytes, 0, count);
                         }
@@ -389,7 +389,7 @@ namespace System.Data.OleDb
             bool hasOleDBServices = (base.ContainsKey(KEY.Ole_DB_Services) && !ADP.IsEmpty((string)base[KEY.Ole_DB_Services]));
             if (!hasOleDBServices)
             { // don't touch registry if they have OLE DB Services
-                string classid = (string)ADP.ClassesRootRegistryValue(progid + "\\CLSID", String.Empty);
+                string classid = (string)ADP.ClassesRootRegistryValue(progid + "\\CLSID", string.Empty);
                 if ((null != classid) && (0 < classid.Length))
                 {
                     // CLSID detection of 'Microsoft OLE DB Provider for ODBC Drivers'
index b6ee6eb..132492b 100644 (file)
@@ -488,11 +488,11 @@ namespace System.Data.OleDb
                                                                 {
                                                                     info._defaultValue = "";
                                                                 }
-                                                                else if (typeof(Int32) == info._type)
+                                                                else if (typeof(int) == info._type)
                                                                 {
                                                                     info._defaultValue = 0;
                                                                 }
-                                                                else if (typeof(Boolean) == info._type)
+                                                                else if (typeof(bool) == info._type)
                                                                 {
                                                                     info._defaultValue = false;
                                                                 }
@@ -616,8 +616,8 @@ namespace System.Data.OleDb
                 string svalue = (value as string);
                 if (null != svalue)
                 {
-                    Int32 services;
-                    if (Int32.TryParse(svalue, out services))
+                    int services;
+                    if (int.TryParse(svalue, out services))
                     {
                         return services;
                     }
@@ -651,7 +651,7 @@ namespace System.Data.OleDb
 
             public override object ConvertTo(ITypeDescriptorContext context, System.Globalization.CultureInfo culture, object value, Type destinationType)
             {
-                if ((typeof(string) == destinationType) && (null != value) && (typeof(Int32) == value.GetType()))
+                if ((typeof(string) == destinationType) && (null != value) && (typeof(int) == value.GetType()))
                 {
                     return Enum.Format(typeof(OleDbServiceValues), ((OleDbServiceValues)(int)value), "G");
                 }
@@ -688,7 +688,7 @@ namespace System.Data.OleDb
             }
         }
 
-        sealed internal class OleDbConnectionStringBuilderConverter : ExpandableObjectConverter
+        internal sealed class OleDbConnectionStringBuilderConverter : ExpandableObjectConverter
         {
             // converter classes should have public ctor
             public OleDbConnectionStringBuilderConverter()
index e2faeb1..dc2f81f 100644 (file)
@@ -180,7 +180,7 @@ namespace System.Data.OleDb
             return FillFromADODB((object)dataSet, ADODBRecordSet, srcTable, true);
         }
 
-        private int FillFromADODB(Object data, object adodb, string srcTable, bool multipleResults)
+        private int FillFromADODB(object data, object adodb, string srcTable, bool multipleResults)
         {
             Debug.Assert(null != data, "FillFromADODB: null data object");
             Debug.Assert(null != adodb, "FillFromADODB: null ADODB");
@@ -261,7 +261,7 @@ namespace System.Data.OleDb
                                 UnsafeNativeMethods.IErrorInfo errorInfo = null;
                                 UnsafeNativeMethods.GetErrorInfo(0, out errorInfo);
 
-                                string message = String.Empty;
+                                string message = string.Empty;
                                 if (null != errorInfo)
                                 {
                                     OleDbHResult hresult = ODB.GetErrorDescription(errorInfo, hr, out message);
@@ -309,7 +309,7 @@ namespace System.Data.OleDb
         //    return base.Fill(dataTable, dataReader);
         //}
 
-        private int FillFromRecordset(Object data, UnsafeNativeMethods.ADORecordsetConstruction recordset, string srcTable, out bool incrementResultCount)
+        private int FillFromRecordset(object data, UnsafeNativeMethods.ADORecordsetConstruction recordset, string srcTable, out bool incrementResultCount)
         {
             incrementResultCount = false;
 
@@ -370,7 +370,7 @@ namespace System.Data.OleDb
             return 0;
         }
 
-        private int FillFromRecord(Object data, UnsafeNativeMethods.ADORecordConstruction record, string srcTable)
+        private int FillFromRecord(object data, UnsafeNativeMethods.ADORecordConstruction record, string srcTable)
         {
             object result = null;
             try
@@ -435,7 +435,7 @@ namespace System.Data.OleDb
             {
                 UnsafeNativeMethods.IErrorInfo errorInfo = null;
                 UnsafeNativeMethods.GetErrorInfo(0, out errorInfo);
-                string message = String.Empty;
+                string message = string.Empty;
                 if (null != errorInfo)
                 {
                     OleDbHResult hresult = ODB.GetErrorDescription(errorInfo, hr, out message);
index 07861ac..54ab006 100644 (file)
@@ -142,7 +142,7 @@ namespace System.Data.OleDb
             }
         }
 
-        public override Int32 FieldCount
+        public override int FieldCount
         {
             get
             {
@@ -167,7 +167,7 @@ namespace System.Data.OleDb
             }
         }
 
-        public override Boolean IsClosed
+        public override bool IsClosed
         {
             get
             { // if we have a rowset or multipleresults, we may have more to read
@@ -199,7 +199,7 @@ namespace System.Data.OleDb
             }
         }*/
 
-        public override object this[Int32 index]
+        public override object this[int index]
         {
             get
             {
@@ -207,7 +207,7 @@ namespace System.Data.OleDb
             }
         }
 
-        public override object this[String name]
+        public override object this[string name]
         {
             get
             {
@@ -324,29 +324,29 @@ namespace System.Data.OleDb
             schemaTable.Locale = CultureInfo.InvariantCulture;
             schemaTable.MinimumCapacity = metadata.Length;
 
-            DataColumn name = new DataColumn("ColumnName", typeof(System.String));
-            DataColumn ordinal = new DataColumn("ColumnOrdinal", typeof(System.Int32));
-            DataColumn size = new DataColumn("ColumnSize", typeof(System.Int32));
-            DataColumn precision = new DataColumn("NumericPrecision", typeof(System.Int16));
-            DataColumn scale = new DataColumn("NumericScale", typeof(System.Int16));
+            DataColumn name = new DataColumn("ColumnName", typeof(string));
+            DataColumn ordinal = new DataColumn("ColumnOrdinal", typeof(int));
+            DataColumn size = new DataColumn("ColumnSize", typeof(int));
+            DataColumn precision = new DataColumn("NumericPrecision", typeof(short));
+            DataColumn scale = new DataColumn("NumericScale", typeof(short));
 
             DataColumn dataType = new DataColumn("DataType", typeof(System.Type));
-            DataColumn providerType = new DataColumn("ProviderType", typeof(System.Int32));
+            DataColumn providerType = new DataColumn("ProviderType", typeof(int));
 
-            DataColumn isLong = new DataColumn("IsLong", typeof(System.Boolean));
-            DataColumn allowDBNull = new DataColumn("AllowDBNull", typeof(System.Boolean));
-            DataColumn isReadOnly = new DataColumn("IsReadOnly", typeof(System.Boolean));
-            DataColumn isRowVersion = new DataColumn("IsRowVersion", typeof(System.Boolean));
+            DataColumn isLong = new DataColumn("IsLong", typeof(bool));
+            DataColumn allowDBNull = new DataColumn("AllowDBNull", typeof(bool));
+            DataColumn isReadOnly = new DataColumn("IsReadOnly", typeof(bool));
+            DataColumn isRowVersion = new DataColumn("IsRowVersion", typeof(bool));
 
-            DataColumn isUnique = new DataColumn("IsUnique", typeof(System.Boolean));
-            DataColumn isKey = new DataColumn("IsKey", typeof(System.Boolean));
-            DataColumn isAutoIncrement = new DataColumn("IsAutoIncrement", typeof(System.Boolean));
-            DataColumn isHidden = new DataColumn("IsHidden", typeof(System.Boolean));
+            DataColumn isUnique = new DataColumn("IsUnique", typeof(bool));
+            DataColumn isKey = new DataColumn("IsKey", typeof(bool));
+            DataColumn isAutoIncrement = new DataColumn("IsAutoIncrement", typeof(bool));
+            DataColumn isHidden = new DataColumn("IsHidden", typeof(bool));
 
-            DataColumn baseSchemaName = new DataColumn("BaseSchemaName", typeof(System.String));
-            DataColumn baseCatalogName = new DataColumn("BaseCatalogName", typeof(System.String));
-            DataColumn baseTableName = new DataColumn("BaseTableName", typeof(System.String));
-            DataColumn baseColumnName = new DataColumn("BaseColumnName", typeof(System.String));
+            DataColumn baseSchemaName = new DataColumn("BaseSchemaName", typeof(string));
+            DataColumn baseCatalogName = new DataColumn("BaseCatalogName", typeof(string));
+            DataColumn baseTableName = new DataColumn("BaseTableName", typeof(string));
+            DataColumn baseColumnName = new DataColumn("BaseColumnName", typeof(string));
 
             ordinal.DefaultValue = 0;
             isLong.DefaultValue = false;
@@ -540,7 +540,7 @@ namespace System.Data.OleDb
                     info.size = (int)dbColumnInfo.ulColumnSize;
 #else
                 long maxsize = (long)dbColumnInfo.ulColumnSize;
-                info.size = (((maxsize < 0) || (Int32.MaxValue < maxsize)) ? Int32.MaxValue : (int)maxsize);
+                info.size = (((maxsize < 0) || (int.MaxValue < maxsize)) ? int.MaxValue : (int)maxsize);
 #endif
                 info.flags = dbColumnInfo.dwFlags;
                 info.precision = dbColumnInfo.bPrecision;
@@ -828,23 +828,23 @@ namespace System.Data.OleDb
             DisposeNativeRowset();
         }
 
-        public override Boolean GetBoolean(int ordinal)
+        public override bool GetBoolean(int ordinal)
         {
             ColumnBinding binding = GetColumnBinding(ordinal);
             return binding.ValueBoolean();
         }
 
-        public override Byte GetByte(int ordinal)
+        public override byte GetByte(int ordinal)
         {
             ColumnBinding binding = GetColumnBinding(ordinal);
             return binding.ValueByte();
         }
 
-        private ColumnBinding DoSequentialCheck(int ordinal, Int64 dataIndex, string method)
+        private ColumnBinding DoSequentialCheck(int ordinal, long dataIndex, string method)
         {
             ColumnBinding binding = GetColumnBinding(ordinal);
 
-            if (dataIndex > Int32.MaxValue)
+            if (dataIndex > int.MaxValue)
             {
                 throw ADP.InvalidSourceBufferIndex(0, dataIndex, "dataIndex");
             }
@@ -862,7 +862,7 @@ namespace System.Data.OleDb
             return binding;
         }
 
-        public override Int64 GetBytes(int ordinal, Int64 dataIndex, byte[] buffer, Int32 bufferIndex, Int32 length)
+        public override long GetBytes(int ordinal, long dataIndex, byte[] buffer, int bufferIndex, int length)
         {
             ColumnBinding binding = DoSequentialCheck(ordinal, dataIndex, ADP.GetBytes);
             byte[] value = binding.ValueByteArray();
@@ -898,7 +898,7 @@ namespace System.Data.OleDb
             return byteCount;
         }
 
-        public override Int64 GetChars(int ordinal, Int64 dataIndex, char[] buffer, Int32 bufferIndex, Int32 length)
+        public override long GetChars(int ordinal, long dataIndex, char[] buffer, int bufferIndex, int length)
         {
             ColumnBinding binding = DoSequentialCheck(ordinal, dataIndex, ADP.GetChars);
             string value = binding.ValueString();
@@ -936,7 +936,7 @@ namespace System.Data.OleDb
         }
 
         [EditorBrowsable(EditorBrowsableState.Never)]
-        public override Char GetChar(int ordinal)
+        public override char GetChar(int ordinal)
         {
             throw ADP.NotSupported();
         }
@@ -987,7 +987,7 @@ namespace System.Data.OleDb
             return reader;
         }
 
-        public override String GetDataTypeName(int index)
+        public override string GetDataTypeName(int index)
         {
             if (null != _metadata)
             {
@@ -1002,13 +1002,13 @@ namespace System.Data.OleDb
             return binding.ValueDateTime();
         }
 
-        public override Decimal GetDecimal(int ordinal)
+        public override decimal GetDecimal(int ordinal)
         {
             ColumnBinding binding = GetColumnBinding(ordinal);
             return binding.ValueDecimal();
         }
 
-        public override Double GetDouble(int ordinal)
+        public override double GetDouble(int ordinal)
         {
             ColumnBinding binding = GetColumnBinding(ordinal);
             return binding.ValueDouble();
@@ -1028,7 +1028,7 @@ namespace System.Data.OleDb
             throw ADP.DataReaderNoData();
         }
 
-        public override Single GetFloat(int ordinal)
+        public override float GetFloat(int ordinal)
         {
             ColumnBinding binding = GetColumnBinding(ordinal);
             return binding.ValueSingle();
@@ -1040,25 +1040,25 @@ namespace System.Data.OleDb
             return binding.ValueGuid();
         }
 
-        public override Int16 GetInt16(int ordinal)
+        public override short GetInt16(int ordinal)
         {
             ColumnBinding binding = GetColumnBinding(ordinal);
             return binding.ValueInt16();
         }
 
-        public override Int32 GetInt32(int ordinal)
+        public override int GetInt32(int ordinal)
         {
             ColumnBinding binding = GetColumnBinding(ordinal);
             return binding.ValueInt32();
         }
 
-        public override Int64 GetInt64(int ordinal)
+        public override long GetInt64(int ordinal)
         {
             ColumnBinding binding = GetColumnBinding(ordinal);
             return binding.ValueInt64();
         }
 
-        public override String GetName(int index)
+        public override string GetName(int index)
         {
             if (null != _metadata)
             {
@@ -1068,7 +1068,7 @@ namespace System.Data.OleDb
             throw ADP.DataReaderNoData();
         }
 
-        public override Int32 GetOrdinal(String name)
+        public override int GetOrdinal(string name)
         {
             if (null == _fieldNameLookup)
             {
@@ -1081,7 +1081,7 @@ namespace System.Data.OleDb
             return _fieldNameLookup.GetOrdinal(name);
         }
 
-        public override String GetString(int ordinal)
+        public override string GetString(int ordinal)
         {
             ColumnBinding binding = GetColumnBinding(ordinal);
             return binding.ValueString();
@@ -1160,7 +1160,7 @@ namespace System.Data.OleDb
             return value;
         }
 
-        public override Int32 GetValues(object[] values)
+        public override int GetValues(object[] values)
         {
             if (null == values)
             {
@@ -1181,7 +1181,7 @@ namespace System.Data.OleDb
             return (condition == (condition & _commandBehavior));
         }
 
-        public override Boolean IsDBNull(int ordinal)
+        public override bool IsDBNull(int ordinal)
         {
             ColumnBinding binding = GetColumnBinding(ordinal);
             return binding.IsValueNull();
@@ -1510,7 +1510,7 @@ namespace System.Data.OleDb
                 _rowHandleFetchCount = new IntPtr(1);
 
                 object maxRows = GetPropertyValue(ODB.DBPROP_MAXROWS);
-                if (maxRows is Int32)
+                if (maxRows is int)
                 {
                     _rowHandleFetchCount = new IntPtr((int)maxRows);
                     if ((ADP.PtrZero == _rowHandleFetchCount) || (20 <= (int)_rowHandleFetchCount))
@@ -1518,7 +1518,7 @@ namespace System.Data.OleDb
                         _rowHandleFetchCount = new IntPtr(20);
                     }
                 }
-                else if (maxRows is Int64)
+                else if (maxRows is long)
                 {
                     _rowHandleFetchCount = new IntPtr((long)maxRows);
                     if ((ADP.PtrZero == _rowHandleFetchCount) || (20 <= (long)_rowHandleFetchCount))
@@ -1917,7 +1917,7 @@ namespace System.Data.OleDb
             _nextAccessorForRetrieval++;
         }
 
-        private Int32 IndexOf(Hashtable hash, string name)
+        private int IndexOf(Hashtable hash, string name)
         {
             // via case sensitive search, first match with lowest ordinal matches
             object index = hash[name];
@@ -2038,7 +2038,7 @@ namespace System.Data.OleDb
             // look for primary keys in the table
             if (_connection.SupportSchemaRowset(OleDbSchemaGuid.Primary_Keys))
             {
-                Object[] restrictions = new Object[] { baseCatalogName, baseSchemaName, baseTableName };
+                object[] restrictions = new object[] { baseCatalogName, baseSchemaName, baseTableName };
                 keyCount = AppendSchemaPrimaryKey(baseColumnNames, restrictions);
             }
             if (0 != keyCount)
@@ -2049,7 +2049,7 @@ namespace System.Data.OleDb
             // look for a single unique contraint that can be upgraded
             if (_connection.SupportSchemaRowset(OleDbSchemaGuid.Indexes))
             {
-                Object[] restrictions = new Object[] { baseCatalogName, baseSchemaName, null, null, baseTableName };
+                object[] restrictions = new object[] { baseCatalogName, baseSchemaName, null, null, baseTableName };
                 AppendSchemaUniqueIndexAsKey(baseColumnNames, restrictions);
             }
         }
@@ -2262,7 +2262,7 @@ namespace System.Data.OleDb
             List<MetaData> metainfo = new List<MetaData>();
 
             object hiddenColumns = null;
-            using (OleDbDataReader dataReader = new OleDbDataReader(_connection, _command, Int32.MinValue, 0))
+            using (OleDbDataReader dataReader = new OleDbDataReader(_connection, _command, int.MinValue, 0))
             {
                 dataReader.InitializeIRowset(rowset, ChapterHandle.DB_NULL_HCHAPTER, IntPtr.Zero);
                 dataReader.BuildSchemaTableInfo(rowset, true, false);
@@ -2441,7 +2441,7 @@ namespace System.Data.OleDb
             }
 
             int visibleCount = metainfo.Count;
-            if (hiddenColumns is Int32)
+            if (hiddenColumns is int)
             {
                 visibleCount -= (int)hiddenColumns;
             }
@@ -2577,7 +2577,7 @@ namespace System.Data.OleDb
         }
     }
 
-    sealed internal class MetaData : IComparable
+    internal sealed class MetaData : IComparable
     {
         internal Bindings bindings;
         internal ColumnBinding columnBinding;
index 0611715..ca7ca1d 100644 (file)
@@ -131,7 +131,7 @@ namespace System.Data.OleDb
             }
         }
 
-        sealed internal class ErrorCodeConverter : Int32Converter
+        internal sealed class ErrorCodeConverter : Int32Converter
         {
             // converter classes should have public ctor
             public ErrorCodeConverter()
@@ -144,7 +144,7 @@ namespace System.Data.OleDb
                 {
                     throw ADP.ArgumentNull("destinationType");
                 }
-                if ((destinationType == typeof(string)) && (value != null) && (value is Int32))
+                if ((destinationType == typeof(string)) && (value != null) && (value is int))
                 {
                     return ODB.ELookup((OleDbHResult)value);
                 }
index 7ad853c..7f6d19c 100644 (file)
@@ -74,12 +74,12 @@ namespace System.Data.OleDb
             // 3) the provider does not support the necessary schema rowset
 
             DataColumn populationMechanism = metaDataCollectionsTable.Columns[_populationMechanism];
-            if ((null == populationMechanism) || (typeof(System.String) != populationMechanism.DataType))
+            if ((null == populationMechanism) || (typeof(string) != populationMechanism.DataType))
             {
                 throw ADP.InvalidXmlMissingColumn(DbMetaDataCollectionNames.MetaDataCollections, _populationMechanism);
             }
             DataColumn collectionName = metaDataCollectionsTable.Columns[_collectionName];
-            if ((null == collectionName) || (typeof(System.String) != collectionName.DataType))
+            if ((null == collectionName) || (typeof(string) != collectionName.DataType))
             {
                 throw ADP.InvalidXmlMissingColumn(DbMetaDataCollectionNames.MetaDataCollections, _collectionName);
             }
@@ -87,7 +87,7 @@ namespace System.Data.OleDb
             if (restrictionsTable != null)
             {
                 restrictionCollectionName = restrictionsTable.Columns[_collectionName];
-                if ((null == restrictionCollectionName) || (typeof(System.String) != restrictionCollectionName.DataType))
+                if ((null == restrictionCollectionName) || (typeof(string) != restrictionCollectionName.DataType))
                 {
                     throw ADP.InvalidXmlMissingColumn(DbMetaDataCollectionNames.Restrictions, _collectionName);
                 }
@@ -176,7 +176,7 @@ namespace System.Data.OleDb
 
         }
 
-        private String BuildRegularExpression(string invalidChars, string invalidStartingChars)
+        private string BuildRegularExpression(string invalidChars, string invalidStartingChars)
         {
             StringBuilder regularExpression = new StringBuilder("[^");
             ADP.EscapeSpecialCharacters(invalidStartingChars, regularExpression);
@@ -435,7 +435,7 @@ namespace System.Data.OleDb
                     newRow[isSearchableWithLike] = DBNull.Value;
                     if (DBNull.Value != sourceRow[searchable])
                     {
-                        Int64 searchableValue = (Int64)(sourceRow[searchable]);
+                        long searchableValue = (long)(sourceRow[searchable]);
                         switch (searchableValue)
                         {
                             case ODB.DB_UNSEARCHABLE:
@@ -496,7 +496,7 @@ namespace System.Data.OleDb
             return reservedWordsTable;
         }
 
-        protected override DataTable PrepareCollection(String collectionName, String[] restrictions, DbConnection connection)
+        protected override DataTable PrepareCollection(string collectionName, string[] restrictions, DbConnection connection)
         {
             OleDbConnection oleDbConnection = (OleDbConnection)connection;
             OleDbConnectionInternal oleDbInternalConnection = (OleDbConnectionInternal)(oleDbConnection.InnerConnection);
@@ -572,7 +572,7 @@ namespace System.Data.OleDb
                                     mungedRestrictions[j] = restrictions[j];
                                 }
 
-                                UInt16 indexTypeValue;
+                                ushort indexTypeValue;
 
                                 if ((restrictions[indexRestrictionTypeSlot] == "DBPROPVAL_IT_BTREE") ||
                                     (restrictions[indexRestrictionTypeSlot] == "1"))
@@ -616,7 +616,7 @@ namespace System.Data.OleDb
                                     mungedRestrictions[j] = restrictions[j];
                                 }
 
-                                Int16 procedureTypeValue;
+                                short procedureTypeValue;
 
                                 if ((restrictions[procedureRestrictionTypeSlot] == "DB_PT_UNKNOWN") ||
                                     (restrictions[procedureRestrictionTypeSlot] == "1"))
index 5a119f3..fcb6f9e 100644 (file)
@@ -59,8 +59,8 @@ namespace System.Data.OleDb
         [EditorBrowsable(EditorBrowsableState.Advanced)]
         public OleDbParameter(string parameterName,
                               OleDbType dbType, int size,
-                              ParameterDirection direction, Boolean isNullable,
-                              Byte precision, Byte scale,
+                              ParameterDirection direction, bool isNullable,
+                              byte precision, byte scale,
                               string srcColumn, DataRowVersion srcVersion,
                               object value) : this()
         { // V1.0 everything
@@ -80,7 +80,7 @@ namespace System.Data.OleDb
         public OleDbParameter(string parameterName,
                               OleDbType dbType, int size,
                               ParameterDirection direction,
-                              Byte precision, Byte scale,
+                              byte precision, byte scale,
                               string sourceColumn, DataRowVersion sourceVersion, bool sourceColumnNullMapping,
                               object value) : this()
         { // V2.0 everything - round trip all browsable properties + precision/scale
@@ -178,8 +178,8 @@ namespace System.Data.OleDb
             }
         }
 
-        [DefaultValue((Byte)0)]
-        public new Byte Precision
+        [DefaultValue((byte)0)]
+        public new byte Precision
         {
             get
             {
@@ -215,8 +215,8 @@ namespace System.Data.OleDb
             return (0 != _precision);
         }
 
-        [DefaultValue((Byte)0)]
-        public new Byte Scale
+        [DefaultValue((byte)0)]
+        public new byte Scale
         {
             get
             {
@@ -341,15 +341,15 @@ namespace System.Data.OleDb
                 {
                     if (NativeDBType.STR == dbtype.dbType)
                     {
-                        size = Int32.MaxValue;
+                        size = int.MaxValue;
                     }
                     else if (NativeDBType.WSTR == dbtype.dbType)
                     {
-                        size = Int32.MaxValue / 2;
+                        size = int.MaxValue / 2;
                     }
                     else
                     {
-                        size = Int32.MaxValue;
+                        size = int.MaxValue;
                     }
                 }
                 wtype |= NativeDBType.BYREF;
@@ -476,7 +476,7 @@ namespace System.Data.OleDb
                         }
                         else if ((NativeDBType.CY == destinationType.dbType) && (typeof(string) == currentType))
                         {
-                            value = Decimal.Parse((string)value, NumberStyles.Currency, (IFormatProvider)null);
+                            value = decimal.Parse((string)value, NumberStyles.Currency, (IFormatProvider)null);
                         }
                         else
                         {
@@ -620,7 +620,7 @@ namespace System.Data.OleDb
         }
 
         // implemented as nested class to take advantage of the private/protected ShouldSerializeXXX methods
-        sealed internal class OleDbParameterConverter : System.ComponentModel.ExpandableObjectConverter
+        internal sealed class OleDbParameterConverter : System.ComponentModel.ExpandableObjectConverter
         {
             // converter classes should have public ctor
             public OleDbParameterConverter()
index 0a5f38b..8308f6f 100644 (file)
@@ -4,7 +4,7 @@
 
 namespace System.Data.OleDb
 {
-    sealed internal class OleDbPropertySetGuid
+    internal sealed class OleDbPropertySetGuid
     {
         private OleDbPropertySetGuid()
         {
index 5d7d605..eeb3b0f 100644 (file)
@@ -7,7 +7,7 @@ using System.Diagnostics;
 
 namespace System.Data.OleDb
 {
-    sealed internal class OleDbReferenceCollection : DbReferenceCollection
+    internal sealed class OleDbReferenceCollection : DbReferenceCollection
     {
         internal const int Closing = 0;
         internal const int Canceling = -1;
index 6ef843c..9554acd 100644 (file)
@@ -43,9 +43,9 @@ namespace System.Data.OleDb
         internal IntPtr pwszDataSourceType;
         internal IntPtr pwszName;
         internal IntPtr ulParamSize;
-        internal Int32 dwFlags;
-        internal Byte bPrecision;
-        internal Byte bScale;
+        internal int dwFlags;
+        internal byte bPrecision;
+        internal byte bScale;
 
 #if DEBUG
         public override string ToString()
@@ -101,14 +101,14 @@ namespace System.Data.OleDb
         internal IntPtr pObject;
         internal IntPtr pBindExt;
 
-        internal Int32 dwPart;
-        internal Int32 dwMemOwner;
-        internal Int32 eParamIO;
+        internal int dwPart;
+        internal int dwMemOwner;
+        internal int eParamIO;
 
         internal IntPtr cbMaxLen;
 
-        internal Int32 dwFlags;
-        internal Int16 wType;
+        internal int dwFlags;
+        internal short wType;
         internal byte bPrecision;
         internal byte bScale;
 
@@ -158,12 +158,12 @@ namespace System.Data.OleDb
         internal IntPtr pData;
         internal tagDBIDX columnid;
         internal IntPtr cbDataLen;
-        internal Int32 dwStatus;
+        internal int dwStatus;
         internal IntPtr cbMaxLen;
         internal IntPtr dwReserved;
-        internal Int16 wType;
-        internal Byte bPrecision;
-        internal Byte bScale;
+        internal short wType;
+        internal byte bPrecision;
+        internal byte bScale;
     }
 
 #if false
@@ -190,7 +190,7 @@ namespace System.Data.OleDb
     internal struct tagDBIDX
     {
         internal Guid uGuid;
-        internal Int32 eKind;
+        internal int eKind;
         internal IntPtr ulPropid;
     }
 
@@ -202,7 +202,7 @@ namespace System.Data.OleDb
     internal sealed class tagDBID
     {
         internal Guid uGuid;
-        internal Int32 eKind;
+        internal int eKind;
         internal IntPtr ulPropid;
     }
 
@@ -221,22 +221,22 @@ namespace System.Data.OleDb
 #else
     [StructLayout(LayoutKind.Sequential, Pack = 8)]
 #endif
-    sealed internal class tagDBLITERALINFO
+    internal sealed class tagDBLITERALINFO
     {
         [MarshalAs(UnmanagedType.LPWStr)]
-        internal String pwszLiteralValue = null;
+        internal string pwszLiteralValue = null;
 
         [MarshalAs(UnmanagedType.LPWStr)]
-        internal String pwszInvalidChars = null;
+        internal string pwszInvalidChars = null;
 
         [MarshalAs(UnmanagedType.LPWStr)]
-        internal String pwszInvalidStartingChars = null;
+        internal string pwszInvalidStartingChars = null;
 
-        internal Int32 it;
+        internal int it;
 
-        internal Int32 fSupported;
+        internal int fSupported;
 
-        internal Int32 cchMaxLen;
+        internal int cchMaxLen;
 
         internal tagDBLITERALINFO()
         {
@@ -255,10 +255,10 @@ namespace System.Data.OleDb
 #else
     [StructLayout(LayoutKind.Sequential, Pack = 8)]
 #endif
-    sealed internal class tagDBPROPSET
+    internal sealed class tagDBPROPSET
     {
         internal IntPtr rgProperties;
-        internal Int32 cProperties;
+        internal int cProperties;
         internal Guid guidPropertySet;
 
         internal tagDBPROPSET()
@@ -286,10 +286,10 @@ namespace System.Data.OleDb
 #else
     [StructLayout(LayoutKind.Sequential, Pack = 8)]
 #endif
-    sealed internal class tagDBPROP
+    internal sealed class tagDBPROP
     {
-        internal Int32 dwPropertyID;
-        internal Int32 dwOptions;
+        internal int dwPropertyID;
+        internal int dwOptions;
         internal OleDbPropertyStatus dwStatus;
 
         internal tagDBIDX columnid;
@@ -321,10 +321,10 @@ namespace System.Data.OleDb
 #else
     [StructLayout(LayoutKind.Sequential, Pack = 8)]
 #endif
-    sealed internal class tagDBPARAMS
+    internal sealed class tagDBPARAMS
     {
         internal IntPtr pData;
-        internal Int32 cParamSets;
+        internal int cParamSets;
         internal IntPtr hAccessor;
 
         internal tagDBPARAMS()
@@ -350,25 +350,25 @@ namespace System.Data.OleDb
 #else
     [StructLayout(LayoutKind.Sequential, Pack = 8)]
 #endif
-    sealed internal class tagDBCOLUMNINFO
+    internal sealed class tagDBCOLUMNINFO
     {
         [MarshalAs(UnmanagedType.LPWStr)]
-        internal String pwszName = null;
+        internal string pwszName = null;
 
         //[MarshalAs(UnmanagedType.Interface)]
         internal IntPtr pTypeInfo = (IntPtr)0;
 
         internal IntPtr iOrdinal = (IntPtr)0;
 
-        internal Int32 dwFlags = 0;
+        internal int dwFlags = 0;
 
         internal IntPtr ulColumnSize = (IntPtr)0;
 
-        internal Int16 wType = 0;
+        internal short wType = 0;
 
-        internal Byte bPrecision = 0;
+        internal byte bPrecision = 0;
 
-        internal Byte bScale = 0;
+        internal byte bScale = 0;
 
         internal tagDBIDX columnid;
 
@@ -404,10 +404,10 @@ namespace System.Data.OleDb
 #else
     [StructLayout(LayoutKind.Sequential, Pack = 8)]
 #endif
-    sealed internal class tagDBPROPINFOSET
+    internal sealed class tagDBPROPINFOSET
     {
         internal IntPtr rgPropertyInfos;
-        internal Int32 cPropertyInfos;
+        internal int cPropertyInfos;
         internal Guid guidPropertySet;
 
         internal tagDBPROPINFOSET()
@@ -429,14 +429,14 @@ namespace System.Data.OleDb
 #else
     [StructLayout(LayoutKind.Sequential, Pack = 8)]
 #endif
-    sealed internal class tagDBPROPINFO
+    internal sealed class tagDBPROPINFO
     {
         [MarshalAs(UnmanagedType.LPWStr)] internal string pwszDescription;
 
-        internal Int32 dwPropertyID;
-        internal Int32 dwFlags;
+        internal int dwPropertyID;
+        internal int dwFlags;
 
-        internal Int16 vtType;
+        internal short vtType;
 
         [MarshalAs(UnmanagedType.Struct)] internal object vValue;
 
@@ -460,7 +460,7 @@ namespace System.Data.OleDb
     internal struct tagDBPROPIDSET
     {
         internal IntPtr rgPropertyIDs;
-        internal Int32 cPropertyIDs;
+        internal int cPropertyIDs;
         internal Guid guidPropertySet;
     }
 }
index ce6fe77..b0fb39f 100644 (file)
@@ -12,7 +12,7 @@ namespace System.Data.OleDb
 {
     // SafeHandle wrapper around 'DataLinks' object which pools the native OLE DB providers.
     // expect 1 per app-domain
-    sealed internal class OleDbServicesWrapper : WrappedIUnknown
+    internal sealed class OleDbServicesWrapper : WrappedIUnknown
     {
         // we expect to store IDataInitialize instance pointer in base.handle
 
@@ -88,7 +88,7 @@ namespace System.Data.OleDb
 
     // SafeHandle wrapper around 'Data Source' object which represents the connection
     // expect 1 per OleDbConnectionInternal
-    sealed internal class DataSourceWrapper : WrappedIUnknown
+    internal sealed class DataSourceWrapper : WrappedIUnknown
     {
         // we expect to store IDBInitialize instance pointer in base.handle
 
@@ -219,7 +219,7 @@ namespace System.Data.OleDb
 
     // SafeHandle wrapper around 'Session' object which represents the session on the connection
     // expect 1 per OleDbConnectionInternal
-    sealed internal class SessionWrapper : WrappedIUnknown
+    internal sealed class SessionWrapper : WrappedIUnknown
     {
         // base.handle will either reference the IUnknown interface or IDBCreateCommand interface
         // if OleDbConnectionString.DangerousIDBCreateCommandCreateCommand exists
index e3136ef..a927480 100644 (file)
@@ -40,7 +40,7 @@ namespace System.Data.OleDb
         S_ROWSETCOLUMN = 29, // 2.6
     }
 
-    sealed internal class NativeDBType
+    internal sealed class NativeDBType
     { // from 4214.0
         // Variant compatible
         internal const short EMPTY = 0;       //
@@ -127,50 +127,50 @@ namespace System.Data.OleDb
         private const string S_WLONGVARCHAR = "DBTYPE_WLONGVARCHAR"; // DBTYPE_WSTR
         private const string S_XML = "DBTYPE_XML";
 
-        static private readonly NativeDBType D_Binary = new NativeDBType(0xff, -1, true, false, OleDbType.Binary, NativeDBType.BYTES, S_BINARY, typeof(System.Byte[]), NativeDBType.BYTES, DbType.Binary); //  0
-        static private readonly NativeDBType D_Boolean = new NativeDBType(0xff, 2, true, false, OleDbType.Boolean, NativeDBType.BOOL, S_BOOL, typeof(System.Boolean), NativeDBType.BOOL, DbType.Boolean); //  1 - integer2 (variant_bool)
-        static private readonly NativeDBType D_BSTR = new NativeDBType(0xff, ADP.PtrSize, false, false, OleDbType.BSTR, NativeDBType.BSTR, S_BSTR, typeof(System.String), NativeDBType.BSTR, DbType.String); //  2 - integer4 (pointer)
-        static private readonly NativeDBType D_Char = new NativeDBType(0xff, -1, true, false, OleDbType.Char, NativeDBType.STR, S_CHAR, typeof(System.String), NativeDBType.WSTR/*STR*/, DbType.AnsiStringFixedLength); //  3 - (ansi pointer)
-        static private readonly NativeDBType D_Currency = new NativeDBType(19, 8, true, false, OleDbType.Currency, NativeDBType.CY, S_CY, typeof(System.Decimal), NativeDBType.CY, DbType.Currency); //  4 - integer8
+        static private readonly NativeDBType D_Binary = new NativeDBType(0xff, -1, true, false, OleDbType.Binary, NativeDBType.BYTES, S_BINARY, typeof(byte[]), NativeDBType.BYTES, DbType.Binary); //  0
+        static private readonly NativeDBType D_Boolean = new NativeDBType(0xff, 2, true, false, OleDbType.Boolean, NativeDBType.BOOL, S_BOOL, typeof(bool), NativeDBType.BOOL, DbType.Boolean); //  1 - integer2 (variant_bool)
+        static private readonly NativeDBType D_BSTR = new NativeDBType(0xff, ADP.PtrSize, false, false, OleDbType.BSTR, NativeDBType.BSTR, S_BSTR, typeof(string), NativeDBType.BSTR, DbType.String); //  2 - integer4 (pointer)
+        static private readonly NativeDBType D_Char = new NativeDBType(0xff, -1, true, false, OleDbType.Char, NativeDBType.STR, S_CHAR, typeof(string), NativeDBType.WSTR/*STR*/, DbType.AnsiStringFixedLength); //  3 - (ansi pointer)
+        static private readonly NativeDBType D_Currency = new NativeDBType(19, 8, true, false, OleDbType.Currency, NativeDBType.CY, S_CY, typeof(decimal), NativeDBType.CY, DbType.Currency); //  4 - integer8
         static private readonly NativeDBType D_Date = new NativeDBType(0xff, 8, true, false, OleDbType.Date, NativeDBType.DATE, S_DATE, typeof(System.DateTime), NativeDBType.DATE, DbType.DateTime); //  5 - double
         static private readonly NativeDBType D_DBDate = new NativeDBType(0xff, 6, true, false, OleDbType.DBDate, NativeDBType.DBDATE, S_DBDATE, typeof(System.DateTime), NativeDBType.DBDATE, DbType.Date); //  6 - (tagDBDate)
         static private readonly NativeDBType D_DBTime = new NativeDBType(0xff, 6, true, false, OleDbType.DBTime, NativeDBType.DBTIME, S_DBTIME, typeof(System.TimeSpan), NativeDBType.DBTIME, DbType.Time); //  7 - (tagDBTime)
         static private readonly NativeDBType D_DBTimeStamp = new NativeDBType(0xff, 16, true, false, OleDbType.DBTimeStamp, NativeDBType.DBTIMESTAMP, S_DBTIMESTAMP, typeof(System.DateTime), NativeDBType.DBTIMESTAMP, DbType.DateTime); //  8 - (tagDBTIMESTAMP)
-        static private readonly NativeDBType D_Decimal = new NativeDBType(28, 16, true, false, OleDbType.Decimal, NativeDBType.DECIMAL, S_DECIMAL, typeof(System.Decimal), NativeDBType.DECIMAL, DbType.Decimal); //  9 - (tagDec)
-        static private readonly NativeDBType D_Error = new NativeDBType(0xff, 4, true, false, OleDbType.Error, NativeDBType.ERROR, S_ERROR, typeof(System.Int32), NativeDBType.ERROR, DbType.Int32); // 10 - integer4
+        static private readonly NativeDBType D_Decimal = new NativeDBType(28, 16, true, false, OleDbType.Decimal, NativeDBType.DECIMAL, S_DECIMAL, typeof(decimal), NativeDBType.DECIMAL, DbType.Decimal); //  9 - (tagDec)
+        static private readonly NativeDBType D_Error = new NativeDBType(0xff, 4, true, false, OleDbType.Error, NativeDBType.ERROR, S_ERROR, typeof(int), NativeDBType.ERROR, DbType.Int32); // 10 - integer4
         static private readonly NativeDBType D_Filetime = new NativeDBType(0xff, 8, true, false, OleDbType.Filetime, NativeDBType.FILETIME, S_FILETIME, typeof(System.DateTime), NativeDBType.FILETIME, DbType.DateTime); // 11 - integer8
         static private readonly NativeDBType D_Guid = new NativeDBType(0xff, 16, true, false, OleDbType.Guid, NativeDBType.GUID, S_GUID, typeof(System.Guid), NativeDBType.GUID, DbType.Guid); // 12 - ubyte[16]
-        static private readonly NativeDBType D_TinyInt = new NativeDBType(3, 1, true, false, OleDbType.TinyInt, NativeDBType.I1, S_I1, typeof(System.Int16), NativeDBType.I1, DbType.SByte); // 13 - integer1
-        static private readonly NativeDBType D_SmallInt = new NativeDBType(5, 2, true, false, OleDbType.SmallInt, NativeDBType.I2, S_I2, typeof(System.Int16), NativeDBType.I2, DbType.Int16); // 14 - integer2
-        static private readonly NativeDBType D_Integer = new NativeDBType(10, 4, true, false, OleDbType.Integer, NativeDBType.I4, S_I4, typeof(System.Int32), NativeDBType.I4, DbType.Int32); // 15 - integer4
-        static private readonly NativeDBType D_BigInt = new NativeDBType(19, 8, true, false, OleDbType.BigInt, NativeDBType.I8, S_I8, typeof(System.Int64), NativeDBType.I8, DbType.Int64); // 16 - integer8
-        static private readonly NativeDBType D_IDispatch = new NativeDBType(0xff, ADP.PtrSize, true, false, OleDbType.IDispatch, NativeDBType.IDISPATCH, S_IDISPATCH, typeof(System.Object), NativeDBType.IDISPATCH, DbType.Object); // 17 - integer4 (pointer)
-        static private readonly NativeDBType D_IUnknown = new NativeDBType(0xff, ADP.PtrSize, true, false, OleDbType.IUnknown, NativeDBType.IUNKNOWN, S_IUNKNOWN, typeof(System.Object), NativeDBType.IUNKNOWN, DbType.Object); // 18 - integer4 (pointer)
-        static private readonly NativeDBType D_LongVarBinary = new NativeDBType(0xff, -1, false, true, OleDbType.LongVarBinary, NativeDBType.BYTES, S_LONGVARBINARY, typeof(System.Byte[]), NativeDBType.BYTES, DbType.Binary); // 19
-        static private readonly NativeDBType D_LongVarChar = new NativeDBType(0xff, -1, false, true, OleDbType.LongVarChar, NativeDBType.STR, S_LONGVARCHAR, typeof(System.String), NativeDBType.WSTR/*STR*/, DbType.AnsiString); // 20 - (ansi pointer)
-        static private readonly NativeDBType D_Numeric = new NativeDBType(28, 19, true, false, OleDbType.Numeric, NativeDBType.NUMERIC, S_NUMERIC, typeof(System.Decimal), NativeDBType.NUMERIC, DbType.Decimal); // 21 - (tagDB_Numeric)
+        static private readonly NativeDBType D_TinyInt = new NativeDBType(3, 1, true, false, OleDbType.TinyInt, NativeDBType.I1, S_I1, typeof(short), NativeDBType.I1, DbType.SByte); // 13 - integer1
+        static private readonly NativeDBType D_SmallInt = new NativeDBType(5, 2, true, false, OleDbType.SmallInt, NativeDBType.I2, S_I2, typeof(short), NativeDBType.I2, DbType.Int16); // 14 - integer2
+        static private readonly NativeDBType D_Integer = new NativeDBType(10, 4, true, false, OleDbType.Integer, NativeDBType.I4, S_I4, typeof(int), NativeDBType.I4, DbType.Int32); // 15 - integer4
+        static private readonly NativeDBType D_BigInt = new NativeDBType(19, 8, true, false, OleDbType.BigInt, NativeDBType.I8, S_I8, typeof(long), NativeDBType.I8, DbType.Int64); // 16 - integer8
+        static private readonly NativeDBType D_IDispatch = new NativeDBType(0xff, ADP.PtrSize, true, false, OleDbType.IDispatch, NativeDBType.IDISPATCH, S_IDISPATCH, typeof(object), NativeDBType.IDISPATCH, DbType.Object); // 17 - integer4 (pointer)
+        static private readonly NativeDBType D_IUnknown = new NativeDBType(0xff, ADP.PtrSize, true, false, OleDbType.IUnknown, NativeDBType.IUNKNOWN, S_IUNKNOWN, typeof(object), NativeDBType.IUNKNOWN, DbType.Object); // 18 - integer4 (pointer)
+        static private readonly NativeDBType D_LongVarBinary = new NativeDBType(0xff, -1, false, true, OleDbType.LongVarBinary, NativeDBType.BYTES, S_LONGVARBINARY, typeof(byte[]), NativeDBType.BYTES, DbType.Binary); // 19
+        static private readonly NativeDBType D_LongVarChar = new NativeDBType(0xff, -1, false, true, OleDbType.LongVarChar, NativeDBType.STR, S_LONGVARCHAR, typeof(string), NativeDBType.WSTR/*STR*/, DbType.AnsiString); // 20 - (ansi pointer)
+        static private readonly NativeDBType D_Numeric = new NativeDBType(28, 19, true, false, OleDbType.Numeric, NativeDBType.NUMERIC, S_NUMERIC, typeof(decimal), NativeDBType.NUMERIC, DbType.Decimal); // 21 - (tagDB_Numeric)
         static unsafe private readonly NativeDBType D_PropVariant = new NativeDBType(0xff, sizeof(PROPVARIANT),
-                                                                                                             true, false, OleDbType.PropVariant, NativeDBType.PROPVARIANT, S_PROPVARIANT, typeof(System.Object), NativeDBType.VARIANT, DbType.Object); // 22
-        static private readonly NativeDBType D_Single = new NativeDBType(7, 4, true, false, OleDbType.Single, NativeDBType.R4, S_R4, typeof(System.Single), NativeDBType.R4, DbType.Single); // 23 - single
-        static private readonly NativeDBType D_Double = new NativeDBType(15, 8, true, false, OleDbType.Double, NativeDBType.R8, S_R8, typeof(System.Double), NativeDBType.R8, DbType.Double); // 24 - double
-        static private readonly NativeDBType D_UnsignedTinyInt = new NativeDBType(3, 1, true, false, OleDbType.UnsignedTinyInt, NativeDBType.UI1, S_UI1, typeof(System.Byte), NativeDBType.UI1, DbType.Byte); // 25 - byte7
-        static private readonly NativeDBType D_UnsignedSmallInt = new NativeDBType(5, 2, true, false, OleDbType.UnsignedSmallInt, NativeDBType.UI2, S_UI2, typeof(System.Int32), NativeDBType.UI2, DbType.UInt16); // 26 - unsigned integer2
-        static private readonly NativeDBType D_UnsignedInt = new NativeDBType(10, 4, true, false, OleDbType.UnsignedInt, NativeDBType.UI4, S_UI4, typeof(System.Int64), NativeDBType.UI4, DbType.UInt32); // 27 - unsigned integer4
-        static private readonly NativeDBType D_UnsignedBigInt = new NativeDBType(20, 8, true, false, OleDbType.UnsignedBigInt, NativeDBType.UI8, S_UI8, typeof(System.Decimal), NativeDBType.UI8, DbType.UInt64); // 28 - unsigned integer8
-        static private readonly NativeDBType D_VarBinary = new NativeDBType(0xff, -1, false, false, OleDbType.VarBinary, NativeDBType.BYTES, S_VARBINARY, typeof(System.Byte[]), NativeDBType.BYTES, DbType.Binary); // 29
-        static private readonly NativeDBType D_VarChar = new NativeDBType(0xff, -1, false, false, OleDbType.VarChar, NativeDBType.STR, S_VARCHAR, typeof(System.String), NativeDBType.WSTR/*STR*/, DbType.AnsiString); // 30 - (ansi pointer)
-        static private readonly NativeDBType D_Variant = new NativeDBType(0xff, ODB.SizeOf_Variant, true, false, OleDbType.Variant, NativeDBType.VARIANT, S_VARIANT, typeof(System.Object), NativeDBType.VARIANT, DbType.Object); // 31 - ubyte[16] (variant)
-        static private readonly NativeDBType D_VarNumeric = new NativeDBType(255, 16, true, false, OleDbType.VarNumeric, NativeDBType.VARNUMERIC, S_VARNUMERIC, typeof(System.Decimal), NativeDBType.DECIMAL, DbType.VarNumeric); // 32 - (unicode pointer)
-        static private readonly NativeDBType D_WChar = new NativeDBType(0xff, -1, true, false, OleDbType.WChar, NativeDBType.WSTR, S_WCHAR, typeof(System.String), NativeDBType.WSTR, DbType.StringFixedLength); // 33 - (unicode pointer)
-        static private readonly NativeDBType D_VarWChar = new NativeDBType(0xff, -1, false, false, OleDbType.VarWChar, NativeDBType.WSTR, S_WVARCHAR, typeof(System.String), NativeDBType.WSTR, DbType.String); // 34 - (unicode pointer)
-        static private readonly NativeDBType D_LongVarWChar = new NativeDBType(0xff, -1, false, true, OleDbType.LongVarWChar, NativeDBType.WSTR, S_WLONGVARCHAR, typeof(System.String), NativeDBType.WSTR, DbType.String); // 35 - (unicode pointer)
+                                                                                                             true, false, OleDbType.PropVariant, NativeDBType.PROPVARIANT, S_PROPVARIANT, typeof(object), NativeDBType.VARIANT, DbType.Object); // 22
+        static private readonly NativeDBType D_Single = new NativeDBType(7, 4, true, false, OleDbType.Single, NativeDBType.R4, S_R4, typeof(float), NativeDBType.R4, DbType.Single); // 23 - single
+        static private readonly NativeDBType D_Double = new NativeDBType(15, 8, true, false, OleDbType.Double, NativeDBType.R8, S_R8, typeof(double), NativeDBType.R8, DbType.Double); // 24 - double
+        static private readonly NativeDBType D_UnsignedTinyInt = new NativeDBType(3, 1, true, false, OleDbType.UnsignedTinyInt, NativeDBType.UI1, S_UI1, typeof(byte), NativeDBType.UI1, DbType.Byte); // 25 - byte7
+        static private readonly NativeDBType D_UnsignedSmallInt = new NativeDBType(5, 2, true, false, OleDbType.UnsignedSmallInt, NativeDBType.UI2, S_UI2, typeof(int), NativeDBType.UI2, DbType.UInt16); // 26 - unsigned integer2
+        static private readonly NativeDBType D_UnsignedInt = new NativeDBType(10, 4, true, false, OleDbType.UnsignedInt, NativeDBType.UI4, S_UI4, typeof(long), NativeDBType.UI4, DbType.UInt32); // 27 - unsigned integer4
+        static private readonly NativeDBType D_UnsignedBigInt = new NativeDBType(20, 8, true, false, OleDbType.UnsignedBigInt, NativeDBType.UI8, S_UI8, typeof(decimal), NativeDBType.UI8, DbType.UInt64); // 28 - unsigned integer8
+        static private readonly NativeDBType D_VarBinary = new NativeDBType(0xff, -1, false, false, OleDbType.VarBinary, NativeDBType.BYTES, S_VARBINARY, typeof(byte[]), NativeDBType.BYTES, DbType.Binary); // 29
+        static private readonly NativeDBType D_VarChar = new NativeDBType(0xff, -1, false, false, OleDbType.VarChar, NativeDBType.STR, S_VARCHAR, typeof(string), NativeDBType.WSTR/*STR*/, DbType.AnsiString); // 30 - (ansi pointer)
+        static private readonly NativeDBType D_Variant = new NativeDBType(0xff, ODB.SizeOf_Variant, true, false, OleDbType.Variant, NativeDBType.VARIANT, S_VARIANT, typeof(object), NativeDBType.VARIANT, DbType.Object); // 31 - ubyte[16] (variant)
+        static private readonly NativeDBType D_VarNumeric = new NativeDBType(255, 16, true, false, OleDbType.VarNumeric, NativeDBType.VARNUMERIC, S_VARNUMERIC, typeof(decimal), NativeDBType.DECIMAL, DbType.VarNumeric); // 32 - (unicode pointer)
+        static private readonly NativeDBType D_WChar = new NativeDBType(0xff, -1, true, false, OleDbType.WChar, NativeDBType.WSTR, S_WCHAR, typeof(string), NativeDBType.WSTR, DbType.StringFixedLength); // 33 - (unicode pointer)
+        static private readonly NativeDBType D_VarWChar = new NativeDBType(0xff, -1, false, false, OleDbType.VarWChar, NativeDBType.WSTR, S_WVARCHAR, typeof(string), NativeDBType.WSTR, DbType.String); // 34 - (unicode pointer)
+        static private readonly NativeDBType D_LongVarWChar = new NativeDBType(0xff, -1, false, true, OleDbType.LongVarWChar, NativeDBType.WSTR, S_WLONGVARCHAR, typeof(string), NativeDBType.WSTR, DbType.String); // 35 - (unicode pointer)
         static private readonly NativeDBType D_Chapter = new NativeDBType(0xff, ADP.PtrSize, false, false, OleDbType.Empty, NativeDBType.HCHAPTER, S_UDT, typeof(IDataReader), NativeDBType.HCHAPTER, DbType.Object); // 36 - (hierarchical chaper)
         static private readonly NativeDBType D_Empty = new NativeDBType(0xff, 0, false, false, OleDbType.Empty, NativeDBType.EMPTY, "", null, NativeDBType.EMPTY, DbType.Object); // 37 - invalid param default
-        static private readonly NativeDBType D_Xml = new NativeDBType(0xff, -1, false, false, OleDbType.VarWChar, NativeDBType.XML, S_XML, typeof(System.String), NativeDBType.WSTR, DbType.String); // 38 - (unicode pointer)
-        static private readonly NativeDBType D_Udt = new NativeDBType(0xff, -1, false, false, OleDbType.VarBinary, NativeDBType.UDT, S_BINARY, typeof(System.Byte[]), NativeDBType.BYTES, DbType.Binary); // 39 - (unicode pointer)
+        static private readonly NativeDBType D_Xml = new NativeDBType(0xff, -1, false, false, OleDbType.VarWChar, NativeDBType.XML, S_XML, typeof(string), NativeDBType.WSTR, DbType.String); // 38 - (unicode pointer)
+        static private readonly NativeDBType D_Udt = new NativeDBType(0xff, -1, false, false, OleDbType.VarBinary, NativeDBType.UDT, S_BINARY, typeof(byte[]), NativeDBType.BYTES, DbType.Binary); // 39 - (unicode pointer)
 
         static internal readonly NativeDBType Default = D_VarWChar;
-        static internal readonly Byte MaximumDecimalPrecision = D_Decimal.maxpre;
+        static internal readonly byte MaximumDecimalPrecision = D_Decimal.maxpre;
 
         private const int FixedDbPart = /*DBPART_VALUE*/0x1 | /*DBPART_STATUS*/0x4;
         private const int VarblDbPart = /*DBPART_VALUE*/0x1 | /*DBPART_LENGTH*/0x2 | /*DBPART_STATUS*/0x4;
@@ -184,13 +184,13 @@ namespace System.Data.OleDb
         internal readonly int dbPart;    // the DBPart w or w/out length
         internal readonly bool isfixed;   // IsFixedLength
         internal readonly bool islong;    // IsLongLength
-        internal readonly Byte maxpre;    // maxium precision for numeric types // $CONSIDER - are we going to use this?
+        internal readonly byte maxpre;    // maxium precision for numeric types // $CONSIDER - are we going to use this?
         internal readonly int fixlen;    // fixed length size in bytes (-1 for variable)
 
-        internal readonly String dataSourceType; // ICommandWithParameters.SetParameterInfo standard type name
+        internal readonly string dataSourceType; // ICommandWithParameters.SetParameterInfo standard type name
         internal readonly StringMemHandle dbString;  // ptr to native allocated memory for dataSourceType string
 
-        private NativeDBType(Byte maxpre, int fixlen, bool isfixed, bool islong, OleDbType enumOleDbType, short dbType, string dbstring, Type dataType, short wType, DbType enumDbType)
+        private NativeDBType(byte maxpre, int fixlen, bool isfixed, bool islong, OleDbType enumOleDbType, short dbType, string dbstring, Type dataType, short wType, DbType enumDbType)
         {
             this.enumOleDbType = enumOleDbType;
             this.dbType = dbType;
@@ -351,7 +351,7 @@ namespace System.Data.OleDb
                         throw ADP.UnknownDataTypeCode(value.GetType(), ic.GetTypeCode());
                 }
             }
-            else if (value is System.Byte[])
+            else if (value is byte[])
             {
                 return NativeDBType.D_VarBinary;
             }
index fcb80d5..dec3f2d 100644 (file)
@@ -692,7 +692,7 @@ namespace System.Data.OleDb
         {
             StringBuilder builder = new StringBuilder();
             builder.Append(hr.ToString());
-            if ((0 < builder.Length) && Char.IsDigit(builder[0]))
+            if ((0 < builder.Length) && char.IsDigit(builder[0]))
             {
                 builder.Length = 0;
             }
index 45872b2..cf3e941 100644 (file)
@@ -10,10 +10,10 @@ using System.Runtime.InteropServices;
 
 namespace System.Data.OleDb
 {
-    sealed internal class OleDbPropertyInfo
+    internal sealed class OleDbPropertyInfo
     {
         public Guid _propertySet;
-        public Int32 _propertyID;
+        public int _propertyID;
         public string _description;
         public string _lowercase;
         public Type _type;
@@ -152,49 +152,49 @@ namespace System.Data.OleDb
                 case VarEnum.VT_NULL:
                     return typeof(System.DBNull);
                 case VarEnum.VT_I2:
-                    return typeof(System.Int16);
+                    return typeof(short);
                 case VarEnum.VT_I4:
-                    return typeof(System.Int32);
+                    return typeof(int);
                 case VarEnum.VT_R4:
-                    return typeof(System.Single);
+                    return typeof(float);
                 case VarEnum.VT_R8:
-                    return typeof(System.Double);
+                    return typeof(double);
                 case VarEnum.VT_CY:
-                    return typeof(System.Decimal);
+                    return typeof(decimal);
                 case VarEnum.VT_DATE:
                     return typeof(System.DateTime);
                 case VarEnum.VT_BSTR:
-                    return typeof(System.String);
+                    return typeof(string);
                 case VarEnum.VT_DISPATCH:
-                    return typeof(System.Object);
+                    return typeof(object);
                 case VarEnum.VT_ERROR:
-                    return typeof(System.Int32);
+                    return typeof(int);
                 case VarEnum.VT_BOOL:
-                    return typeof(System.Boolean);
+                    return typeof(bool);
                 case VarEnum.VT_VARIANT:
-                    return typeof(System.Object);
+                    return typeof(object);
                 case VarEnum.VT_UNKNOWN:
-                    return typeof(System.Object);
+                    return typeof(object);
                 case VarEnum.VT_DECIMAL:
-                    return typeof(System.Decimal);
+                    return typeof(decimal);
                 case VarEnum.VT_I1:
-                    return typeof(System.SByte);
+                    return typeof(sbyte);
                 case VarEnum.VT_UI1:
-                    return typeof(System.Byte);
+                    return typeof(byte);
                 case VarEnum.VT_UI2:
-                    return typeof(System.UInt16);
+                    return typeof(ushort);
                 case VarEnum.VT_UI4:
-                    return typeof(System.UInt32);
+                    return typeof(uint);
                 case VarEnum.VT_I8:
-                    return typeof(System.Int64);
+                    return typeof(long);
                 case VarEnum.VT_UI8:
-                    return typeof(System.UInt64);
+                    return typeof(ulong);
                 case VarEnum.VT_INT:
-                    return typeof(System.Int32);
+                    return typeof(int);
                 case VarEnum.VT_UINT:
-                    return typeof(System.UInt32);
+                    return typeof(uint);
                 default:
-                    return typeof(System.Object);
+                    return typeof(object);
             }
         }
     }
index 74f1a03..3c8c3ea 100644 (file)
@@ -9,7 +9,7 @@ using System.Runtime.InteropServices;
 
 namespace System.Data.OleDb
 {
-    sealed internal class RowBinding : System.Data.ProviderBase.DbBuffer
+    internal sealed class RowBinding : System.Data.ProviderBase.DbBuffer
     {
         private readonly int _bindingCount;
         private readonly int _headerLength;
index ab6ddbf..fd0f61b 100644 (file)
@@ -414,13 +414,13 @@ namespace System.Data.OleDb
         /// LARGE_INTEGER
         /// </summary>
         [FieldOffset(0)]
-        internal Int64 hVal;
+        internal long hVal;
 
         /// <summary>
         /// ULARGE_INTEGER
         /// </summary>
         [FieldOffset(0)]
-        internal UInt64 uhVal;
+        internal ulong uhVal;
 
         /// <summary>
         /// FLOAT
@@ -730,7 +730,7 @@ namespace System.Data.OleDb
 
     internal class NativeOledbWrapper
     {
-        internal unsafe static OleDbHResult IChapteredRowsetReleaseChapter(System.IntPtr ptr, System.IntPtr chapter)
+        internal static unsafe OleDbHResult IChapteredRowsetReleaseChapter(System.IntPtr ptr, System.IntPtr chapter)
         {
             OleDbHResult hr = OleDbHResult.E_UNEXPECTED;
             IntPtr hchapter = chapter;
@@ -752,7 +752,7 @@ namespace System.Data.OleDb
             return hr;
         }
 
-        internal unsafe static OleDbHResult ITransactionAbort(System.IntPtr ptr)
+        internal static unsafe OleDbHResult ITransactionAbort(System.IntPtr ptr)
         {
             OleDbHResult hr = OleDbHResult.E_UNEXPECTED;
             ITransactionLocal transactionLocal = null;
@@ -773,7 +773,7 @@ namespace System.Data.OleDb
             return hr;
         }
 
-        internal unsafe static OleDbHResult ITransactionCommit(System.IntPtr ptr)
+        internal static unsafe OleDbHResult ITransactionCommit(System.IntPtr ptr)
         {
             OleDbHResult hr = OleDbHResult.E_UNEXPECTED;
             ITransactionLocal transactionLocal = null;
@@ -794,7 +794,7 @@ namespace System.Data.OleDb
             return hr;
         }
 
-        internal static bool MemoryCompare(System.IntPtr buf1, System.IntPtr buf2, System.Int32 count)
+        internal static bool MemoryCompare(System.IntPtr buf1, System.IntPtr buf2, int count)
         {
             Debug.Assert(buf1 != buf2, "buf1 and buf2 are the same");
             Debug.Assert(buf1.ToInt64() < buf2.ToInt64() || buf2.ToInt64() + count <= buf1.ToInt64(), "overlapping region buf1");
@@ -810,7 +810,7 @@ namespace System.Data.OleDb
             }
         }
 
-        internal static void MemoryCopy(System.IntPtr dst, System.IntPtr src, System.Int32 count)
+        internal static void MemoryCopy(System.IntPtr dst, System.IntPtr src, int count)
         {
             Debug.Assert(dst != src, "dst and src are the same");
             Debug.Assert(dst.ToInt64() < src.ToInt64() || src.ToInt64() + count <= dst.ToInt64(), "overlapping region dst");
index 9260dc1..5c0eb75 100644 (file)
@@ -55,7 +55,7 @@ namespace System.Data.Common
         static internal extern IntPtr LocalFree(IntPtr handle);
 
         [DllImport(Interop.Libraries.OleAut32, CharSet = CharSet.Unicode)]
-        internal static extern IntPtr SysAllocStringLen(String src, int len);  // BSTR
+        internal static extern IntPtr SysAllocStringLen(string src, int len);  // BSTR
 
         [DllImport(Interop.Libraries.OleAut32)]
         internal static extern void SysFreeString(IntPtr bstr);
@@ -63,7 +63,7 @@ namespace System.Data.Common
         // only using this to clear existing error info with null
         [DllImport(Interop.Libraries.OleAut32, CharSet = CharSet.Unicode, PreserveSig = false)]
         // TLS values are preserved between threads, need to check that we use this API to clear the error state only.
-        static private extern void SetErrorInfo(Int32 dwReserved, IntPtr pIErrorInfo);
+        static private extern void SetErrorInfo(int dwReserved, IntPtr pIErrorInfo);
 
         [DllImport(Interop.Libraries.Kernel32, SetLastError = true)]
         static internal extern int ReleaseSemaphore(IntPtr handle, int releaseCount, IntPtr previousCount);
@@ -80,7 +80,7 @@ namespace System.Data.Common
         [DllImport(Interop.Libraries.OleAut32, PreserveSig = false)]
         static internal extern void VariantClear(IntPtr pObject);
 
-        sealed internal class Wrapper
+        internal sealed class Wrapper
         {
             private Wrapper() { }
 
index f81bd46..374672b 100644 (file)
@@ -1036,7 +1036,7 @@ namespace System.Data.Common
             return FileVersionInfo.GetVersionInfo(filename);
         }
 
-        static internal Stream GetXmlStreamFromValues(String[] values, String errorString)
+        static internal Stream GetXmlStreamFromValues(string[] values, string errorString)
         {
             if (values.Length != 1)
             {
@@ -1048,7 +1048,7 @@ namespace System.Data.Common
         // metadata files are opened from <.NetRuntimeFolder>\CONFIG\<metadatafilename.xml>
         // this operation is safe in SxS because the file is opened in read-only mode and each NDP runtime accesses its own copy of the metadata
         // under the runtime folder.
-        static internal Stream GetXmlStream(String value, String errorString)
+        static internal Stream GetXmlStream(string value, string errorString)
         {
             Stream XmlStream;
             const string config = "config\\";
@@ -1062,7 +1062,7 @@ namespace System.Data.Common
             tempstring.Append(rootPath);
             tempstring.Append(config);
             tempstring.Append(value);
-            String fullPath = tempstring.ToString();
+            string fullPath = tempstring.ToString();
 
             // don't allow relative paths
             if (ADP.GetFullPath(fullPath) != fullPath)
@@ -1145,10 +1145,10 @@ namespace System.Data.Common
                 else
                 {
                     string[] parts = version.Split('.');
-                    major = Int32.Parse(parts[0], NumberStyles.None, CultureInfo.InvariantCulture);
-                    minor = Int32.Parse(parts[1], NumberStyles.None, CultureInfo.InvariantCulture);
-                    build = Int32.Parse(parts[2], NumberStyles.None, CultureInfo.InvariantCulture);
-                    Int32.Parse(parts[3], NumberStyles.None, CultureInfo.InvariantCulture);
+                    major = int.Parse(parts[0], NumberStyles.None, CultureInfo.InvariantCulture);
+                    minor = int.Parse(parts[1], NumberStyles.None, CultureInfo.InvariantCulture);
+                    build = int.Parse(parts[2], NumberStyles.None, CultureInfo.InvariantCulture);
+                    int.Parse(parts[3], NumberStyles.None, CultureInfo.InvariantCulture);
                 }
             }
             catch (Exception e)
@@ -1179,7 +1179,7 @@ namespace System.Data.Common
 
         // the return value is true if the string was quoted and false if it was not
         // this allows the caller to determine if it is an error or not for the quotedString to not be quoted
-        static internal Boolean RemoveStringQuotes(string quotePrefix, string quoteSuffix, string quotedString, out string unquotedString)
+        static internal bool RemoveStringQuotes(string quotePrefix, string quoteSuffix, string quotedString, out string unquotedString)
         {
             int prefixLength;
             if (quotePrefix == null)
@@ -1249,7 +1249,7 @@ namespace System.Data.Common
             return true;
         }
 
-        static internal IntPtr IntPtrOffset(IntPtr pbase, Int32 offset)
+        static internal IntPtr IntPtrOffset(IntPtr pbase, int offset)
         {
             if (4 == ADP.PtrSize)
             {
@@ -1268,8 +1268,8 @@ namespace System.Data.Common
             else
             {
                 long lval = (long)value;
-                lval = Math.Min((long)Int32.MaxValue, lval);
-                lval = Math.Max((long)Int32.MinValue, lval);
+                lval = Math.Min((long)int.MaxValue, lval);
+                lval = Math.Max((long)int.MinValue, lval);
                 return (int)lval;
             }
         }
index 97ffbf0..019dd7d 100644 (file)
@@ -66,7 +66,7 @@ namespace System.Data.ProviderBase
             }
         }
 
-        internal String PtrToStringUni(int offset, int length)
+        internal string PtrToStringUni(int offset, int length)
         {
             offset += BaseOffset;
             Validate(offset, 2 * length);
@@ -151,7 +151,7 @@ namespace System.Data.ProviderBase
             return destination;
         }
 
-        internal Char ReadChar(int offset)
+        internal char ReadChar(int offset)
         {
             short value = ReadInt16(offset);
             return unchecked((char)value);
@@ -184,13 +184,13 @@ namespace System.Data.ProviderBase
             return destination;
         }
 
-        internal Double ReadDouble(int offset)
+        internal double ReadDouble(int offset)
         {
-            Int64 value = ReadInt64(offset);
+            long value = ReadInt64(offset);
             return BitConverter.Int64BitsToDouble(value);
         }
 
-        internal Int16 ReadInt16(int offset)
+        internal short ReadInt16(int offset)
         {
             offset += BaseOffset;
             ValidateCheck(offset, 2);
@@ -242,7 +242,7 @@ namespace System.Data.ProviderBase
             }
         }
 
-        internal Int32 ReadInt32(int offset)
+        internal int ReadInt32(int offset)
         {
             offset += BaseOffset;
             ValidateCheck(offset, 4);
@@ -294,7 +294,7 @@ namespace System.Data.ProviderBase
             }
         }
 
-        internal Int64 ReadInt64(int offset)
+        internal long ReadInt64(int offset)
         {
             offset += BaseOffset;
             ValidateCheck(offset, 8);
@@ -346,10 +346,10 @@ namespace System.Data.ProviderBase
             return value;
         }
 
-        internal unsafe Single ReadSingle(int offset)
+        internal unsafe float ReadSingle(int offset)
         {
-            Int32 value = ReadInt32(offset);
-            return *(Single*)&value;
+            int value = ReadInt32(offset);
+            return *(float*)&value;
         }
 
         protected override bool ReleaseHandle()
@@ -465,7 +465,7 @@ namespace System.Data.ProviderBase
             }
         }
 
-        internal void WriteDouble(int offset, Double value)
+        internal void WriteDouble(int offset, double value)
         {
             WriteInt64(offset, BitConverter.DoubleToInt64Bits(value));
         }
@@ -618,9 +618,9 @@ namespace System.Data.ProviderBase
             }
         }
 
-        internal unsafe void WriteSingle(int offset, Single value)
+        internal unsafe void WriteSingle(int offset, float value)
         {
-            WriteInt32(offset, *(Int32*)&value);
+            WriteInt32(offset, *(int*)&value);
         }
 
         internal Guid ReadGuid(int offset)
@@ -703,7 +703,7 @@ namespace System.Data.ProviderBase
             WriteInt32(offset + 12, ticks);
         }
 
-        internal Decimal ReadNumeric(int offset)
+        internal decimal ReadNumeric(int offset)
         {
             byte[] bits = new byte[20];
             ReadBytes(offset, bits, 1, 19);
@@ -721,17 +721,17 @@ namespace System.Data.ProviderBase
             {
                 throw ADP.NumericToDecimalOverflow();
             }
-            return new Decimal(buffer);
+            return new decimal(buffer);
         }
 
-        internal void WriteNumeric(int offset, Decimal value, byte precision)
+        internal void WriteNumeric(int offset, decimal value, byte precision)
         {
-            int[] tmp = Decimal.GetBits(value);
+            int[] tmp = decimal.GetBits(value);
             byte[] buffer = new byte[20];
 
             buffer[1] = precision;
             Buffer.BlockCopy(tmp, 14, buffer, 2, 2); // copy sign and scale
-            buffer[3] = (Byte)((0 == buffer[3]) ? 1 : 0); // flip sign for native
+            buffer[3] = (byte)((0 == buffer[3]) ? 1 : 0); // flip sign for native
             Buffer.BlockCopy(tmp, 0, buffer, 4, 12);
             buffer[16] = 0;
             buffer[17] = 0;
index 91f7986..5e43db9 100644 (file)
@@ -77,7 +77,7 @@ namespace System.Data.ProviderBase
         }
     }
 
-    sealed internal class DbConnectionClosedBusy : DbConnectionBusy
+    internal sealed class DbConnectionClosedBusy : DbConnectionBusy
     {
         // Closed Connection, Currently Busy - changing connection string
         internal static readonly DbConnectionInternal SingletonInstance = new DbConnectionClosedBusy();   // singleton object
@@ -87,7 +87,7 @@ namespace System.Data.ProviderBase
         }
     }
 
-    sealed internal class DbConnectionOpenBusy : DbConnectionBusy
+    internal sealed class DbConnectionOpenBusy : DbConnectionBusy
     {
         // Open Connection, Currently Busy - closing connection
         internal static readonly DbConnectionInternal SingletonInstance = new DbConnectionOpenBusy();   // singleton object
@@ -97,7 +97,7 @@ namespace System.Data.ProviderBase
         }
     }
 
-    sealed internal class DbConnectionClosedConnecting : DbConnectionBusy
+    internal sealed class DbConnectionClosedConnecting : DbConnectionBusy
     {
         // Closed Connection, Currently Connecting
 
@@ -138,7 +138,7 @@ namespace System.Data.ProviderBase
         }
     }
 
-    sealed internal class DbConnectionClosedNeverOpened : DbConnectionClosed
+    internal sealed class DbConnectionClosedNeverOpened : DbConnectionClosed
     {
         // Closed Connection, Has Never Been Opened
 
@@ -149,7 +149,7 @@ namespace System.Data.ProviderBase
         }
     }
 
-    sealed internal class DbConnectionClosedPreviouslyOpened : DbConnectionClosed
+    internal sealed class DbConnectionClosedPreviouslyOpened : DbConnectionClosed
     {
         // Closed Connection, Has Previously Been Opened
 
index a909cd0..5811e40 100644 (file)
@@ -133,11 +133,11 @@ namespace System.Data.ProviderBase
                         // native resources and GC may not happen soon enough.
                         // don't dispose if still holding reference in _enlistedTransaction
                         if (null != previousTransactionClone &&
-                                !Object.ReferenceEquals(previousTransactionClone, _enlistedTransaction))
+                                !object.ReferenceEquals(previousTransactionClone, _enlistedTransaction))
                         {
                             previousTransactionClone.Dispose();
                         }
-                        if (null != valueClone && !Object.ReferenceEquals(valueClone, _enlistedTransaction))
+                        if (null != valueClone && !object.ReferenceEquals(valueClone, _enlistedTransaction))
                         {
                             valueClone.Dispose();
                         }
index 9f7048f..e4b7fc4 100644 (file)
@@ -17,7 +17,7 @@ namespace System.Data.ProviderBase
 {
     using SysTx = Transactions;
 
-    sealed internal class DbConnectionPool
+    internal sealed class DbConnectionPool
     {
         private enum State
         {
@@ -509,7 +509,7 @@ namespace System.Data.ProviderBase
             get { return (null != _identity && DbConnectionPoolIdentity.NoIdentity != _identity); }
         }
 
-        private void CleanupCallback(Object state)
+        private void CleanupCallback(object state)
         {
             // Called when the cleanup-timer ticks over.
 
@@ -922,7 +922,7 @@ namespace System.Data.ProviderBase
             }
         }
 
-        private void ErrorCallback(Object state)
+        private void ErrorCallback(object state)
         {
             _errorOccurred = false;
             _waitHandles.ErrorEvent.Reset();
index 0c4aaeb..68f0901 100644 (file)
@@ -89,7 +89,7 @@ namespace System.Data.ProviderBase
                                                                         PerformanceCounterType.NumberOfItems32);
         };
 
-        sealed internal class Counter
+        internal sealed class Counter
         {
             private PerformanceCounter _instance;
 
@@ -260,7 +260,7 @@ namespace System.Data.ProviderBase
             // to PERFMON.  They recommend that we translate them as shown below, to 
             // prevent problems.
 
-            result = String.Format((IFormatProvider)null, "{0}[{1}]", instanceName, pid);
+            result = string.Format((IFormatProvider)null, "{0}[{1}]", instanceName, pid);
             result = result.Replace('(', '[').Replace(')', ']').Replace('#', '_').Replace('/', '_').Replace('\\', '_');
 
             // counter instance name cannot be greater than 127
@@ -331,7 +331,7 @@ namespace System.Data.ProviderBase
         }
     }
 
-    sealed internal class DbConnectionPoolCountersNoCounters : DbConnectionPoolCounters
+    internal sealed class DbConnectionPoolCountersNoCounters : DbConnectionPoolCounters
     {
         public static readonly DbConnectionPoolCountersNoCounters SingletonInstance = new DbConnectionPoolCountersNoCounters();
 
index 7963975..f3f8063 100644 (file)
@@ -25,7 +25,7 @@ namespace System.Data.ProviderBase
     // and once no pools remain, change state from Active->Idle->Disabled
     // Once Disabled, factory can remove its reference to the pool entry
 
-    sealed internal class DbConnectionPoolGroup
+    internal sealed class DbConnectionPoolGroup
     {
         private readonly DbConnectionOptions _connectionOptions;
         private readonly DbConnectionPoolKey _poolKey;
index 02042da..985fba8 100644 (file)
@@ -16,13 +16,13 @@ using System.Runtime.Versioning;
 
 namespace System.Data.ProviderBase
 {
-    sealed internal class DbConnectionPoolIdentity
+    internal sealed class DbConnectionPoolIdentity
     {
         private const int E_NotImpersonationToken = unchecked((int)0x8007051D);
         private const int Win32_CheckTokenMembership = 1;
         private const int Win32_CreateWellKnownSid = 5;
 
-        static public readonly DbConnectionPoolIdentity NoIdentity = new DbConnectionPoolIdentity(String.Empty, false, true);
+        static public readonly DbConnectionPoolIdentity NoIdentity = new DbConnectionPoolIdentity(string.Empty, false, true);
 
         private readonly string _sidString;
         private readonly bool _isRestricted;
index d209359..d2d4a98 100644 (file)
@@ -122,7 +122,7 @@ namespace System.Data.ProviderBase
             }
         }
 
-        private DataTable ExecuteCommand(DataRow requestedCollectionRow, String[] restrictions, DbConnection connection)
+        private DataTable ExecuteCommand(DataRow requestedCollectionRow, string[] restrictions, DbConnection connection)
         {
             DataTable metaDataCollectionsTable = _metaDataCollectionsDataSet.Tables[DbMetaDataCollectionNames.MetaDataCollections];
             DataColumn populationStringColumn = metaDataCollectionsTable.Columns[_populationString];
@@ -135,9 +135,9 @@ namespace System.Data.ProviderBase
             DataTable schemaTable = null;
 
             Debug.Assert(requestedCollectionRow != null);
-            String sqlCommand = requestedCollectionRow[populationStringColumn, DataRowVersion.Current] as string;
+            string sqlCommand = requestedCollectionRow[populationStringColumn, DataRowVersion.Current] as string;
             int numberOfRestrictions = (int)requestedCollectionRow[numberOfRestrictionsColumn, DataRowVersion.Current];
-            String collectionName = requestedCollectionRow[collectionNameColumn, DataRowVersion.Current] as string;
+            string collectionName = requestedCollectionRow[collectionNameColumn, DataRowVersion.Current] as string;
 
             if ((restrictions != null) && (restrictions.Length > numberOfRestrictions))
             {
@@ -264,13 +264,13 @@ namespace System.Data.ProviderBase
 
             DataColumn collectionNameColumn = metaDataCollectionsTable.Columns[DbMetaDataColumnNames.CollectionName];
 
-            if ((null == collectionNameColumn) || (typeof(System.String) != collectionNameColumn.DataType))
+            if ((null == collectionNameColumn) || (typeof(string) != collectionNameColumn.DataType))
             {
                 throw ADP.InvalidXmlMissingColumn(DbMetaDataCollectionNames.MetaDataCollections, DbMetaDataColumnNames.CollectionName);
             }
 
             DataRow requestedCollectionRow = null;
-            String exactCollectionName = null;
+            string exactCollectionName = null;
 
             // find the requested collection
             versionFailure = false;
@@ -524,7 +524,7 @@ namespace System.Data.ProviderBase
             _metaDataCollectionsDataSet.ReadXml(XmlStream);
         }
 
-        protected virtual DataTable PrepareCollection(String collectionName, String[] restrictions, DbConnection connection)
+        protected virtual DataTable PrepareCollection(string collectionName, string[] restrictions, DbConnection connection)
         {
             throw ADP.NotSupported();
         }
@@ -534,7 +534,7 @@ namespace System.Data.ProviderBase
             bool result = true;
             DataColumnCollection tableColumns = requestedCollectionRow.Table.Columns;
             DataColumn versionColumn;
-            Object version;
+            object version;
 
             // check the minimum version first
             versionColumn = tableColumns[_minimumVersion];
index c63be49..3866780 100644 (file)
@@ -17,7 +17,7 @@ namespace System.Data.Common
 
         [DllImport(Interop.Libraries.OleAut32, CharSet = CharSet.Unicode, PreserveSig = true)]
         static internal extern System.Data.OleDb.OleDbHResult GetErrorInfo(
-            [In] Int32 dwReserved,
+            [In] int dwReserved,
             [Out, MarshalAs(UnmanagedType.Interface)] out IErrorInfo ppIErrorInfo);
 
         [Guid("00000567-0000-0010-8000-00AA006D2EA4"), InterfaceType(ComInterfaceType.InterfaceIsDual), ComImport, SuppressUnmanagedCodeSecurity]
@@ -231,10 +231,10 @@ namespace System.Data.Common
             [Obsolete("not used", true)] void GetBindings(/*deleted parameters signature*/);
 
             /*[local]
-               HRESULT ReleaseAccessor(
-                       [in] HACCESSOR hAccessor,
-                       [in, out, unique] DBREFCOUNT * pcRefCount
-               );*/
+            HRESULT ReleaseAccessor(
+                [in] HACCESSOR hAccessor,
+                [in, out, unique] DBREFCOUNT * pcRefCount
+            );*/
             [PreserveSig]
             System.Data.OleDb.OleDbHResult ReleaseAccessor(
                 [In] IntPtr hAccessor,
@@ -261,10 +261,10 @@ namespace System.Data.Common
         internal interface IColumnsInfo
         {
             /*[local]
-               HRESULT GetColumnInfo(
-                       [in, out] DBORDINAL * pcColumns,
-                       [out, size_is(,(ULONG)*pcColumns)] DBCOLUMNINFO ** prgInfo,
-                       [out] OLECHAR ** ppStringsBuffer
+            HRESULT GetColumnInfo(
+                [in, out] DBORDINAL * pcColumns,
+                [out, size_is(,(ULONG)*pcColumns)] DBCOLUMNINFO ** prgInfo,
+                [out] OLECHAR ** ppStringsBuffer
             );*/
             [PreserveSig]
             System.Data.OleDb.OleDbHResult GetColumnInfo(
@@ -329,12 +329,12 @@ namespace System.Data.Common
         internal interface ICommandProperties
         {
             /*[local]
-               HRESULT GetProperties(
-                       [in] const ULONG cPropertyIDSets,
-                       [in, size_is(cPropertyIDSets)] const DBPROPIDSET rgPropertyIDSets[],
-                       [in, out] ULONG * pcPropertySets,
-                       [out, size_is(,*pcPropertySets)] DBPROPSET ** prgPropertySets
-               );*/
+            HRESULT GetProperties(
+                [in] const ULONG cPropertyIDSets,
+                [in, size_is(cPropertyIDSets)] const DBPROPIDSET rgPropertyIDSets[],
+                [in, out] ULONG * pcPropertySets,
+                [out, size_is(,*pcPropertySets)] DBPROPSET ** prgPropertySets
+            );*/
             [PreserveSig]
             System.Data.OleDb.OleDbHResult GetProperties(
                 [In] int cPropertyIDSets,
@@ -419,9 +419,9 @@ namespace System.Data.Common
         internal interface IDBInfo
         {
             /*[local]
-               HRESULT GetKeywords(
-                       [out] LPOLESTR * ppwszKeywords
-               );*/
+            HRESULT    GetKeywords(
+                [out] LPOLESTR * ppwszKeywords
+            );*/
             [PreserveSig]
             System.Data.OleDb.OleDbHResult GetKeywords(
                 [Out, MarshalAs(UnmanagedType.LPWStr)] out string ppwszKeywords);
@@ -500,11 +500,11 @@ namespace System.Data.Common
                 [Out, MarshalAs(UnmanagedType.Interface)] out IRowset ppRowset);
 
             /*[local]
-               HRESULT GetSchemas(
-                       [in, out] ULONG * pcSchemas,
-                       [out, size_is(,*pcSchemas)] GUID ** prgSchemas,
-                       [out, size_is(,*pcSchemas)] ULONG ** prgRestrictionSupport
-               );*/
+            HRESULT GetSchemas(
+                [in, out] ULONG * pcSchemas,
+                [out, size_is(,*pcSchemas)] GUID ** prgSchemas,
+                [out, size_is(,*pcSchemas)] ULONG ** prgRestrictionSupport
+            );*/
             [PreserveSig]
             System.Data.OleDb.OleDbHResult GetSchemas(
                 [Out] out int pcSchemas,
@@ -553,18 +553,18 @@ namespace System.Data.Common
 
             [PreserveSig]
             System.Data.OleDb.OleDbHResult GetCustomErrorObject( // may return E_NOINTERFACE when asking for IID_ISQLErrorInfo
-                [In] Int32 ulRecordNum,
+                [In] int ulRecordNum,
                 [In] ref Guid riid,
                 [Out, MarshalAs(UnmanagedType.Interface)] out ISQLErrorInfo ppObject);
 
             [return: MarshalAs(UnmanagedType.Interface)]
             IErrorInfo GetErrorInfo(
-                [In] Int32 ulRecordNum,
-                [In] Int32 lcid);
+                [In] int ulRecordNum,
+                [In] int lcid);
 
             [Obsolete("not used", true)] void GetErrorParameters(/*deleted parameter signature*/);
 
-            Int32 GetRecordCount();
+            int GetRecordCount();
         }
 #if false
     MIDL_INTERFACE("0c733a67-2a1c-11ce-ade5-00aa0044773d")
@@ -734,8 +734,8 @@ namespace System.Data.Common
         internal interface ISQLErrorInfo
         {
             [return: MarshalAs(UnmanagedType.I4)]
-            Int32 GetSQLInfo(
-                [Out, MarshalAs(UnmanagedType.BStr)] out String pbstrSQLState);
+            int GetSQLInfo(
+                [Out, MarshalAs(UnmanagedType.BStr)] out string pbstrSQLState);
         }
 
         [Guid("0C733A5F-2A1C-11CE-ADE5-00AA0044773D"), InterfaceType(ComInterfaceType.InterfaceIsIUnknown), ComImport, SuppressUnmanagedCodeSecurity]
index 480de62..1bec853 100644 (file)
@@ -3725,7 +3725,7 @@ namespace Microsoft.SqlServer.Server
         {
             // set up writer
             XmlWriterSettings WriterSettings = new XmlWriterSettings();
-            WriterSettings.CloseOutput = false;                // don't close the memory stream
+            WriterSettings.CloseOutput = false; // don't close the memory stream
             WriterSettings.ConformanceLevel = ConformanceLevel.Fragment;
             WriterSettings.Encoding = System.Text.Encoding.Unicode;
             WriterSettings.OmitXmlDeclaration = true;
index b5d5792..be97b8c 100644 (file)
@@ -8,7 +8,7 @@ using System.Data.SqlClient;
 
 namespace System.Data.ProviderBase
 {
-    sealed internal partial class DbConnectionPool
+    internal sealed partial class DbConnectionPool
     {
         partial void CheckPoolBlockingPeriod(Exception e)
         {
index 62728f0..8428454 100644 (file)
@@ -16,7 +16,7 @@ using System.Transactions;
 
 namespace System.Data.ProviderBase
 {
-    sealed internal partial class DbConnectionPool
+    internal sealed partial class DbConnectionPool
     {
         private enum State
         {
index 128a072..a402a8f 100644 (file)
@@ -4,7 +4,7 @@
 
 namespace System.Data.ProviderBase
 {
-    sealed internal partial class DbConnectionPoolIdentity
+    internal sealed partial class DbConnectionPoolIdentity
     {
         public static readonly DbConnectionPoolIdentity NoIdentity = new DbConnectionPoolIdentity(string.Empty, false, true);
 
index 6abe3b7..2728f02 100644 (file)
@@ -1239,7 +1239,7 @@ namespace Microsoft.SqlServer.Server
                 case TypeCode.Single: smd = new SqlMetaData(name, SqlDbType.Real); break;
                 case TypeCode.String:
                     {
-                        long maxLen = ((String)value).Length;
+                        long maxLen = ((string)value).Length;
                         if (maxLen < 1) maxLen = 1;
 
                         if (x_lServerMaxUnicode < maxLen)
@@ -1254,7 +1254,7 @@ namespace Microsoft.SqlServer.Server
                 case TypeCode.Object:
                     if (dataType == typeof(byte[]))
                     {
-                        long maxLen = ((System.Byte[])value).Length;
+                        long maxLen = ((byte[])value).Length;
                         if (maxLen < 1) maxLen = 1;
 
                         if (x_lServerMaxBinary < maxLen)
@@ -1264,7 +1264,7 @@ namespace Microsoft.SqlServer.Server
                     }
                     else if (dataType == typeof(char[]))
                     {
-                        long maxLen = ((System.Char[])value).Length;
+                        long maxLen = ((char[])value).Length;
                         if (maxLen < 1) maxLen = 1;
 
                         if (x_lServerMaxUnicode < maxLen)
index f9fd9dc..778752b 100644 (file)
@@ -5,15 +5,15 @@
 
 namespace System.Data.SqlClient
 {
-       // this structure is used for transporting packet handle references between the TdsParserStateObject
-       //  base class and Managed or Native implementations. 
-       // It prevents the native IntPtr type from being boxed and prevents the need to cast from object which loses compile time type safety
-       // It carries type information so that assertions about the type of handle can be made in the implemented abstract methods 
-       // it is a ref struct so that it can only be used to transport the handles and not store them
+    // this structure is used for transporting packet handle references between the TdsParserStateObject
+    //  base class and Managed or Native implementations. 
+    // It prevents the native IntPtr type from being boxed and prevents the need to cast from object which loses compile time type safety
+    // It carries type information so that assertions about the type of handle can be made in the implemented abstract methods 
+    // it is a ref struct so that it can only be used to transport the handles and not store them
 
-       // N.B. If you change this type you must also change the version for the other platform
+    // N.B. If you change this type you must also change the version for the other platform
 
-       internal readonly ref struct PacketHandle
+    internal readonly ref struct PacketHandle
     {
         public const int NativePointerType = 1;
         public const int NativePacketType = 2;
@@ -28,6 +28,6 @@ namespace System.Data.SqlClient
             ManagedPacket = managedPacket;
         }
 
-               public static PacketHandle FromManagedPacket(SNI.SNIPacket managedPacket) => new PacketHandle(managedPacket, ManagedPacketType);
-       }
+        public static PacketHandle FromManagedPacket(SNI.SNIPacket managedPacket) => new PacketHandle(managedPacket, ManagedPacketType);
+    }
 }
index ce03faf..302dbb1 100644 (file)
@@ -103,7 +103,7 @@ namespace System.Data.SqlClient.SNI
 
                 if (disposeAfterWriteAsync)
                 {
-                                       Release();
+                    Release();
                 }
 
                 // Completed
index 5bf099a..2c46719 100644 (file)
@@ -5,15 +5,15 @@
 
 namespace System.Data.SqlClient
 {
-       // this structure is used for transporting packet handle references between the TdsParserStateObject
-       //  base class and Managed or Native implementations. 
-       // It carries type information so that assertions about the type of handle can be made in the 
-       //  implemented abstract methods 
-       // it is a ref struct so that it can only be used to transport the handles and not store them
+    // this structure is used for transporting packet handle references between the TdsParserStateObject
+    //  base class and Managed or Native implementations. 
+    // It carries type information so that assertions about the type of handle can be made in the 
+    //  implemented abstract methods 
+    // it is a ref struct so that it can only be used to transport the handles and not store them
 
-       // N.B. If you change this type you must also change the version for the other platform
+    // N.B. If you change this type you must also change the version for the other platform
 
-       internal readonly ref struct SessionHandle
+    internal readonly ref struct SessionHandle
     {
         public const int NativeHandleType = 1;
         public const int ManagedHandleType = 2;
@@ -29,6 +29,6 @@ namespace System.Data.SqlClient
 
         public bool IsNull => ManagedHandle is null;
 
-               public static SessionHandle FromManagedSession(SNI.SNIHandle managedSessionHandle) => new SessionHandle(managedSessionHandle, ManagedHandleType);
-       }
+        public static SessionHandle FromManagedSession(SNI.SNIHandle managedSessionHandle) => new SessionHandle(managedSessionHandle, ManagedHandleType);
+    }
 }
index 94b6c85..c1ad7a7 100644 (file)
@@ -17,7 +17,7 @@ using System.Data.Common;
 namespace System.Data.SqlClient
 {
     // Caches the bytes returned from partial length prefixed datatypes, like XML
-    sealed internal class SqlCachedBuffer : System.Data.SqlTypes.INullable
+    internal sealed class SqlCachedBuffer : System.Data.SqlTypes.INullable
     {
         public static readonly SqlCachedBuffer Null = new SqlCachedBuffer();
         private const int _maxChunkSize = 2048; // Arbitrary value for chunk size. Revisit this later for better perf
index 774b2a5..6625b41 100644 (file)
@@ -12,7 +12,7 @@ using System.IO;
 
 namespace System.Data.SqlClient
 {
-    sealed internal class SqlConnectionFactory : DbConnectionFactory
+    internal sealed class SqlConnectionFactory : DbConnectionFactory
     {
         private SqlConnectionFactory() : base() { }
 
index e129147..845549d 100644 (file)
@@ -11,7 +11,7 @@ using System.Data.ProviderBase;
 
 namespace System.Data.SqlClient
 {
-    sealed internal class SqlConnectionPoolGroupProviderInfo : DbConnectionPoolGroupProviderInfo
+    internal sealed class SqlConnectionPoolGroupProviderInfo : DbConnectionPoolGroupProviderInfo
     {
         private string _alias;
         private string _failoverPartner;
index 2236367..520ecf2 100644 (file)
@@ -66,7 +66,7 @@ namespace System.Data.SqlClient
         public override bool Equals(object obj)
         {
             SqlConnectionPoolKey key = obj as SqlConnectionPoolKey;
-            return (key != null && _credential == key._credential && ConnectionString == key.ConnectionString && Object.ReferenceEquals(_accessToken, key._accessToken));
+            return (key != null && _credential == key._credential && ConnectionString == key.ConnectionString && object.ReferenceEquals(_accessToken, key._accessToken));
         }
 
         public override int GetHashCode()
index 5f4251e..30fc801 100644 (file)
@@ -1063,7 +1063,7 @@ namespace System.Data.SqlClient
             {
                 if (_parser.State == TdsParserState.Broken || _parser.State == TdsParserState.Closed)
                 {
-                    // Happened for DEVDIV2:180509     (SqlDataReader.ConsumeMetaData Hangs In 100% CPU Loop Forever When TdsParser._state == TdsParserState.Broken)
+                    // Happened for DEVDIV2:180509    (SqlDataReader.ConsumeMetaData Hangs In 100% CPU Loop Forever When TdsParser._state == TdsParserState.Broken)
                     // during request for DTC address.
                     // NOTE: We doom connection for TdsParserState.Closed since it indicates that it is in some abnormal and unstable state, probably as a result of
                     // closing from another thread. In general, TdsParserState.Closed does not necessitate dooming the connection.
index 7f7b9fe..b3eebc9 100644 (file)
@@ -6,7 +6,7 @@ using System.Transactions;
 
 namespace System.Data.SqlClient
 {
-    sealed internal partial class SqlDelegatedTransaction : IPromotableSinglePhaseNotification
+    internal sealed partial class SqlDelegatedTransaction : IPromotableSinglePhaseNotification
     {
         // Get the server-side Global Transaction Id from the PromotedDTCToken
         // Skip first 4 bytes since they contain the version
index e99802e..47a226c 100644 (file)
@@ -6,7 +6,7 @@ using System.Transactions;
 
 namespace System.Data.SqlClient
 {
-    sealed internal partial class SqlDelegatedTransaction : IPromotableSinglePhaseNotification
+    internal sealed partial class SqlDelegatedTransaction : IPromotableSinglePhaseNotification
     {
         // Get the server-side Global Transaction Id from the PromotedDTCToken
         // Skip first 4 bytes since they contain the version
index c61d0b4..96a9c57 100644 (file)
@@ -13,7 +13,7 @@ using System.Transactions;
 
 namespace System.Data.SqlClient
 {
-    sealed internal partial class SqlDelegatedTransaction : IPromotableSinglePhaseNotification
+    internal sealed partial class SqlDelegatedTransaction : IPromotableSinglePhaseNotification
     {
         private static int _objectTypeCount;
         private readonly int _objectID = Interlocked.Increment(ref _objectTypeCount);
index b56cad3..65a1074 100644 (file)
@@ -14,7 +14,7 @@ namespace System.Data.SqlTypes
             throw new PlatformNotSupportedException(SR.SqlFileStream_NotSupported);
         }
 
-        public SqlFileStream(string path, byte[] transactionContext, FileAccess access, FileOptions options, Int64 allocationSize)
+        public SqlFileStream(string path, byte[] transactionContext, FileAccess access, FileOptions options, long allocationSize)
         {
             throw new PlatformNotSupportedException(SR.SqlFileStream_NotSupported);
         }
index f12abb4..b2b19b9 100644 (file)
@@ -99,7 +99,7 @@ namespace System.Data.SqlClient
         }
     }
 
-    sealed internal class SqlInternalConnectionTds : SqlInternalConnection, IDisposable
+    internal sealed class SqlInternalConnectionTds : SqlInternalConnection, IDisposable
     {
         // CONNECTION AND STATE VARIABLES
         private readonly SqlConnectionPoolGroupProviderInfo _poolGroupProviderInfo; // will only be null when called for ChangePassword, or creating SSE User Instance
@@ -499,7 +499,7 @@ namespace System.Data.SqlClient
             }
         }
 
-        internal protected override bool IsNonPoolableTransactionRoot
+        protected internal override bool IsNonPoolableTransactionRoot
         {
             get
             {
index 7ae5f3d..574fe24 100644 (file)
@@ -30,7 +30,7 @@ namespace System.Data.SqlClient
         Context = 5,     // only valid in proc.
     };
 
-    sealed internal class SqlInternalTransaction
+    internal sealed class SqlInternalTransaction
     {
         internal const long NullTransactionId = 0;
 
index 7698581..6ecb583 100644 (file)
@@ -141,7 +141,7 @@ namespace System.Data.SqlClient
         {
             if (value is decimal)
             {
-                return ((System.Data.SqlTypes.SqlDecimal)(Decimal)value).Precision;
+                return ((System.Data.SqlTypes.SqlDecimal)(decimal)value).Precision;
             }
             return 0;
         }
index 824516a..2cf5729 100644 (file)
@@ -11,7 +11,7 @@ using System.Data.ProviderBase;
 
 namespace System.Data.SqlClient
 {
-    sealed internal class SqlReferenceCollection : DbReferenceCollection
+    internal sealed class SqlReferenceCollection : DbReferenceCollection
     {
         internal const int DataReaderTag = 1;
         internal const int CommandTag = 2;
index 08289a9..e0ce518 100644 (file)
@@ -9,7 +9,7 @@ using System.Threading.Tasks;
 
 namespace System.Data.SqlClient
 {
-    sealed internal class SqlSequentialStream : System.IO.Stream
+    internal sealed class SqlSequentialStream : System.IO.Stream
     {
         private SqlDataReader _reader;  // The SqlDataReader that we are reading data from
         private int _columnIndex;       // The index of out column in the table
index ee6bbf1..420736d 100644 (file)
@@ -10,7 +10,7 @@ using System.Threading.Tasks;
 
 namespace System.Data.SqlClient
 {
-    sealed internal class SqlSequentialTextReader : System.IO.TextReader
+    internal sealed class SqlSequentialTextReader : System.IO.TextReader
     {
         private SqlDataReader _reader;  // The SqlDataReader that we are reading data from
         private int _columnIndex;       // The index of out column in the table
@@ -476,7 +476,7 @@ namespace System.Data.SqlClient
         }
     }
 
-    sealed internal class SqlUnicodeEncoding : UnicodeEncoding
+    internal sealed class SqlUnicodeEncoding : UnicodeEncoding
     {
         private static SqlUnicodeEncoding s_singletonEncoding = new SqlUnicodeEncoding();
 
index ff35151..217cb84 100644 (file)
@@ -16,7 +16,7 @@ using System.Xml;
 
 namespace System.Data.SqlClient
 {
-    sealed internal class SqlStream : Stream
+    internal sealed class SqlStream : Stream
     {
         private SqlDataReader _reader; // reader we will stream off
         private int _columnOrdinal;
@@ -314,7 +314,7 @@ namespace System.Data.SqlClient
     // case. This causes double buffering and is a perf hit, but this is not the high perf way for accessing this type of data.
     // In the case of sequential access, we do not have to do any buffering since the XmlTextReader we return can become 
     // invalid as soon as we move off the current column.
-    sealed internal class SqlCachedStream : Stream
+    internal sealed class SqlCachedStream : Stream
     {
         private int _currentPosition;   // Position within the current array byte
         private int _currentArrayIndex; // Index into the _cachedBytes List
@@ -548,7 +548,7 @@ namespace System.Data.SqlClient
         }
     }
 
-    sealed internal class SqlStreamingXml
+    internal sealed class SqlStreamingXml
     {
         private int _columnOrdinal;
         private SqlDataReader _reader;
index 7dce1aa..911b29e 100644 (file)
@@ -1031,7 +1031,7 @@ namespace System.Data.SqlClient
         internal const string SqlNotificationStoredProcedureDefault = "SqlQueryNotificationStoredProcedure";
     }
 
-    sealed internal class SQLMessage
+    internal sealed class SQLMessage
     {
         private SQLMessage() { /* prevent utility class from being instantiated*/ }
 
index 41e557b..d51115f 100644 (file)
@@ -541,7 +541,7 @@ namespace System.Data.SqlClient
         public const short SNI_WSAECONNRESET = 10054;    // An existing connection was forcibly closed by the remote host.
 
         // SNI internal errors (shouldn't overlap with Win32 / socket errors)
-        public const uint SNI_QUEUE_FULL = 1048576;             // Packet queue is full
+        public const uint SNI_QUEUE_FULL = 1048576;         // Packet queue is full
 
         // SNI flags
         public const uint SNI_SSL_VALIDATE_CERTIFICATE = 1;   // This enables validation of server certificate
index bdd54a9..29626d5 100644 (file)
@@ -9,23 +9,23 @@ namespace System.Data.SqlClient
 {
     internal sealed partial class TdsParser
     {
-               internal static void FillGuidBytes(Guid guid, Span<byte> buffer)
+        internal static void FillGuidBytes(Guid guid, Span<byte> buffer)
         {
             byte[] bytes = guid.ToByteArray();
             bytes.AsSpan().CopyTo(buffer);
         }
 
-               internal static void FillDoubleBytes(double value, Span<byte> buffer)
-               {
-                       byte[] bytes = BitConverter.GetBytes(value);
-                       bytes.AsSpan().CopyTo(buffer);
-               }
+        internal static void FillDoubleBytes(double value, Span<byte> buffer)
+        {
+            byte[] bytes = BitConverter.GetBytes(value);
+            bytes.AsSpan().CopyTo(buffer);
+        }
 
-               internal static void FillFloatBytes(float value, Span<byte> buffer)
-               {
-                       byte[] bytes = BitConverter.GetBytes(value);
-                       bytes.AsSpan().CopyTo(buffer);
-               }
+        internal static void FillFloatBytes(float value, Span<byte> buffer)
+        {
+            byte[] bytes = BitConverter.GetBytes(value);
+            bytes.AsSpan().CopyTo(buffer);
+        }
 
         internal static Guid ConstructGuid(ReadOnlySpan<byte> bytes)
         {
index d709a16..a0881ae 100644 (file)
@@ -7,7 +7,7 @@ using System.Data.SqlClient.SNI;
 
 namespace System.Data.SqlClient
 {
-    sealed internal partial class TdsParser
+    internal sealed partial class TdsParser
     {
         internal void PostReadAsyncForMars()
         {
@@ -41,4 +41,4 @@ namespace System.Data.SqlClient
         }
 
     }    // tdsparser
-}//namespace
\ No newline at end of file
+}//namespace
index 000f4ef..8f91cbf 100644 (file)
@@ -3371,7 +3371,7 @@ namespace System.Data.SqlClient
             if (0 != collation.sortId)
             {
                 codePage = TdsEnums.CODE_PAGE_FROM_SORT_ID[collation.sortId];
-                Debug.Assert(0 != codePage, "GetCodePage accessed codepage array and produced 0!, sortID =" + ((Byte)(collation.sortId)).ToString((IFormatProvider)null));
+                Debug.Assert(0 != codePage, "GetCodePage accessed codepage array and produced 0!, sortID =" + ((byte)(collation.sortId)).ToString((IFormatProvider)null));
             }
             else
             {
@@ -8699,7 +8699,7 @@ namespace System.Data.SqlClient
                             return true;
                     }
                 }
-                else if ((currentType == typeof(string)) && (((String)value).Length > 0))
+                else if ((currentType == typeof(string)) && (((string)value).Length > 0))
                 {
                     if ((value != null) && (((string)value)[0] & 0xff) != 0xff)
                         return true;
index 33c0af0..c531d87 100644 (file)
@@ -15,7 +15,7 @@ using System.Runtime.InteropServices;
 
 namespace System.Data.SqlClient
 {
-    sealed internal class LastIOTimer
+    internal sealed class LastIOTimer
     {
         internal long _value;
     }
index 5e160fb..fc27f62 100644 (file)
@@ -1004,7 +1004,7 @@ namespace System.Data.SqlClient.ManualTesting.Tests
             {
                 conn.Open();
 
-                // select with SqlChars        parameter
+                // select with SqlChars parameter
                 SqlCommand cmd;
                 SqlDataReader reader;
                 using (cmd = conn.CreateCommand())
@@ -1022,7 +1022,7 @@ namespace System.Data.SqlClient.ManualTesting.Tests
                     }
                 }
 
-                // select with SqlBytes        parameter
+                // select with SqlBytes parameter
                 using (cmd = conn.CreateCommand())
                 {
                     cmd.CommandText = "select EmployeeID, FirstName, LastName from Employees where EmployeeID = 2 and Convert(binary(5), Photo) = @bn ";
index 0e98b87..b29851c 100644 (file)
@@ -185,7 +185,7 @@ namespace Stress.Data
         }
 
 
-        #region        CommandExecute and Consume methods
+        #region CommandExecute and Consume methods
 
         /// <summary>
         /// Utility function used by command tests
@@ -466,7 +466,7 @@ namespace Stress.Data
 
         #endregion
 
-        #region        Command and Parameter Tests
+        #region Command and Parameter Tests
 
         /// <summary>
         /// Command Reader Test: Executes a simple SELECT statement without parameters
index 413076a..f14cb4d 100644 (file)
@@ -40,19 +40,19 @@ namespace Microsoft.SqlServer.TDS.EndPoint
         /// <summary>
         /// It is called when SPNEGO response arrives
         /// </summary>
-        /// <param name="packet">TDS message received</param>          
+        /// <param name="packet">TDS message received</param>
         TDSMessage OnSSPIResponse(TDSMessage message);
 
         /// <summary>
         /// It is called when FedAuthInfoToken response arrives
         /// </summary>
-        /// <param name="packet">TDS message received</param>          
+        /// <param name="packet">TDS message received</param>
         TDSMessage OnFedAuthInfoTokenResponse(TDSMessage message);
 
         /// <summary>
         /// It is called when login acknowledgement arrives.
         /// </summary>
-        /// <param name="packet">TDS message received</param>          
+        /// <param name="packet">TDS message received</param>
         void OnLoginResponse(TDSMessage message);
 
         /// <summary>
index 458392e..5340a77 100644 (file)
@@ -54,7 +54,7 @@ namespace Microsoft.SqlServer.TDS.EndPoint
                             // Check the client context for encryption state
                             if (Client.Context.Encryption != TDSEncryptionType.Off)
                             {
-                                // Turn on encryption before sending the response                                                              
+                                // Turn on encryption before sending the response
                                 EnableClientTransportEncryption(Client.Context.ServerHost);
                             }
 
index 4349110..a2335d2 100644 (file)
@@ -138,7 +138,7 @@ namespace Microsoft.SqlServer.TDS.Login7
 
         /// <summary>
         /// Inflating constructor
-        /// </summary>         
+        /// </summary>
         public TDSLogin7FedAuthOptionToken(Stream source)
             : this()
         {
@@ -377,4 +377,4 @@ namespace Microsoft.SqlServer.TDS.Login7
             return randomBytes;
         }
     }
-}
\ No newline at end of file
+}
index 32421f1..8a2be30 100644 (file)
@@ -47,7 +47,7 @@ namespace Microsoft.SqlServer.TDS.Login7
 
         /// <summary>
         /// Inflating constructor
-        /// </summary>         
+        /// </summary>
         public TDSLogin7GenericOptionToken(Stream source) :
             this()
         {
index 610e908..fd8086c 100644 (file)
@@ -38,7 +38,7 @@ namespace Microsoft.SqlServer.TDS.Login7
 
         /// <summary>
         /// Inflating constructor
-        /// </summary>         
+        /// </summary>
         public TDSLogin7SessionRecoveryOptionToken(Stream source) :
             this()
         {
index 4793cc6..29eef1c 100644 (file)
@@ -34,7 +34,7 @@ namespace Microsoft.SqlServer.TDS.Login7
         /// <summary>
         /// Initialization constructor
         /// </summary>
-               public TDSLogin7TokenOffsetProperty(PropertyInfo property, ushort position, ushort length)
+        public TDSLogin7TokenOffsetProperty(PropertyInfo property, ushort position, ushort length)
         {
             Property = property;
             Position = position;
@@ -44,7 +44,7 @@ namespace Microsoft.SqlServer.TDS.Login7
         /// <summary>
         /// Initialization constructor
         /// </summary>
-               public TDSLogin7TokenOffsetProperty(PropertyInfo property, ushort position, ushort length, bool isOffsetOffset) :
+        public TDSLogin7TokenOffsetProperty(PropertyInfo property, ushort position, ushort length, bool isOffsetOffset) :
             this(property, position, length)
         {
             IsOffsetOffset = isOffsetOffset;
index 7a5288f..368eae2 100644 (file)
@@ -115,7 +115,7 @@ namespace Microsoft.SqlServer.TDS.PreLogin
 
         /// <summary>
         /// Initialization constructor
-        /// </summary>         
+        /// </summary>
         public TDSPreLoginToken(Version version, TDSPreLoginTokenEncryptionType encryption, bool isMARS, uint threadID, TdsPreLoginFedAuthRequiredOption fedAuthRequired) :
             this(version, encryption, isMARS, threadID)
         {
index 9dcead8..5082615 100644 (file)
@@ -1103,7 +1103,7 @@ namespace System.Diagnostics
         /// Sets the bytes in 'outBytes' to be random values.   outBytes.Length must be less than or equal to 16
         /// </summary>
         /// <param name="outBytes"></param>
-        internal unsafe static void SetToRandomBytes(Span<byte> outBytes)
+        internal static unsafe void SetToRandomBytes(Span<byte> outBytes)
         {
             Debug.Assert(outBytes.Length <= sizeof(Guid));     // Guid is 16 bytes, and so is TraceId 
             Guid guid = Guid.NewGuid();
@@ -1219,7 +1219,7 @@ namespace System.Diagnostics
         /// <summary>
         /// Create a new SpanId with at random number in it (very likely to be unique)
         /// </summary>
-        public unsafe static ActivitySpanId CreateRandom()
+        public static unsafe ActivitySpanId CreateRandom()
         {
             ulong id;
             ActivityTraceId.SetToRandomBytes(new Span<byte>(&id, sizeof(ulong)));
index 903d1ed..b599680 100644 (file)
@@ -309,7 +309,7 @@ namespace System.Diagnostics
                 // Write out the value characters, escaping things as needed.  
                 foreach(var c in keyValue.Value)
                 {
-                    if (Char.IsControl(c))
+                    if (char.IsControl(c))
                     {
                         if (c == '\n')
                             sb.Append("\\n");
index bb6c2e4..f3f37de 100644 (file)
@@ -70,7 +70,7 @@ namespace System.Diagnostics
         private BitVector32 boolFlags = new BitVector32();
 
         private Hashtable messageLibraries;
-        private readonly static Hashtable listenerInfos = new Hashtable(StringComparer.OrdinalIgnoreCase);
+        private static readonly Hashtable listenerInfos = new Hashtable(StringComparer.OrdinalIgnoreCase);
 
         private object m_InstanceLockObject;
         private object InstanceLockObject
index 2cb4af6..a7d1069 100644 (file)
@@ -179,7 +179,7 @@ namespace System.Diagnostics.Eventing.Reader
             return pubEnum;
         }
 
-        public static EventLogHandle EvtOpenChannelConfig(EventLogHandle session, String channelPath, int flags)
+        public static EventLogHandle EvtOpenChannelConfig(EventLogHandle session, string channelPath, int flags)
         {
             EventLogHandle handle = UnsafeNativeMethods.EvtOpenChannelConfig(session, channelPath, flags);
             int win32Error = Marshal.GetLastWin32Error();
@@ -246,8 +246,8 @@ namespace System.Diagnostics.Eventing.Reader
         }
 
         public static EventLogHandle EvtCreateRenderContext(
-                            Int32 valuePathsCount,
-                            String[] valuePaths,
+                            int valuePathsCount,
+                            string[] valuePaths,
                             UnsafeNativeMethods.EvtRenderContextFlags flags)
         {
             EventLogHandle renderContextHandleValues = UnsafeNativeMethods.EvtCreateRenderContext(valuePathsCount, valuePaths, flags);
@@ -849,7 +849,7 @@ namespace System.Diagnostics.Eventing.Reader
                             systemProperties.Version = (byte?)ConvertToObject(varVal, UnsafeNativeMethods.EvtVariantType.EvtVarTypeByte);
                             break;
                     }
-                    pointer = new IntPtr(((Int64)pointer + Marshal.SizeOf(varVal)));
+                    pointer = new IntPtr(((long)pointer + Marshal.SizeOf(varVal)));
                 }
             }
             finally
@@ -893,7 +893,7 @@ namespace System.Diagnostics.Eventing.Reader
                     {
                         UnsafeNativeMethods.EvtVariant varVal = Marshal.PtrToStructure<UnsafeNativeMethods.EvtVariant>(pointer);
                         valuesList.Add(ConvertToObject(varVal));
-                        pointer = new IntPtr(((Int64)pointer + Marshal.SizeOf(varVal)));
+                        pointer = new IntPtr(((long)pointer + Marshal.SizeOf(varVal)));
                     }
                 }
                 return valuesList;
@@ -1003,11 +1003,11 @@ namespace System.Diagnostics.Eventing.Reader
                 while (true)
                 {
                     string s = Marshal.PtrToStringUni(pointer);
-                    if (String.IsNullOrEmpty(s))
+                    if (string.IsNullOrEmpty(s))
                         break;
                     keywordsList.Add(s);
                     // nr of bytes = # chars * 2 + 2 bytes for character '\0'.
-                    pointer = new IntPtr((Int64)pointer + (s.Length * 2) + 2);
+                    pointer = new IntPtr((long)pointer + (s.Length * 2) + 2);
                 }
 
                 return keywordsList.AsReadOnly();
@@ -1164,49 +1164,49 @@ namespace System.Diagnostics.Eventing.Reader
                 case ((int)UnsafeNativeMethods.EvtMasks.EVT_VARIANT_TYPE_ARRAY | (int)UnsafeNativeMethods.EvtVariantType.EvtVarTypeByte):
                     if (val.Reference == IntPtr.Zero)
                         return Array.Empty<byte>();
-                    Byte[] arByte = new Byte[val.Count];
+                    byte[] arByte = new byte[val.Count];
                     Marshal.Copy(val.Reference, arByte, 0, (int)val.Count);
                     return arByte;
                 case ((int)UnsafeNativeMethods.EvtMasks.EVT_VARIANT_TYPE_ARRAY | (int)UnsafeNativeMethods.EvtVariantType.EvtVarTypeInt16):
                     if (val.Reference == IntPtr.Zero)
                         return Array.Empty<short>();
-                    Int16[] arInt16 = new Int16[val.Count];
+                    short[] arInt16 = new short[val.Count];
                     Marshal.Copy(val.Reference, arInt16, 0, (int)val.Count);
                     return arInt16;
                 case ((int)UnsafeNativeMethods.EvtMasks.EVT_VARIANT_TYPE_ARRAY | (int)UnsafeNativeMethods.EvtVariantType.EvtVarTypeInt32):
                     if (val.Reference == IntPtr.Zero)
                         return Array.Empty<int>();
-                    Int32[] arInt32 = new Int32[val.Count];
+                    int[] arInt32 = new int[val.Count];
                     Marshal.Copy(val.Reference, arInt32, 0, (int)val.Count);
                     return arInt32;
                 case ((int)UnsafeNativeMethods.EvtMasks.EVT_VARIANT_TYPE_ARRAY | (int)UnsafeNativeMethods.EvtVariantType.EvtVarTypeInt64):
                     if (val.Reference == IntPtr.Zero)
                         return Array.Empty<long>();
-                    Int64[] arInt64 = new Int64[val.Count];
+                    long[] arInt64 = new long[val.Count];
                     Marshal.Copy(val.Reference, arInt64, 0, (int)val.Count);
                     return arInt64;
                 case ((int)UnsafeNativeMethods.EvtMasks.EVT_VARIANT_TYPE_ARRAY | (int)UnsafeNativeMethods.EvtVariantType.EvtVarTypeSingle):
                     if (val.Reference == IntPtr.Zero)
                         return Array.Empty<float>();
-                    Single[] arSingle = new Single[val.Count];
+                    float[] arSingle = new float[val.Count];
                     Marshal.Copy(val.Reference, arSingle, 0, (int)val.Count);
                     return arSingle;
                 case ((int)UnsafeNativeMethods.EvtMasks.EVT_VARIANT_TYPE_ARRAY | (int)UnsafeNativeMethods.EvtVariantType.EvtVarTypeDouble):
                     if (val.Reference == IntPtr.Zero)
                         return Array.Empty<double>();
-                    Double[] arDouble = new Double[val.Count];
+                    double[] arDouble = new double[val.Count];
                     Marshal.Copy(val.Reference, arDouble, 0, (int)val.Count);
                     return arDouble;
                 case ((int)UnsafeNativeMethods.EvtMasks.EVT_VARIANT_TYPE_ARRAY | (int)UnsafeNativeMethods.EvtVariantType.EvtVarTypeSByte):
-                    return ConvertToArray<SByte>(val, sizeof(SByte)); // not CLS-compliant
+                    return ConvertToArray<sbyte>(val, sizeof(sbyte)); // not CLS-compliant
                 case ((int)UnsafeNativeMethods.EvtMasks.EVT_VARIANT_TYPE_ARRAY | (int)UnsafeNativeMethods.EvtVariantType.EvtVarTypeUInt16):
-                    return ConvertToArray<UInt16>(val, sizeof(UInt16));
+                    return ConvertToArray<ushort>(val, sizeof(ushort));
                 case ((int)UnsafeNativeMethods.EvtMasks.EVT_VARIANT_TYPE_ARRAY | (int)UnsafeNativeMethods.EvtVariantType.EvtVarTypeUInt64):
                 case ((int)UnsafeNativeMethods.EvtMasks.EVT_VARIANT_TYPE_ARRAY | (int)UnsafeNativeMethods.EvtVariantType.EvtVarTypeHexInt64):
-                    return ConvertToArray<UInt64>(val, sizeof(UInt64));
+                    return ConvertToArray<ulong>(val, sizeof(ulong));
                 case ((int)UnsafeNativeMethods.EvtMasks.EVT_VARIANT_TYPE_ARRAY | (int)UnsafeNativeMethods.EvtVariantType.EvtVarTypeUInt32):
                 case ((int)UnsafeNativeMethods.EvtMasks.EVT_VARIANT_TYPE_ARRAY | (int)UnsafeNativeMethods.EvtVariantType.EvtVarTypeHexInt32):
-                    return ConvertToArray<UInt32>(val, sizeof(UInt32));
+                    return ConvertToArray<uint>(val, sizeof(uint));
                 case ((int)UnsafeNativeMethods.EvtMasks.EVT_VARIANT_TYPE_ARRAY | (int)UnsafeNativeMethods.EvtVariantType.EvtVarTypeString):
                     return ConvertToStringArray(val, false);
                 case ((int)UnsafeNativeMethods.EvtMasks.EVT_VARIANT_TYPE_ARRAY | (int)UnsafeNativeMethods.EvtVariantType.EvtVarTypeAnsiString):
@@ -1274,7 +1274,7 @@ namespace System.Diagnostics.Eventing.Reader
                 for (int i = 0; i < val.Count; i++)
                 {
                     array.SetValue(Marshal.PtrToStructure<T>(ptr), i);
-                    ptr = new IntPtr((Int64)ptr + size);
+                    ptr = new IntPtr((long)ptr + size);
                 }
                 return array;
             }
@@ -1295,7 +1295,7 @@ namespace System.Diagnostics.Eventing.Reader
                 {
                     bool value = (Marshal.ReadInt32(ptr) != 0) ? true : false;
                     array[i] = value;
-                    ptr = new IntPtr((Int64)ptr + 4);
+                    ptr = new IntPtr((long)ptr + 4);
                 }
                 return array;
             }
@@ -1314,7 +1314,7 @@ namespace System.Diagnostics.Eventing.Reader
                 for (int i = 0; i < val.Count; i++)
                 {
                     array[i] = DateTime.FromFileTime(Marshal.ReadInt64(ptr));
-                    ptr = new IntPtr((Int64)ptr + 8 * sizeof(byte)); // FILETIME values are 8 bytes
+                    ptr = new IntPtr((long)ptr + 8 * sizeof(byte)); // FILETIME values are 8 bytes
                 }
                 return array;
             }
@@ -1334,7 +1334,7 @@ namespace System.Diagnostics.Eventing.Reader
                 {
                     UnsafeNativeMethods.SystemTime sysTime = Marshal.PtrToStructure<UnsafeNativeMethods.SystemTime>(ptr);
                     array[i] = new DateTime(sysTime.Year, sysTime.Month, sysTime.Day, sysTime.Hour, sysTime.Minute, sysTime.Second, sysTime.Milliseconds);
-                    ptr = new IntPtr((Int64)ptr + 16 * sizeof(byte)); // SystemTime values are 16 bytes
+                    ptr = new IntPtr((long)ptr + 16 * sizeof(byte)); // SystemTime values are 16 bytes
                 }
                 return array;
             }
index b7affdb..ff9e9f2 100644 (file)
@@ -196,11 +196,11 @@ namespace System.Diagnostics.Eventing.Reader
 
                             if (channelRefDisplayName == null && isImported)
                             {
-                                if (String.Compare(channelName, "Application", StringComparison.OrdinalIgnoreCase) == 0)
+                                if (string.Compare(channelName, "Application", StringComparison.OrdinalIgnoreCase) == 0)
                                     channelRefMessageId = 256;
-                                else if (String.Compare(channelName, "System", StringComparison.OrdinalIgnoreCase) == 0)
+                                else if (string.Compare(channelName, "System", StringComparison.OrdinalIgnoreCase) == 0)
                                     channelRefMessageId = 258;
-                                else if (String.Compare(channelName, "Security", StringComparison.OrdinalIgnoreCase) == 0)
+                                else if (string.Compare(channelName, "Security", StringComparison.OrdinalIgnoreCase) == 0)
                                     channelRefMessageId = 257;
                                 else
                                     channelRefMessageId = -1;
index fed02da..1d566a0 100644 (file)
@@ -21,7 +21,7 @@ namespace Microsoft.Win32
 {
     internal static partial class UnsafeNativeMethods
     {
-        internal const String WEVTAPI = "wevtapi.dll";
+        internal const string WEVTAPI = "wevtapi.dll";
 
         // WinError.h codes:
 
@@ -166,9 +166,9 @@ namespace Microsoft.Win32
         internal struct EvtVariant
         {
             [FieldOffset(0)]
-            public UInt32 UInteger;
+            public uint UInteger;
             [FieldOffset(0)]
-            public Int32 Integer;
+            public int Integer;
             [FieldOffset(0)]
             public byte UInt8;
             [FieldOffset(0)]
@@ -176,19 +176,19 @@ namespace Microsoft.Win32
             [FieldOffset(0)]
             public ushort UShort;
             [FieldOffset(0)]
-            public UInt32 Bool;
+            public uint Bool;
             [FieldOffset(0)]
-            public Byte ByteVal;
+            public byte ByteVal;
             [FieldOffset(0)]
             public byte SByte;
             [FieldOffset(0)]
-            public UInt64 ULong;
+            public ulong ULong;
             [FieldOffset(0)]
-            public Int64 Long;
+            public long Long;
             [FieldOffset(0)]
-            public Single Single;
+            public float Single;
             [FieldOffset(0)]
-            public Double Double;
+            public double Double;
             [FieldOffset(0)]
             public IntPtr StringVal;
             [FieldOffset(0)]
@@ -204,15 +204,15 @@ namespace Microsoft.Win32
             [FieldOffset(0)]
             public IntPtr GuidReference;
             [FieldOffset(0)]
-            public UInt64 FileTime;
+            public ulong FileTime;
             [FieldOffset(0)]
             public IntPtr SystemTime;
             [FieldOffset(0)]
             public IntPtr SizeT;
             [FieldOffset(8)]
-            public UInt32 Count;   // number of elements (not length) in bytes.
+            public uint Count;   // number of elements (not length) in bytes.
             [FieldOffset(12)]
-            public UInt32 Type;
+            public uint Type;
         }
 
         internal enum EvtEventPropertyId
@@ -586,7 +586,7 @@ namespace Microsoft.Win32
         [DllImport(WEVTAPI, CharSet = CharSet.Auto, SetLastError = true)]
         internal static extern EventLogHandle EvtOpenChannelConfig(
                             EventLogHandle session,
-                            [MarshalAs(UnmanagedType.LPWStr)]String channelPath,
+                            [MarshalAs(UnmanagedType.LPWStr)]string channelPath,
                             int flags
                                     );
 
@@ -662,9 +662,9 @@ namespace Microsoft.Win32
         // RENDERING
         [DllImport(WEVTAPI, CharSet = CharSet.Auto, SetLastError = true)]
         internal static extern EventLogHandle EvtCreateRenderContext(
-                            Int32 valuePathsCount,
+                            int valuePathsCount,
                             [MarshalAs(UnmanagedType.LPArray,ArraySubType = UnmanagedType.LPWStr)]
-                                String[] valuePaths,
+                                string[] valuePaths,
                             [MarshalAs(UnmanagedType.I4)]EvtRenderContextFlags flags
                                     );
 
@@ -696,9 +696,9 @@ namespace Microsoft.Win32
             [MarshalAs(UnmanagedType.LPWStr), FieldOffset(0)]
             public string StringVal;
             [FieldOffset(8)]
-            public UInt32 Count;
+            public uint Count;
             [FieldOffset(12)]
-            public UInt32 Type;
+            public uint Type;
         };
 
         [DllImport(WEVTAPI, CharSet = CharSet.Auto, SetLastError = true)]
index b8ad492..71b3f2d 100644 (file)
@@ -499,7 +499,7 @@ namespace System.Diagnostics
             return freeMemoryOffset;
         }
 
-        private unsafe static void PopulateLifetimeEntry(ProcessLifetimeEntry* lifetimeEntry, PerformanceCounterInstanceLifetime lifetime)
+        private static unsafe void PopulateLifetimeEntry(ProcessLifetimeEntry* lifetimeEntry, PerformanceCounterInstanceLifetime lifetime)
         {
 
             if (lifetime == PerformanceCounterInstanceLifetime.Process)
@@ -1385,7 +1385,7 @@ namespace System.Diagnostics
             return DecrementUnaligned(_counterEntryPointer);
         }
 
-        internal unsafe static void RemoveAllInstances(string categoryName)
+        internal static unsafe void RemoveAllInstances(string categoryName)
         {
             SharedPerformanceCounter spc = new SharedPerformanceCounter(categoryName, null, null);
             spc.RemoveAllInstances();
index cbd68db..f062ad3 100644 (file)
@@ -157,10 +157,10 @@ namespace System.Diagnostics
                     {
                         string nameString = names[(index * 2) + 1];
                         if (nameString == null)
-                            nameString = String.Empty;
+                            nameString = string.Empty;
 
                         int key;
-                        if (!Int32.TryParse(names[index * 2], NumberStyles.Integer, CultureInfo.InvariantCulture, out key))
+                        if (!int.TryParse(names[index * 2], NumberStyles.Integer, CultureInfo.InvariantCulture, out key))
                         {
                             if (isHelp)
                             {
index de7c53e..c82654b 100644 (file)
@@ -911,7 +911,7 @@ namespace System.Diagnostics
             return (userId.Value, groupId.Value, groups);
         }
 
-        private unsafe static (uint? userId, uint? groupId) GetUserAndGroupIds(string userName)
+        private static unsafe (uint? userId, uint? groupId) GetUserAndGroupIds(string userName)
         {
             Interop.Sys.Passwd? passwd;
             // First try with a buffer that should suffice for 99% of cases.
index 2266a10..c4e3843 100644 (file)
@@ -1027,7 +1027,7 @@ namespace System.Diagnostics.Tests
         }
 
         [DllImport("shlwapi.dll", CharSet = CharSet.Unicode, ExactSpelling = true)]
-        private unsafe static extern int AssocQueryStringW(
+        private static extern unsafe int AssocQueryStringW(
             int flags,
             int str,
             string pszAssoc,
@@ -1035,7 +1035,7 @@ namespace System.Diagnostics.Tests
             char* pszOut,
             ref uint pcchOut);
 
-        private unsafe static string GetAssociationString(int flags, int str, string pszAssoc, string pszExtra)
+        private static unsafe string GetAssociationString(int flags, int str, string pszAssoc, string pszExtra)
         {
             uint count = 0;
             int result = AssocQueryStringW(flags, str, pszAssoc, pszExtra, null, ref count);
index 3831814..9898ab0 100644 (file)
@@ -909,9 +909,9 @@ namespace System.Diagnostics.Tests
         private static extern uint getgid();
 
         [DllImport("libc", SetLastError = true)]
-        private unsafe static extern int getgroups(int size, uint* list);
+        private static extern unsafe int getgroups(int size, uint* list);
 
-        private unsafe static HashSet<uint> GetGroups()
+        private static unsafe HashSet<uint> GetGroups()
         {
             int maxSize = 128;
             Span<uint> groups = stackalloc uint[maxSize];
@@ -933,7 +933,7 @@ namespace System.Diagnostics.Tests
         private static extern int seteuid(uint euid);
 
         [DllImport("libc")]
-        private static unsafe extern int setgroups(int length, uint* groups);
+        private static extern unsafe int setgroups(int length, uint* groups);
 
         private const int SIGKILL = 9;
 
index 710e069..b2b1482 100644 (file)
@@ -40,7 +40,7 @@ namespace System.Diagnostics
                 if (_initializedLock == null)
                 {
                     object o = new object();
-                    Interlocked.CompareExchange<Object>(ref _initializedLock, o, null);
+                    Interlocked.CompareExchange<object>(ref _initializedLock, o, null);
                 }
 
                 return _initializedLock;
index e2fb764..eaa8f2c 100644 (file)
@@ -14,7 +14,7 @@ namespace System.DirectoryServices.AccountManagement
 {
     public class AdvancedFilters
     {
-        internal protected AdvancedFilters(Principal p)
+        protected internal AdvancedFilters(Principal p)
         {
             _p = p;
         }
index e3b2353..72bea11 100644 (file)
@@ -102,7 +102,7 @@ namespace System.DirectoryServices.AccountManagement
                         // Extract the group SIDs from the user's context.  Determine the size of the buffer we need.
                         f = UnsafeNativeMethods.AuthzGetInformationFromContext(
                                                     pClientContext,
-                                                    2,                 // AuthzContextInfoGroupsSids 
+                                                    2,                    // AuthzContextInfoGroupsSids 
                                                     0,
                                                     out bufferSize,
                                                     IntPtr.Zero
@@ -119,7 +119,7 @@ namespace System.DirectoryServices.AccountManagement
                             // Extract the group SIDs from the user's context, into our buffer.0
                             f = UnsafeNativeMethods.AuthzGetInformationFromContext(
                                                         pClientContext,
-                                                        2,                     // AuthzContextInfoGroupsSids 
+                                                        2,                    // AuthzContextInfoGroupsSids 
                                                         bufferSize,
                                                         out bufferSize,
                                                         pBuffer
index d107764..dc6d97a 100644 (file)
@@ -325,7 +325,7 @@ namespace System.DirectoryServices.AccountManagement
         //
         // Private implementation
         //
-        internal protected AuthenticablePrincipal(PrincipalContext context)
+        protected internal AuthenticablePrincipal(PrincipalContext context)
         {
             if (context == null)
                 throw new ArgumentException(SR.NullArguments);
@@ -335,7 +335,7 @@ namespace System.DirectoryServices.AccountManagement
             this.rosf = new AdvancedFilters(this);
         }
 
-        internal protected AuthenticablePrincipal(PrincipalContext context, string samAccountName, string password, bool enabled) : this(context)
+        protected internal AuthenticablePrincipal(PrincipalContext context, string samAccountName, string password, bool enabled) : this(context)
         {
             if (samAccountName != null)
             {
index 7eb377d..65b3e47 100644 (file)
@@ -758,7 +758,7 @@ namespace System.DirectoryServices.AccountManagement
         // hence the LinkDemand.
         [System.ComponentModel.Browsable(false)]
         [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
-        internal protected PrincipalContext ContextRaw
+        protected internal PrincipalContext ContextRaw
         {
             get
             { return _ctx; }
index f1fdb10..217ce6a 100644 (file)
@@ -27,8 +27,8 @@ namespace System.DirectoryServices.AccountManagement
         /// Performs bytewise comparison of two byte[] arrays
         /// </summary>
         /// <param name="src">Array to compare</param>
-        /// <param name="tgt">Array to compare against src</param>             
-        /// <returns>true if identical, false otherwise</returns>              
+        /// <param name="tgt">Array to compare against src</param>
+        /// <returns>true if identical, false otherwise</returns>
         internal static bool AreBytesEqual(byte[] src, byte[] tgt)
         {
             if (src.Length != tgt.Length)
index f5d8424..40f1431 100644 (file)
@@ -611,7 +611,7 @@ namespace System.DirectoryServices.AccountManagement
                                         );
 
         /*
-                [DllImport("authz.dll", SetLastError=true, CallingConvention=CallingConvention.StdCall, EntryPoint="AuthzInitializeContextFromToken", CharSet=CharSet.Unicode)]                                
+                [DllImport("authz.dll", SetLastError=true, CallingConvention=CallingConvention.StdCall, EntryPoint="AuthzInitializeContextFromToken", CharSet=CharSet.Unicode)]                
                 static extern public bool AuthzInitializeContextFromToken(
                                                 int Flags,
                                                 IntPtr TokenHandle,
index 330e5eb..dbc799e 100644 (file)
@@ -30,7 +30,7 @@ namespace System.DirectoryServices.ActiveDirectory
             Dispose(true);
         }
 
-        // private Dispose method              
+        // private Dispose method
         protected virtual void Dispose(bool disposing)
         {
             if (!_disposed)
index 61b29da..a059365 100644 (file)
@@ -78,28 +78,28 @@ namespace System.DirectoryServices.ActiveDirectory
         // syntaxes
         private static int s_syntaxesCount = 23;
         private static Syntax[] s_syntaxes = {/* CaseExactString */ new Syntax("2.5.5.3", 27, null),
-                                                                                          /* CaseIgnoreString */ new Syntax("2.5.5.4", 20, null),
-                                                                                          /* NumericString */ new Syntax("2.5.5.6", 18, null),
-                                                                                          /* DirectoryString */ new Syntax("2.5.5.12", 64, null),
-                                                                                          /* OctetString */ new Syntax("2.5.5.10", 4, null),
-                                                                                          /* SecurityDescriptor */ new Syntax("2.5.5.15", 66, null),
-                                                                                          /* Int */ new Syntax("2.5.5.9", 2, null),
-                                                                                          /* Int64 */ new Syntax("2.5.5.16", 65, null),
-                                                                                          /* Bool */ new Syntax("2.5.5.8", 1, null),
-                                                                                          /* Oid */ new Syntax("2.5.5.2", 6, null),
-                                                                                          /* GeneralizedTime */ new Syntax("2.5.5.11", 24, null),
-                                                                                          /* UtcTime */ new Syntax("2.5.5.11", 23, null),
-                                                                                          /* DN */ new Syntax("2.5.5.1", 127, s_dnOMObjectClass),
-                                                                                          /* DNWithBinary */ new Syntax("2.5.5.7", 127, s_dNWithBinaryOMObjectClass),
-                                                                                          /* DNWithString */ new Syntax("2.5.5.14", 127, s_dNWithStringOMObjectClass),
-                                                                                          /* Enumeration */ new Syntax("2.5.5.9", 10, null),
-                                                                                          /* IA5String */ new Syntax("2.5.5.5", 22, null),
-                                                                                          /* PrintableString */ new Syntax("2.5.5.5", 19, null),
-                                                                                          /* Sid */ new Syntax("2.5.5.17", 4, null),
-                                                                                          /* AccessPointDN */ new Syntax("2.5.5.14", 127, s_accessPointDnOMObjectClass),
-                                                                                          /* ORName */ new Syntax("2.5.5.7", 127, s_oRNameOMObjectClass),
-                                                                                          /* PresentationAddress */ new Syntax("2.5.5.13", 127, s_presentationAddressOMObjectClass),
-                                                                                          /* ReplicaLink */ new Syntax("2.5.5.10", 127, s_replicaLinkOMObjectClass)};
+                                              /* CaseIgnoreString */ new Syntax("2.5.5.4", 20, null),
+                                              /* NumericString */ new Syntax("2.5.5.6", 18, null),
+                                              /* DirectoryString */ new Syntax("2.5.5.12", 64, null),
+                                              /* OctetString */ new Syntax("2.5.5.10", 4, null),
+                                              /* SecurityDescriptor */ new Syntax("2.5.5.15", 66, null),
+                                              /* Int */ new Syntax("2.5.5.9", 2, null),
+                                              /* Int64 */ new Syntax("2.5.5.16", 65, null),
+                                              /* Bool */ new Syntax("2.5.5.8", 1, null),
+                                              /* Oid */ new Syntax("2.5.5.2", 6, null),
+                                              /* GeneralizedTime */ new Syntax("2.5.5.11", 24, null),
+                                              /* UtcTime */ new Syntax("2.5.5.11", 23, null),
+                                              /* DN */ new Syntax("2.5.5.1", 127, s_dnOMObjectClass),
+                                              /* DNWithBinary */ new Syntax("2.5.5.7", 127, s_dNWithBinaryOMObjectClass),
+                                              /* DNWithString */ new Syntax("2.5.5.14", 127, s_dNWithStringOMObjectClass),
+                                              /* Enumeration */ new Syntax("2.5.5.9", 10, null),
+                                              /* IA5String */ new Syntax("2.5.5.5", 22, null),
+                                              /* PrintableString */ new Syntax("2.5.5.5", 19, null),
+                                              /* Sid */ new Syntax("2.5.5.17", 4, null),
+                                              /* AccessPointDN */ new Syntax("2.5.5.14", 127, s_accessPointDnOMObjectClass),
+                                              /* ORName */ new Syntax("2.5.5.7", 127, s_oRNameOMObjectClass),
+                                              /* PresentationAddress */ new Syntax("2.5.5.13", 127, s_presentationAddressOMObjectClass),
+                                              /* ReplicaLink */ new Syntax("2.5.5.10", 127, s_replicaLinkOMObjectClass)};
 
         #region constructors
         public ActiveDirectorySchemaProperty(DirectoryContext context, string ldapDisplayName)
index 04dec45..b9d78cf 100644 (file)
@@ -55,7 +55,7 @@ namespace System.DirectoryServices.ActiveDirectory
             GC.SuppressFinalize(this);
         }
 
-        // private Dispose method              
+        // private Dispose method        
         protected virtual void Dispose(bool disposing)
         {
             if (!_disposed)
@@ -434,7 +434,7 @@ namespace System.DirectoryServices.ActiveDirectory
                         FreeReplicaInfo(DS_REPL_INFO_TYPE.DS_REPL_INFO_CURSORS_3_FOR_NC, info, libHandle);
                     }
 
-                    // get the next batch of results                       
+                    // get the next batch of results
                     info = GetReplicationInfoHelper(dsHandle, (int)DS_REPL_INFO_TYPE.DS_REPL_INFO_CURSORS_3_FOR_NC, (int)DS_REPL_INFO_TYPE.DS_REPL_INFO_CURSORS_FOR_NC, partition, ref advanced, context, libHandle);
                 }
             }
@@ -609,7 +609,7 @@ namespace System.DirectoryServices.ActiveDirectory
 
                 if (temp != (IntPtr)0)
                 {
-                    // error information is available                      
+                    // error information is available
                     exception = ExceptionHelper.CreateSyncAllException(temp, true);
                     if (exception == null)
                     {
index 06d9d89..4a64a31 100644 (file)
@@ -997,8 +997,8 @@ namespace System.DirectoryServices.ActiveDirectory
 
                 foreach (SearchResult res in resCol)
                 {
-                    // add the name of the appNC only if it is not 
-                    // the Schema or Configuration partition
+                    // add the name of the appNC only if it is not 
+                    // the Schema or Configuration partition
                     string nCName = (string)PropertyManager.GetSearchResultPropertyValue(res, PropertyManager.NCName);
                     if ((!(nCName.Equals(schemaNamingContext)))
                         && (!(nCName.Equals(configurationNamingContext))))
index d9fe9ee..f7a45ca 100644 (file)
@@ -9,16 +9,16 @@ namespace System.DirectoryServices.ActiveDirectory
 {
 
     /*typedef struct _DOMAIN_CONTROLLER_INFO {
-               LPTSTR DomainControllerName;
-               LPTSTR DomainControllerAddress;
-               ULONG DomainControllerAddressType;
-               GUID DomainGuid;
-               LPTSTR DomainName;
-               LPTSTR DnsForestName;
-               ULONG Flags;
-               LPTSTR DcSiteName;
-               LPTSTR ClientSiteName;
-       } DOMAIN_CONTROLLER_INFO, *PDOMAIN_CONTROLLER_INFO; */
+        LPTSTR DomainControllerName;
+        LPTSTR DomainControllerAddress;
+        ULONG DomainControllerAddressType;
+        GUID DomainGuid;
+        LPTSTR DomainName;
+        LPTSTR DnsForestName;
+        ULONG Flags;
+        LPTSTR DcSiteName;
+        LPTSTR ClientSiteName;
+    } DOMAIN_CONTROLLER_INFO, *PDOMAIN_CONTROLLER_INFO; */
     [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
     internal sealed class DomainControllerInfo
     {
@@ -34,21 +34,21 @@ namespace System.DirectoryServices.ActiveDirectory
     }
 
     /*typedef struct {  
-               LPTSTR NetbiosName;  
-               LPTSTR DnsHostName;  
-               LPTSTR SiteName;
-               LPTSTR SiteObjectName;    
-               LPTSTR ComputerObjectName;  
-               LPTSTR ServerObjectName;  
-               LPTSTR NtdsaObjectName;  
-               BOOL fIsPdc;  
-               BOOL fDsEnabled;  
-               BOOL fIsGc;  
-               GUID SiteObjectGuid;  
-               GUID ComputerObjectGuid;  
-               GUID ServerObjectGuid;  
-               GUID NtdsDsaObjectGuid;
-       } DS_DOMAIN_CONTROLLER_INFO_2, *PDS_DOMAIN_CONTROLLER_INFO_2;*/
+         LPTSTR NetbiosName;  
+        LPTSTR DnsHostName;  
+        LPTSTR SiteName;
+        LPTSTR SiteObjectName;    
+        LPTSTR ComputerObjectName;  
+        LPTSTR ServerObjectName;  
+        LPTSTR NtdsaObjectName;  
+        BOOL fIsPdc;  
+        BOOL fDsEnabled;  
+        BOOL fIsGc;  
+        GUID SiteObjectGuid;  
+        GUID ComputerObjectGuid;  
+        GUID ServerObjectGuid;  
+        GUID NtdsDsaObjectGuid;
+    } DS_DOMAIN_CONTROLLER_INFO_2, *PDS_DOMAIN_CONTROLLER_INFO_2;*/
     [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
     internal sealed class DsDomainControllerInfo2
     {
@@ -69,22 +69,22 @@ namespace System.DirectoryServices.ActiveDirectory
     }
 
     /*typedef struct {  
-               LPTSTR NetbiosName;  
-               LPTSTR DnsHostName;  
-               LPTSTR SiteName;
-               LPTSTR SiteObjectName;    
-               LPTSTR ComputerObjectName;  
-               LPTSTR ServerObjectName;  
-               LPTSTR NtdsaObjectName;  
-               BOOL fIsPdc;  
-               BOOL fDsEnabled;  
-               BOOL fIsGc;  
-               BOOL fIsRodc;  
-               GUID SiteObjectGuid;  
-               GUID ComputerObjectGuid;  
-               GUID ServerObjectGuid;  
-               GUID NtdsDsaObjectGuid;
-       } DS_DOMAIN_CONTROLLER_INFO_3, *PDS_DOMAIN_CONTROLLER_INFO_3;*/
+        LPTSTR NetbiosName;  
+        LPTSTR DnsHostName;  
+        LPTSTR SiteName;
+        LPTSTR SiteObjectName;    
+        LPTSTR ComputerObjectName;  
+        LPTSTR ServerObjectName;  
+        LPTSTR NtdsaObjectName;  
+        BOOL fIsPdc;  
+        BOOL fDsEnabled;  
+        BOOL fIsGc;  
+        BOOL fIsRodc;  
+        GUID SiteObjectGuid;  
+        GUID ComputerObjectGuid;  
+        GUID ServerObjectGuid;  
+        GUID NtdsDsaObjectGuid;
+    } DS_DOMAIN_CONTROLLER_INFO_3, *PDS_DOMAIN_CONTROLLER_INFO_3;*/
     [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
     internal sealed class DsDomainControllerInfo3
     {
@@ -106,9 +106,9 @@ namespace System.DirectoryServices.ActiveDirectory
     }
 
     /*typedef struct {
-               DWORD cItems;
-               PDS_NAME_RESULT_ITEM rItems;
-       } DS_NAME_RESULT, *PDS_NAME_RESULT;*/
+        DWORD cItems;
+        PDS_NAME_RESULT_ITEM rItems;
+    } DS_NAME_RESULT, *PDS_NAME_RESULT;*/
     [StructLayout(LayoutKind.Sequential)]
     internal sealed class DsNameResult
     {
@@ -117,10 +117,10 @@ namespace System.DirectoryServices.ActiveDirectory
     }
 
     /*typedef struct  {
-               DWORD status;
-               LPTSTR pDomain;
-               LPTSTR pName;
-       } DS_NAME_RESULT_ITEM, *PDS_NAME_RESULT_ITEM;*/
+        DWORD status;
+        LPTSTR pDomain;
+        LPTSTR pName;
+    } DS_NAME_RESULT_ITEM, *PDS_NAME_RESULT_ITEM;*/
     [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
     internal sealed class DsNameResultItem
     {
@@ -130,54 +130,54 @@ namespace System.DirectoryServices.ActiveDirectory
     }
 
     /*typedef struct _DnsRecord {
-               struct _DnsRecord * pNext;
-               LPTSTR              pName;
-               WORD                wType;
-               WORD                wDataLength; // Not referenced for DNS record 
-               //types defined above.
-               union {
-                       DWORD               DW;      // flags as DWORD
-                       DNS_RECORD_FLAGS    S;       // flags as structure
-               } Flags;
-
-               DWORD               dwTtl;
-               DWORD               dwReserved;
-
-               // Record Data
-               union {
-                       DNS_A_DATA      A;
-                       DNS_SOA_DATA    SOA, Soa;
-                       DNS_PTR_DATA    PTR, Ptr,
-                                                       NS, Ns,
-                                                       CNAME, Cname,
-                                                       MB, Mb,
-                                                       MD, Md,
-                                                       MF, Mf,
-                                                       MG, Mg,
-                                                       MR, Mr;
-                       DNS_MINFO_DATA  MINFO, Minfo,
-                                                       RP, Rp;
-                       DNS_MX_DATA     MX, Mx,
-                                                       AFSDB, Afsdb,
-                                                       RT, Rt;
-                       DNS_TXT_DATA    HINFO, Hinfo,
-                                                       ISDN, Isdn,
-                                                       TXT, Txt,
-                                                       X25;
-                       DNS_NULL_DATA   Null;
-                       DNS_WKS_DATA    WKS, Wks;
-                       DNS_AAAA_DATA   AAAA;
-                       DNS_KEY_DATA    KEY, Key;
-                       DNS_SIG_DATA    SIG, Sig;
-                       DNS_ATMA_DATA   ATMA, Atma;
-                       DNS_NXT_DATA    NXT, Nxt;
-                       DNS_SRV_DATA    SRV, Srv;
-                       DNS_TKEY_DATA   TKEY, Tkey;
-                       DNS_TSIG_DATA   TSIG, Tsig;
-                       DNS_WINS_DATA   WINS, Wins;
-                       DNS_WINSR_DATA  WINSR, WinsR, NBSTAT, Nbstat;
-               } Data;
-       }DNS_RECORD, *PDNS_RECORD;*/
+        struct _DnsRecord * pNext;
+        LPTSTR              pName;
+        WORD                wType;
+        WORD                wDataLength; // Not referenced for DNS record 
+        //types defined above.
+        union {
+            DWORD               DW;      // flags as DWORD
+            DNS_RECORD_FLAGS    S;       // flags as structure
+        } Flags;
+
+        DWORD               dwTtl;
+        DWORD               dwReserved;
+
+        // Record Data
+        union {
+            DNS_A_DATA      A;
+            DNS_SOA_DATA    SOA, Soa;
+            DNS_PTR_DATA    PTR, Ptr,
+                            NS, Ns,
+                            CNAME, Cname,
+                            MB, Mb,
+                            MD, Md,
+                            MF, Mf,
+                            MG, Mg,
+                            MR, Mr;
+            DNS_MINFO_DATA  MINFO, Minfo,
+                            RP, Rp;
+            DNS_MX_DATA     MX, Mx,
+                            AFSDB, Afsdb,
+                            RT, Rt;
+            DNS_TXT_DATA    HINFO, Hinfo,
+                            ISDN, Isdn,
+                            TXT, Txt,
+                            X25;
+            DNS_NULL_DATA   Null;
+            DNS_WKS_DATA    WKS, Wks;
+            DNS_AAAA_DATA   AAAA;
+            DNS_KEY_DATA    KEY, Key;
+            DNS_SIG_DATA    SIG, Sig;
+            DNS_ATMA_DATA   ATMA, Atma;
+            DNS_NXT_DATA    NXT, Nxt;
+            DNS_SRV_DATA    SRV, Srv;
+            DNS_TKEY_DATA   TKEY, Tkey;
+            DNS_TSIG_DATA   TSIG, Tsig;
+            DNS_WINS_DATA   WINS, Wins;
+            DNS_WINSR_DATA  WINSR, WinsR, NBSTAT, Nbstat;
+        } Data;
+    }DNS_RECORD, *PDNS_RECORD;*/
     [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
     internal sealed class DnsRecord
     {
@@ -205,12 +205,12 @@ namespace System.DirectoryServices.ActiveDirectory
     }
 
     /*typedef struct {
-               LPTSTR      pNameTarget;
-               WORD        wPriority;
-               WORD        wWeight;
-               WORD        wPort;
-               WORD        Pad;            // keep ptrs DWORD aligned
-       }DNS_SRV_DATA, *PDNS_SRV_DATA;*/
+        LPTSTR      pNameTarget;
+        WORD        wPriority;
+        WORD        wWeight;
+        WORD        wPort;
+        WORD        Pad;            // keep ptrs DWORD aligned
+    }DNS_SRV_DATA, *PDNS_SRV_DATA;*/
     [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
     internal sealed class DnsSrvData
     {
@@ -222,18 +222,18 @@ namespace System.DirectoryServices.ActiveDirectory
     }
 
     /*typedef struct _OSVERSIONINFOEX {
-               DWORD dwOSVersionInfoSize;
-               DWORD dwMajorVersion;
-               DWORD dwMinorVersion;
-               DWORD dwBuildNumber;
-               DWORD dwPlatformId;
-               TCHAR szCSDVersion[ 128 ];
-               WORD wServicePackMajor;
-               WORD wServicePackMinor;
-               WORD wSuiteMask;
-               BYTE wProductType;
-               BYTE wReserved;
-               } OSVERSIONINFOEX, *POSVERSIONINFOEX, *LPOSVERSIONINFOEX;*/
+        DWORD dwOSVersionInfoSize;
+        DWORD dwMajorVersion;
+        DWORD dwMinorVersion;
+        DWORD dwBuildNumber;
+        DWORD dwPlatformId;
+        TCHAR szCSDVersion[ 128 ];
+        WORD wServicePackMajor;
+        WORD wServicePackMinor;
+        WORD wSuiteMask;
+        BYTE wProductType;
+        BYTE wReserved;
+        } OSVERSIONINFOEX, *POSVERSIONINFOEX, *LPOSVERSIONINFOEX;*/
     [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
     internal sealed class OSVersionInfoEx
     {
@@ -258,9 +258,9 @@ namespace System.DirectoryServices.ActiveDirectory
     }
 
     /*typedef struct _LUID {
-               DWORD LowPart;
-               LONG HighPart;
-       } LUID, *PLUID;*/
+            DWORD LowPart;
+            LONG HighPart;
+    } LUID, *PLUID;*/
     [StructLayout(LayoutKind.Sequential)]
     internal sealed class LUID
     {
@@ -269,9 +269,9 @@ namespace System.DirectoryServices.ActiveDirectory
     }
 
     /*typedef struct _NEGOTIATE_CALLER_NAME_REQUEST {
-               ULONG       MessageType ;
-               LUID        LogonId ;
-       } NEGOTIATE_CALLER_NAME_REQUEST, *PNEGOTIATE_CALLER_NAME_REQUEST ;*/
+            ULONG       MessageType ;
+            LUID        LogonId ;
+    } NEGOTIATE_CALLER_NAME_REQUEST, *PNEGOTIATE_CALLER_NAME_REQUEST ;*/
     [StructLayout(LayoutKind.Sequential)]
     internal sealed class NegotiateCallerNameRequest
     {
@@ -280,9 +280,9 @@ namespace System.DirectoryServices.ActiveDirectory
     }
 
     /*typedef struct _NEGOTIATE_CALLER_NAME_RESPONSE {
-               ULONG       MessageType ;
-               PWSTR       CallerName ;
-               } NEGOTIATE_CALLER_NAME_RESPONSE, * PNEGOTIATE_CALLER_NAME_RESPONSE ;*/
+            ULONG       MessageType ;
+            PWSTR       CallerName ;
+        } NEGOTIATE_CALLER_NAME_RESPONSE, * PNEGOTIATE_CALLER_NAME_RESPONSE ;*/
     [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
     internal sealed class NegotiateCallerNameResponse
     {
@@ -314,13 +314,13 @@ namespace System.DirectoryServices.ActiveDirectory
         internal const int STATUS_QUOTA_EXCEEDED = unchecked((int)0xC0000044);
 
         /*DWORD DsGetDcName(
-                               LPCTSTR ComputerName, 
-                               LPCTSTR DomainName, 
-                               GUID* DomainGuid, 
-                               LPCTSTR SiteName, 
-                               ULONG Flags, 
-                               PDOMAIN_CONTROLLER_INFO* DomainControllerInfo
-                               );*/
+                LPCTSTR ComputerName, 
+                LPCTSTR DomainName, 
+                GUID* DomainGuid, 
+                LPCTSTR SiteName, 
+                ULONG Flags, 
+                PDOMAIN_CONTROLLER_INFO* DomainControllerInfo
+                );*/
         [DllImport("Netapi32.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "DsGetDcNameW", CharSet = CharSet.Unicode)]
         internal static extern int DsGetDcName(
             [In] string computerName,
@@ -331,14 +331,14 @@ namespace System.DirectoryServices.ActiveDirectory
             [Out] out IntPtr domainControllerInfo);
 
         /* DWORD WINAPI DsGetDcOpen(
-                                                LPCTSTR DnsName,
-                                                ULONG OptionFlags,
-                                                LPCTSTR SiteName,
-                                                GUID* DomainGuid,
-                                                LPCTSTR DnsForestName,
-                                                ULONG DcFlags,
-                                                PHANDLE RetGetDcContext
-                                                );*/
+                         LPCTSTR DnsName,
+                         ULONG OptionFlags,
+                         LPCTSTR SiteName,
+                         GUID* DomainGuid,
+                         LPCTSTR DnsForestName,
+                         ULONG DcFlags,
+                         PHANDLE RetGetDcContext
+                         );*/
         [DllImport("Netapi32.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "DsGetDcOpenW", CharSet = CharSet.Unicode)]
         internal static extern int DsGetDcOpen(
             [In] string dnsName,
@@ -350,11 +350,11 @@ namespace System.DirectoryServices.ActiveDirectory
             [Out] out IntPtr retGetDcContext);
 
         /*DWORD WINAPI DsGetDcNext(
-                                               HANDLE GetDcContextHandle,
-                                               PULONG SockAddressCount,
-                                               LPSOCKET_ADDRESS* SockAddresses,
-                                               LPTSTR* DnsHostName
-                                               );*/
+                        HANDLE GetDcContextHandle,
+                        PULONG SockAddressCount,
+                        LPSOCKET_ADDRESS* SockAddresses,
+                        LPTSTR* DnsHostName
+                        );*/
         [DllImport("Netapi32.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "DsGetDcNextW", CharSet = CharSet.Unicode)]
         internal static extern int DsGetDcNext(
             [In] IntPtr getDcContextHandle,
@@ -363,25 +363,25 @@ namespace System.DirectoryServices.ActiveDirectory
             [Out] out IntPtr dnsHostName);
 
         /*void WINAPI DsGetDcClose(
-                                               HANDLE GetDcContextHandle
-                                               );*/
+                        HANDLE GetDcContextHandle
+                        );*/
         [DllImport("Netapi32.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "DsGetDcCloseW", CharSet = CharSet.Unicode)]
         internal static extern void DsGetDcClose(
             [In] IntPtr getDcContextHandle);
 
         /*NET_API_STATUS NetApiBufferFree(
-                               LPVOID Buffer  
-                               );*/
+                LPVOID Buffer  
+                );*/
         [DllImport("Netapi32.dll")]
         internal static extern int NetApiBufferFree(
             [In] IntPtr buffer);
 
         /*DWORD DsMakePasswordCredentials(
-                       LPTSTR User, 
-                       LPTSTR Domain, 
-                       LPTSTR Password, 
-                       RPC_AUTH_IDENTITY_HANDLE* pAuthIdentity
-                       );*/
+            LPTSTR User, 
+            LPTSTR Domain, 
+            LPTSTR Password, 
+            RPC_AUTH_IDENTITY_HANDLE* pAuthIdentity
+            );*/
 
         internal delegate int DsMakePasswordCredentials(
       [MarshalAs(UnmanagedType.LPWStr)] string user,
@@ -390,17 +390,17 @@ namespace System.DirectoryServices.ActiveDirectory
       [Out] out IntPtr authIdentity);
 
         /*VOID DsFreePasswordCredentials(
-                       RPC_AUTH_IDENTITY_HANDLE AuthIdentity
-                       );*/
+            RPC_AUTH_IDENTITY_HANDLE AuthIdentity
+            );*/
         internal delegate void DsFreePasswordCredentials(
             [In] IntPtr authIdentity);
 
         /*DWORD DsBindWithCred(
-                       TCHAR* DomainController, 
-                       TCHAR* DnsDomainName, 
-                       RPC_AUTH_IDENTITY_HANDLE AuthIdentity, 
-                       HANDLE* phDS
-                       );*/
+            TCHAR* DomainController, 
+            TCHAR* DnsDomainName, 
+            RPC_AUTH_IDENTITY_HANDLE AuthIdentity, 
+            HANDLE* phDS
+            );*/
         internal delegate int DsBindWithCred(
             [MarshalAs(UnmanagedType.LPWStr)] string domainController,
             [MarshalAs(UnmanagedType.LPWStr)] string dnsDomainName,
@@ -408,18 +408,18 @@ namespace System.DirectoryServices.ActiveDirectory
             [Out] out IntPtr handle);
 
         /*DWORD DsUnBind(
-                       HANDLE* phDS
-                       );*/
+            HANDLE* phDS
+            );*/
         internal delegate int DsUnBind(
             [In] ref IntPtr handle);
 
         /*DWORD DsGetDomainControllerInfo(
-                       HANDLE hDs,
-                       LPTSTR DomainName,
-                       DWORD InfoLevel,
-                       DWORD* pcOut,
-                       VOID** ppInfo
-                       );*/
+            HANDLE hDs,
+            LPTSTR DomainName,
+            DWORD InfoLevel,
+            DWORD* pcOut,
+            VOID** ppInfo
+            );*/
         internal delegate int DsGetDomainControllerInfo(
             [In] IntPtr handle,
             [MarshalAs(UnmanagedType.LPWStr)] string domainName,
@@ -431,10 +431,10 @@ namespace System.DirectoryServices.ActiveDirectory
         internal const int DsDomainControllerInfoLevel3 = 3;
 
         /*VOID DsFreeDomainControllerInfo(
-                       DWORD InfoLevel, 
-                       DWORD cInfo, 
-                       VOID* pInfo
-                       );*/
+            DWORD InfoLevel, 
+            DWORD cInfo, 
+            VOID* pInfo
+            );*/
         internal delegate void DsFreeDomainControllerInfo(
             [In] int infoLevel,
             [In] int dcInfoListCount,
@@ -443,17 +443,17 @@ namespace System.DirectoryServices.ActiveDirectory
         internal const int DsNameNoError = 0;
 
         /*DWORD DsListSites(
-                       HANDLE hDs,
-                       PDS_NAME_RESULT* ppSites
-                       );*/
+            HANDLE hDs,
+            PDS_NAME_RESULT* ppSites
+            );*/
         internal delegate int DsListSites(
             [In] IntPtr dsHandle,
             [Out] out IntPtr sites);
 
         /*DWORD DsListRoles(
-                       HANDLE hDs, 
-                       PDS_NAME_RESULTW* ppRoles
-                       );*/
+            HANDLE hDs, 
+            PDS_NAME_RESULTW* ppRoles
+            );*/
         internal delegate int DsListRoles(
             [In] IntPtr dsHandle,
             [Out] out IntPtr roles);
@@ -466,13 +466,13 @@ namespace System.DirectoryServices.ActiveDirectory
         internal const int DnsQueryBypassCache = 8;
 
         /*DNS_STATUS WINAPI DnsQuery (
-                       LPSTR lpstrName,
-                       WORD wType,
-                       DWORD fOptions,
-                       PIP4_ARRAY aipServers,
-                       PDNS_RECORD *ppQueryResultsSet,
-                       PVOID *pReserved 
-                       );*/
+            LPSTR lpstrName,
+            WORD wType,
+            DWORD fOptions,
+            PIP4_ARRAY aipServers,
+            PDNS_RECORD *ppQueryResultsSet,
+            PVOID *pReserved 
+            );*/
         [DllImport("Dnsapi.dll", EntryPoint = "DnsQuery_W", CharSet = CharSet.Unicode)]
         internal static extern int DnsQuery(
             [In] string recordName,
@@ -483,30 +483,30 @@ namespace System.DirectoryServices.ActiveDirectory
             [Out] IntPtr reserved);
 
         /*VOID WINAPI DnsRecordListFree(
-                       PDNS_RECORD pRecordList,
-                       DNS_FREE_TYPE FreeType
-                       );*/
+            PDNS_RECORD pRecordList,
+            DNS_FREE_TYPE FreeType
+            );*/
         [DllImport("Dnsapi.dll", CharSet = CharSet.Unicode)]
         internal static extern void DnsRecordListFree(
             [In] IntPtr dnsResultList,
             [In] bool dnsFreeType);
 
         /*BOOL GetVersionEx(
-                       LPOSVERSIONINFO lpVersionInfo
-                       );*/
+              LPOSVERSIONINFO lpVersionInfo
+            );*/
         [DllImport("Kernel32.dll", EntryPoint = "GetVersionExW", CharSet = CharSet.Unicode, SetLastError = true)]
         internal static extern bool GetVersionEx(
                 [In, Out] OSVersionInfoEx ver);
 
         /*DWORD DsCrackNames(
-                       HANDLE hDS, 
-                       DS_NAME_FLAGS flags, 
-                       DS_NAME_FORMAT formatOffered, 
-                       DS_NAME_FORMAT formatDesired, 
-                       DWORD cNames, 
-                       LPTSTR* rpNames, 
-                       PDS_NAME_RESULT* ppResult
-                       );*/
+            HANDLE hDS, 
+            DS_NAME_FLAGS flags, 
+            DS_NAME_FORMAT formatOffered, 
+            DS_NAME_FORMAT formatDesired, 
+            DWORD cNames, 
+            LPTSTR* rpNames, 
+            PDS_NAME_RESULT* ppResult
+            );*/
         internal delegate int DsCrackNames(
             [In] IntPtr hDS,
             [In] int flags,
@@ -517,8 +517,8 @@ namespace System.DirectoryServices.ActiveDirectory
             [Out] out IntPtr results);
 
         /*NTSTATUS LsaConnectUntrusted(
-                        PHANDLE LsaHandle
-                       );*/
+              PHANDLE LsaHandle
+            );*/
         [DllImport("Secur32.dll")]
         internal static extern int LsaConnectUntrusted(
              [Out] out LsaLogonProcessSafeHandle lsaHandle);
@@ -526,14 +526,14 @@ namespace System.DirectoryServices.ActiveDirectory
         internal const int NegGetCallerName = 1;
 
         /*NTSTATUS LsaCallAuthenticationPackage(
-                         HANDLE LsaHandle,
-                         ULONG AuthenticationPackage,
-                         PVOID ProtocolSubmitBuffer,
-                         ULONG SubmitBufferLength,
-                         PVOID* ProtocolReturnBuffer,
-                         PULONG ReturnBufferLength,
-                         PNTSTATUS ProtocolStatus
-                       );*/
+              HANDLE LsaHandle,
+              ULONG AuthenticationPackage,
+              PVOID ProtocolSubmitBuffer,
+              ULONG SubmitBufferLength,
+              PVOID* ProtocolReturnBuffer,
+              PULONG ReturnBufferLength,
+              PNTSTATUS ProtocolStatus
+            );*/
         [DllImport("Secur32.dll")]
         internal static extern int LsaCallAuthenticationPackage(
             [In] LsaLogonProcessSafeHandle lsaHandle,
@@ -545,26 +545,26 @@ namespace System.DirectoryServices.ActiveDirectory
             [Out] out int protocolStatus);
 
         /*NTSTATUS LsaFreeReturnBuffer(
-                       PVOID Buffer
-                       );*/
+              PVOID Buffer
+            );*/
         [DllImport("Secur32.dll")]
         internal static extern uint LsaFreeReturnBuffer(
             [In] IntPtr buffer);
 
         /*NTSTATUS LsaDeregisterLogonProcess(
-                       HANDLE LsaHandle
-                       );*/
+              HANDLE LsaHandle
+            );*/
         [DllImport("Secur32.dll")]
         internal static extern int LsaDeregisterLogonProcess(
             [In] IntPtr lsaHandle);
 
         /*int CompareString(LCID Locale,
-                       DWORD dwCmpFlags,
-                       DWORD lpString1,
-                       DWORD cchCount1,
-                       DWORD lpString2,
-                       DWORD cchCount2
-                       );*/
+            DWORD dwCmpFlags,
+            DWORD lpString1,
+            DWORD cchCount1,
+            DWORD lpString2,
+            DWORD cchCount2
+            );*/
         [DllImport("Kernel32.dll", EntryPoint = "CompareStringW", CharSet = CharSet.Unicode, SetLastError = true)]
         internal static extern int CompareString(
             [In] uint locale,
@@ -581,32 +581,32 @@ namespace System.DirectoryServices.ActiveDirectory
     internal sealed class NativeComInterfaces
     {
         /*typedef enum {
-                  ADS_SETTYPE_FULL=1,
-                  ADS_SETTYPE_PROVIDER=2,
-                  ADS_SETTYPE_SERVER=3,
-                  ADS_SETTYPE_DN=4
-               } ADS_SETTYPE_ENUM;
-
-               typedef enum {
-                  ADS_FORMAT_WINDOWS=1,
-                  ADS_FORMAT_WINDOWS_NO_SERVER=2,
-                  ADS_FORMAT_WINDOWS_DN=3,
-                  ADS_FORMAT_WINDOWS_PARENT=4,
-                  ADS_FORMAT_X500=5,
-                  ADS_FORMAT_X500_NO_SERVER=6,
-                  ADS_FORMAT_X500_DN=7,
-                  ADS_FORMAT_X500_PARENT=8,
-                  ADS_FORMAT_SERVER=9,
-                  ADS_FORMAT_PROVIDER=10,
-                  ADS_FORMAT_LEAF=11
-               } ADS_FORMAT_ENUM;
-
-               typedef enum {
-                  ADS_ESCAPEDMODE_DEFAULT=1,
-                  ADS_ESCAPEDMODE_ON=2,
-                  ADS_ESCAPEDMODE_OFF=3,
-                  ADS_ESCAPEDMODE_OFF_EX=4
-               } ADS_ESCAPE_MODE_ENUM;*/
+           ADS_SETTYPE_FULL=1,
+           ADS_SETTYPE_PROVIDER=2,
+           ADS_SETTYPE_SERVER=3,
+           ADS_SETTYPE_DN=4
+        } ADS_SETTYPE_ENUM;
+
+        typedef enum {
+           ADS_FORMAT_WINDOWS=1,
+           ADS_FORMAT_WINDOWS_NO_SERVER=2,
+           ADS_FORMAT_WINDOWS_DN=3,
+           ADS_FORMAT_WINDOWS_PARENT=4,
+           ADS_FORMAT_X500=5,
+           ADS_FORMAT_X500_NO_SERVER=6,
+           ADS_FORMAT_X500_DN=7,
+           ADS_FORMAT_X500_PARENT=8,
+           ADS_FORMAT_SERVER=9,
+           ADS_FORMAT_PROVIDER=10,
+           ADS_FORMAT_LEAF=11
+        } ADS_FORMAT_ENUM;
+
+        typedef enum {
+           ADS_ESCAPEDMODE_DEFAULT=1,
+           ADS_ESCAPEDMODE_ON=2,
+           ADS_ESCAPEDMODE_OFF=3,
+           ADS_ESCAPEDMODE_OFF_EX=4
+        } ADS_ESCAPE_MODE_ENUM;*/
 
         internal const int ADS_SETTYPE_DN = 4;
         internal const int ADS_FORMAT_X500_DN = 7;
index e823ba9..55c9779 100644 (file)
@@ -51,34 +51,34 @@ namespace System.DirectoryServices.ActiveDirectory
 
         /*
 
-               #define LANG_ENGLISH                     0x09
-               #define SUBLANG_ENGLISH_US               0x01    // English (USA)       
-               #define SORT_DEFAULT                     0x0     // sorting default     
-
-               #define NORM_IGNORECASE           0x00000001  // ignore case
-               #define NORM_IGNORENONSPACE       0x00000002  // ignore nonspacing chars
-               #define NORM_IGNORESYMBOLS        0x00000004  // ignore symbols
-               #define NORM_IGNOREKANATYPE       0x00010000  // ignore kanatype
-               #define NORM_IGNOREWIDTH          0x00020000  // ignore width   
-
-               #define SORT_STRINGSORT           0x00001000  // use string sort method
-               
-               #define MAKELANGID(p, s)       ((((WORD  )(s)) << 10) | (WORD  )(p))
-
-               #define MAKELCID(lgid, srtid)  ((DWORD)((((DWORD)((WORD  )(srtid))) << 16) |  \
-                                                ((DWORD)((WORD  )(lgid)))))
-
-               #define DS_DEFAULT_LOCALE                                           \
-                                                       (MAKELCID(MAKELANGID(LANG_ENGLISH, SUBLANG_ENGLISH_US),  \
-                                                       SORT_DEFAULT))
-
-               #define DS_DEFAULT_LOCALE_COMPARE_FLAGS    (NORM_IGNORECASE     |   \
-                                                                                                       NORM_IGNOREKANATYPE |   \
-                                                                                                       NORM_IGNORENONSPACE |   \
-                                                                                                       NORM_IGNOREWIDTH    |   \
-                                                                                                       SORT_STRINGSORT )
-
-               */
+        #define LANG_ENGLISH                     0x09
+        #define SUBLANG_ENGLISH_US               0x01    // English (USA)
+        #define SORT_DEFAULT                     0x0     // sorting default
+
+        #define NORM_IGNORECASE           0x00000001  // ignore case
+        #define NORM_IGNORENONSPACE       0x00000002  // ignore nonspacing chars
+        #define NORM_IGNORESYMBOLS        0x00000004  // ignore symbols
+        #define NORM_IGNOREKANATYPE       0x00010000  // ignore kanatype
+        #define NORM_IGNOREWIDTH          0x00020000  // ignore width
+
+        #define SORT_STRINGSORT           0x00001000  // use string sort method
+        
+        #define MAKELANGID(p, s)       ((((WORD  )(s)) << 10) | (WORD  )(p))
+
+        #define MAKELCID(lgid, srtid)  ((DWORD)((((DWORD)((WORD  )(srtid))) << 16) |  \
+                                             ((DWORD)((WORD  )(lgid)))))
+
+        #define DS_DEFAULT_LOCALE                                           \
+                            (MAKELCID(MAKELANGID(LANG_ENGLISH, SUBLANG_ENGLISH_US),  \
+                            SORT_DEFAULT))
+
+        #define DS_DEFAULT_LOCALE_COMPARE_FLAGS    (NORM_IGNORECASE     |   \
+                                                    NORM_IGNOREKANATYPE |   \
+                                                    NORM_IGNORENONSPACE |   \
+                                                    NORM_IGNOREWIDTH    |   \
+                                                    SORT_STRINGSORT )
+
+        */
         private static uint s_LANG_ENGLISH = 0x09;
         private static uint s_SUBLANG_ENGLISH_US = 0x01;
         private static uint s_SORT_DEFAULT = 0x0;
@@ -257,9 +257,9 @@ namespace System.DirectoryServices.ActiveDirectory
 
         //
         // DN is of the form cn=NTDS Settings, cn={dc name}, cn=Servers, cn={site name}, cn=Sites,
-        //                                                             cn=Configuration, {defaultNamingContext}
-        //     Bind to the NTDS-DSA (parent) object for and get the dnsHostName
-        //     from there
+        //                                cn=Configuration, {defaultNamingContext}
+        //    Bind to the NTDS-DSA (parent) object for and get the dnsHostName
+        //    from there
         //
         internal static string GetDnsHostNameFromNTDSA(DirectoryContext context, string dn)
         {
index 920877a..a0620f8 100644 (file)
@@ -10,7 +10,7 @@ namespace System.DirectoryServices
     public enum DereferenceAlias
     {
         Never = 0,
-       InSearching = 1,
+        InSearching = 1,
         FindingBaseObject = 2,
         Always = 3
     }
index a25af4d..3d32779 100644 (file)
@@ -28,7 +28,7 @@ namespace System.DirectoryServices
             }
         }
 
-       public DirectoryVirtualListViewContext Copy()
+        public DirectoryVirtualListViewContext Copy()
         {
             return new DirectoryVirtualListViewContext(_context);
         }
index fca3710..9a513ba 100644 (file)
@@ -9,8 +9,8 @@ namespace System.DirectoryServices
     /// </devdoc>
     public enum ExtendedDN
     {
-       None = -1,
-       HexString = 0,
-       Standard = 1
+        None = -1,
+        HexString = 0,
+        Standard = 1
     }
 }
index b174268..de846ea 100644 (file)
@@ -9,249 +9,249 @@ using System;
 namespace ActiveDirectoryComInterop
 {
     // , TypeLibType(TypeLibTypeFlags.FDual | TypeLibTypeFlags.FDispatchable)
-       [Guid("9068270B-0939-11D1-8BE1-00C04FD8D503")]
-       [ComImport]
-       public interface IADsLargeInteger
-       {
-               [DispId(2)]
-               int HighPart
-               {
-                       [DispId(2)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       get;
-                       [DispId(2)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       set;
-               }
+    [Guid("9068270B-0939-11D1-8BE1-00C04FD8D503")]
+    [ComImport]
+    public interface IADsLargeInteger
+    {
+        [DispId(2)]
+        int HighPart
+        {
+            [DispId(2)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            get;
+            [DispId(2)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            set;
+        }
 
-               [DispId(3)]
-               int LowPart
-               {
-                       [DispId(3)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       get;
-                       [DispId(3)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       set;
-               }
-       }
+        [DispId(3)]
+        int LowPart
+        {
+            [DispId(3)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            get;
+            [DispId(3)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            set;
+        }
+    }
 
     // , TypeLibType(TypeLibTypeFlags.FDual | TypeLibTypeFlags.FDispatchable)
-       [Guid("FD8256D0-FD15-11CE-ABC4-02608C9E7553")]
-       [ComImport]
-       public interface IADs
-       {
-               [DispId(2)]
-               string Name
-               {
-                       [DispId(2)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       [return: MarshalAs(UnmanagedType.BStr)]
-                       get;
-               }
+    [Guid("FD8256D0-FD15-11CE-ABC4-02608C9E7553")]
+    [ComImport]
+    public interface IADs
+    {
+        [DispId(2)]
+        string Name
+        {
+            [DispId(2)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            [return: MarshalAs(UnmanagedType.BStr)]
+            get;
+        }
 
-               [DispId(3)]
-               string Class
-               {
-                       [DispId(3)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       [return: MarshalAs(UnmanagedType.BStr)]
-                       get;
-               }
+        [DispId(3)]
+        string Class
+        {
+            [DispId(3)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            [return: MarshalAs(UnmanagedType.BStr)]
+            get;
+        }
 
-               [DispId(4)]
-               string GUID
-               {
-                       [DispId(4)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       [return: MarshalAs(UnmanagedType.BStr)]
-                       get;
-               }
+        [DispId(4)]
+        string GUID
+        {
+            [DispId(4)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            [return: MarshalAs(UnmanagedType.BStr)]
+            get;
+        }
 
-               [DispId(5)]
-               string ADsPath
-               {
-                       [DispId(5)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       [return: MarshalAs(UnmanagedType.BStr)]
-                       get;
-               }
+        [DispId(5)]
+        string ADsPath
+        {
+            [DispId(5)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            [return: MarshalAs(UnmanagedType.BStr)]
+            get;
+        }
 
-               [DispId(6)]
-               string Parent
-               {
-                       [DispId(6)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       [return: MarshalAs(UnmanagedType.BStr)]
-                       get;
-               }
+        [DispId(6)]
+        string Parent
+        {
+            [DispId(6)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            [return: MarshalAs(UnmanagedType.BStr)]
+            get;
+        }
 
-               [DispId(7)]
-               string Schema
-               {
-                       [DispId(7)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       [return: MarshalAs(UnmanagedType.BStr)]
-                       get;
-               }
+        [DispId(7)]
+        string Schema
+        {
+            [DispId(7)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            [return: MarshalAs(UnmanagedType.BStr)]
+            get;
+        }
 
-               [DispId(8)]
-               [MethodImpl(MethodImplOptions.InternalCall)]
-               void GetInfo();
+        [DispId(8)]
+        [MethodImpl(MethodImplOptions.InternalCall)]
+        void GetInfo();
 
-               [DispId(9)]
-               [MethodImpl(MethodImplOptions.InternalCall)]
-               void SetInfo();
+        [DispId(9)]
+        [MethodImpl(MethodImplOptions.InternalCall)]
+        void SetInfo();
 
-               [DispId(10)]
-               [MethodImpl(MethodImplOptions.InternalCall)]
-               [return: MarshalAs(UnmanagedType.Struct)]
-               object Get([MarshalAs(UnmanagedType.BStr)] [In] string bstrName);
+        [DispId(10)]
+        [MethodImpl(MethodImplOptions.InternalCall)]
+        [return: MarshalAs(UnmanagedType.Struct)]
+        object Get([MarshalAs(UnmanagedType.BStr)] [In] string bstrName);
 
-               [DispId(11)]
-               [MethodImpl(MethodImplOptions.InternalCall)]
-               void Put([MarshalAs(UnmanagedType.BStr)] [In] string bstrName, [MarshalAs(UnmanagedType.Struct)] [In] object vProp);
+        [DispId(11)]
+        [MethodImpl(MethodImplOptions.InternalCall)]
+        void Put([MarshalAs(UnmanagedType.BStr)] [In] string bstrName, [MarshalAs(UnmanagedType.Struct)] [In] object vProp);
 
-               [DispId(12)]
-               [MethodImpl(MethodImplOptions.InternalCall)]
-               [return: MarshalAs(UnmanagedType.Struct)]
-               object GetEx([MarshalAs(UnmanagedType.BStr)] [In] string bstrName);
+        [DispId(12)]
+        [MethodImpl(MethodImplOptions.InternalCall)]
+        [return: MarshalAs(UnmanagedType.Struct)]
+        object GetEx([MarshalAs(UnmanagedType.BStr)] [In] string bstrName);
 
-               [DispId(13)]
-               [MethodImpl(MethodImplOptions.InternalCall)]
-               void PutEx([In] int lnControlCode, [MarshalAs(UnmanagedType.BStr)] [In] string bstrName, [MarshalAs(UnmanagedType.Struct)] [In] object vProp);
+        [DispId(13)]
+        [MethodImpl(MethodImplOptions.InternalCall)]
+        void PutEx([In] int lnControlCode, [MarshalAs(UnmanagedType.BStr)] [In] string bstrName, [MarshalAs(UnmanagedType.Struct)] [In] object vProp);
 
-               [DispId(14)]
-               [MethodImpl(MethodImplOptions.InternalCall)]
-               void GetInfoEx([MarshalAs(UnmanagedType.Struct)] [In] object vProperties, [In] int lnReserved);
-       }
+        [DispId(14)]
+        [MethodImpl(MethodImplOptions.InternalCall)]
+        void GetInfoEx([MarshalAs(UnmanagedType.Struct)] [In] object vProperties, [In] int lnReserved);
+    }
 
     // , TypeLibType(TypeLibTypeFlags.FDual | TypeLibTypeFlags.FDispatchable)
-       [Guid("B8C787CA-9BDD-11D0-852C-00C04FD8D503")]
-       [ComImport]
-       public interface IADsSecurityDescriptor
-       {
-               [DispId(2)]
-               int Revision
-               {
-                       [DispId(2)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       get;
-                       [DispId(2)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       set;
-               }
+    [Guid("B8C787CA-9BDD-11D0-852C-00C04FD8D503")]
+    [ComImport]
+    public interface IADsSecurityDescriptor
+    {
+        [DispId(2)]
+        int Revision
+        {
+            [DispId(2)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            get;
+            [DispId(2)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            set;
+        }
 
-               [DispId(3)]
-               int Control
-               {
-                       [DispId(3)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       get;
-                       [DispId(3)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       set;
-               }
+        [DispId(3)]
+        int Control
+        {
+            [DispId(3)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            get;
+            [DispId(3)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            set;
+        }
 
-               [DispId(4)]
-               string Owner
-               {
-                       [DispId(4)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       [return: MarshalAs(UnmanagedType.BStr)]
-                       get;
-                       [DispId(4)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       [param: MarshalAs(UnmanagedType.BStr)]
-                       set;
-               }
+        [DispId(4)]
+        string Owner
+        {
+            [DispId(4)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            [return: MarshalAs(UnmanagedType.BStr)]
+            get;
+            [DispId(4)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            [param: MarshalAs(UnmanagedType.BStr)]
+            set;
+        }
 
-               [DispId(5)]
-               bool OwnerDefaulted
-               {
-                       [DispId(5)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       get;
-                       [DispId(5)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       set;
-               }
+        [DispId(5)]
+        bool OwnerDefaulted
+        {
+            [DispId(5)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            get;
+            [DispId(5)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            set;
+        }
 
-               [DispId(6)]
-               string Group
-               {
-                       [DispId(6)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       [return: MarshalAs(UnmanagedType.BStr)]
-                       get;
-                       [DispId(6)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       [param: MarshalAs(UnmanagedType.BStr)]
-                       set;
-               }
+        [DispId(6)]
+        string Group
+        {
+            [DispId(6)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            [return: MarshalAs(UnmanagedType.BStr)]
+            get;
+            [DispId(6)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            [param: MarshalAs(UnmanagedType.BStr)]
+            set;
+        }
 
-               [DispId(7)]
-               bool GroupDefaulted
-               {
-                       [DispId(7)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       get;
-                       [DispId(7)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       set;
-               }
+        [DispId(7)]
+        bool GroupDefaulted
+        {
+            [DispId(7)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            get;
+            [DispId(7)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            set;
+        }
 
-               [DispId(8)]
-               object DiscretionaryAcl
-               {
-                       [DispId(8)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       [return: MarshalAs(UnmanagedType.IDispatch)]
-                       get;
-                       [DispId(8)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       [param: MarshalAs(UnmanagedType.IDispatch)]
-                       set;
-               }
+        [DispId(8)]
+        object DiscretionaryAcl
+        {
+            [DispId(8)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            [return: MarshalAs(UnmanagedType.IDispatch)]
+            get;
+            [DispId(8)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            [param: MarshalAs(UnmanagedType.IDispatch)]
+            set;
+        }
 
-               [DispId(9)]
-               bool DaclDefaulted
-               {
-                       [DispId(9)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       get;
-                       [DispId(9)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       set;
-               }
+        [DispId(9)]
+        bool DaclDefaulted
+        {
+            [DispId(9)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            get;
+            [DispId(9)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            set;
+        }
 
-               [DispId(10)]
-               object SystemAcl
-               {
-                       [DispId(10)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       [return: MarshalAs(UnmanagedType.IDispatch)]
-                       get;
-                       [DispId(10)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       [param: MarshalAs(UnmanagedType.IDispatch)]
-                       set;
-               }
+        [DispId(10)]
+        object SystemAcl
+        {
+            [DispId(10)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            [return: MarshalAs(UnmanagedType.IDispatch)]
+            get;
+            [DispId(10)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            [param: MarshalAs(UnmanagedType.IDispatch)]
+            set;
+        }
 
-               [DispId(11)]
-               bool SaclDefaulted
-               {
-                       [DispId(11)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       get;
-                       [DispId(11)]
-                       [MethodImpl(MethodImplOptions.InternalCall)]
-                       set;
-               }
+        [DispId(11)]
+        bool SaclDefaulted
+        {
+            [DispId(11)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            get;
+            [DispId(11)]
+            [MethodImpl(MethodImplOptions.InternalCall)]
+            set;
+        }
 
-               [DispId(12)]
-               [MethodImpl(MethodImplOptions.InternalCall)]
-               [return: MarshalAs(UnmanagedType.IDispatch)]
-               object CopySecurityDescriptor();
-       }
+        [DispId(12)]
+        [MethodImpl(MethodImplOptions.InternalCall)]
+        [return: MarshalAs(UnmanagedType.IDispatch)]
+        object CopySecurityDescriptor();
+    }
 }
index bb63f56..0be3587 100644 (file)
@@ -101,14 +101,14 @@ namespace System.DirectoryServices.Tests
                                 Assert.Equal(originalPhone, (string) sameUserEntry.Properties["telephoneNumber"].Value);
                             }
 
-                                       userEntry.CommitChanges();
+                            userEntry.CommitChanges();
 
                             using (DirectoryEntry sameUserEntry = GetOrganizationalRole(rootOU, "caching.user.1"))
                             {
                                 Assert.Equal(newPhone, (string) sameUserEntry.Properties["telephoneNumber"].Value);
                             }
 
-                                       userEntry.UsePropertyCache = false;
+                            userEntry.UsePropertyCache = false;
                             Assert.False(userEntry.UsePropertyCache);
 
                             userEntry.Properties["telephoneNumber"].Value = originalPhone;
index 42a1a32..9ecf2b6 100644 (file)
@@ -286,7 +286,7 @@ namespace System.Drawing
         /// <param name="lf">A boxed LOGFONT.</param>
         /// <param name="hdc">Handle to a device context (HDC).</param>
         /// <returns>The newly created <see cref="Font"/>.</returns>
-        public unsafe static Font FromLogFont(object lf, IntPtr hdc)
+        public static unsafe Font FromLogFont(object lf, IntPtr hdc)
         {
             if (lf == null)
             {
index 33ebd18..a236f38 100644 (file)
@@ -917,7 +917,7 @@ namespace System.Drawing
         public static extern IntPtr SelectObject(HandleRef hdc, HandleRef obj);
 
         [DllImport(ExternDll.User32, ExactSpelling = true, SetLastError = true)]
-        public unsafe static extern IntPtr CreateIconFromResourceEx(
+        public static extern unsafe IntPtr CreateIconFromResourceEx(
             byte* pbIconBits,
             uint cbIconBits,
             bool fIcon,
@@ -927,7 +927,7 @@ namespace System.Drawing
             int flags);
 
         [DllImport(ExternDll.Shell32, CharSet = CharSet.Unicode)]
-        public unsafe static extern IntPtr ExtractAssociatedIcon(HandleRef hInst, char* iconPath, ref int index);
+        public static extern unsafe IntPtr ExtractAssociatedIcon(HandleRef hInst, char* iconPath, ref int index);
 
         [DllImport(ExternDll.User32, SetLastError = true, CharSet = CharSet.Unicode)]
         public static extern IntPtr LoadIcon(HandleRef hInst, IntPtr iconId);
@@ -945,7 +945,7 @@ namespace System.Drawing
         [DllImport(ExternDll.Gdi32, SetLastError = true, CharSet = CharSet.Unicode)]
         public static extern int GetObject(HandleRef hObject, int nSize, ref LOGFONT lf);
 
-        public unsafe static int GetObject(HandleRef hObject, ref LOGFONT lp)
+        public static unsafe int GetObject(HandleRef hObject, ref LOGFONT lp)
             => GetObject(hObject, sizeof(LOGFONT), ref lp);
 
         [DllImport(ExternDll.User32, SetLastError = true, ExactSpelling = true)]
index a6f8afd..5c1ad98 100644 (file)
@@ -11,7 +11,7 @@ using System.Runtime.InteropServices;
 
 namespace System.Drawing
 {
-    internal unsafe static partial class SafeNativeMethods
+    internal static unsafe partial class SafeNativeMethods
     {
         internal static partial class Gdip
         {
index 82e1fc5..70fda1f 100644 (file)
@@ -160,7 +160,7 @@ namespace System.Drawing
 
         public static Icon ExtractAssociatedIcon(string filePath) => ExtractAssociatedIcon(filePath, 0);
 
-        private unsafe static Icon ExtractAssociatedIcon(string filePath, int index)
+        private static unsafe Icon ExtractAssociatedIcon(string filePath, int index)
         {
             if (filePath == null)
             {
index 9b6fe05..8b82086 100644 (file)
@@ -371,7 +371,7 @@ namespace System.Drawing
             }
         }
 
-        internal unsafe static void EnsureSave(Image image, string filename, Stream dataStream)
+        internal static unsafe void EnsureSave(Image image, string filename, Stream dataStream)
         {
             if (image.RawFormat.Equals(ImageFormat.Gif))
             {
index 7e990e9..cae6354 100644 (file)
@@ -10,7 +10,7 @@ namespace System.Drawing
 {
     public static partial class SystemFonts
     {
-        private unsafe static bool GetNonClientMetrics(out NativeMethods.NONCLIENTMETRICS metrics)
+        private static unsafe bool GetNonClientMetrics(out NativeMethods.NONCLIENTMETRICS metrics)
         {
             metrics = new NativeMethods.NONCLIENTMETRICS { cbSize = (uint)sizeof(NativeMethods.NONCLIENTMETRICS) };
             fixed (void* m = &metrics)
index 0d3e197..388cd87 100644 (file)
@@ -33,7 +33,7 @@ namespace System.Drawing
         public static extern int GetSystemMetrics(int nIndex);
 
         [DllImport(ExternDll.User32, SetLastError = true, CharSet = CharSet.Unicode)]
-        public static unsafe extern bool SystemParametersInfo(uint uiAction, uint uiParam, void* pvParam, uint fWinIni);
+        public static extern unsafe bool SystemParametersInfo(uint uiAction, uint uiParam, void* pvParam, uint fWinIni);
 
         [DllImport(ExternDll.Gdi32, SetLastError = true, ExactSpelling = true, CharSet = CharSet.Auto)]
         public static extern int GetDeviceCaps(HandleRef hDC, int nIndex);
index 70aa28c..4f7c9a7 100644 (file)
@@ -2,8 +2,8 @@
 // See the LICENSE file in the project root for more information.
 //
 // Authors:
-//     Jordi Mas i Hernàndez (jordi@ximian.com)
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Jordi Mas i Hernàndez (jordi@ximian.com)
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // (C) 2004 Ximian, Inc.  http://www.ximian.com
 // Copyright (C) 2004-2007 Novell, Inc (http://www.novell.com)
index bda3eea..47a5d1b 100644 (file)
@@ -2,7 +2,7 @@
 // See the LICENSE file in the project root for more information.
 //
 // Authors:
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // Copyright (C) 2007 Novell, Inc (http://www.novell.com)
 //
index 6252d28..ff172fb 100644 (file)
@@ -24,7 +24,7 @@
 //
 // Author:
 //
-//     Jordi Mas i Hernandez, jordimash@gmail.com
+//  Jordi Mas i Hernandez, jordimash@gmail.com
 //
 
 using Xunit;
index f8f8d4d..b0f0f43 100644 (file)
@@ -23,7 +23,7 @@
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 // Author:
-//     Andy Hume <andyhume32@yahoo.co.uk>
+//  Andy Hume <andyhume32@yahoo.co.uk>
 //
 
 using Xunit;
index f7a8f0c..ef4290e 100644 (file)
@@ -23,7 +23,7 @@
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 // Author:
-//     Andy Hume <andyhume32@yahoo.co.uk>
+//  Andy Hume <andyhume32@yahoo.co.uk>
 //
 
 using Xunit;
index 43d222a..aee42b7 100644 (file)
@@ -2,7 +2,7 @@
 // See the LICENSE file in the project root for more information.
 //
 // Authors:
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // Copyright (C) 2007 Novell, Inc (http://www.novell.com)
 //
index b411ee4..75f4d6d 100644 (file)
@@ -4,8 +4,8 @@
 // BMPCodec class testing unit
 //
 // Authors:
-//     Jordi Mas i Hernàndez (jordi@ximian.com)
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Jordi Mas i Hernàndez (jordi@ximian.com)
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // (C) 2004 Ximian, Inc.  http://www.ximian.com
 // Copyright (C) 2004-2007 Novell, Inc (http://www.novell.com)
@@ -447,7 +447,7 @@ namespace MonoTests.System.Drawing.Imaging
         {
             string sOutFile = $"linerect-{expected}.bmp";
 
-            // Save            
+            // Save
             Bitmap bmp = new Bitmap(100, 100, original);
             Graphics gr = Graphics.FromImage(bmp);
 
index 35b7638..e823c60 100644 (file)
@@ -4,8 +4,8 @@
 // GIF Codec class testing unit
 //
 // Authors:
-//     Jordi Mas i Hernàndez (jordi@ximian.com)
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Jordi Mas i Hernàndez (jordi@ximian.com)
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // Copyright (C) 2006, 2007 Novell, Inc (http://www.novell.com)
 //
@@ -190,7 +190,7 @@ namespace MonoTests.System.Drawing.Imaging
         {
             string sOutFile = $"linerect-{expected}.gif";
 
-            // Save            
+            // Save
             Bitmap bmp = new Bitmap(100, 100, original);
             Graphics gr = Graphics.FromImage(bmp);
 
index 9f910cc..b35a73d 100644 (file)
@@ -4,8 +4,8 @@
 // ICO Codec class testing unit
 //
 // Authors:
-//     Jordi Mas i Hernàndez (jordi@ximian.com)
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Jordi Mas i Hernàndez (jordi@ximian.com)
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // Copyright (C) 2006-2007 Novell, Inc (http://www.novell.com)
 //
@@ -2034,7 +2034,7 @@ namespace MonoTests.System.Drawing.Imaging
         {
             string sOutFile = $"linerect-{expected}.ico";
 
-            // Save            
+            // Save
             Bitmap bmp = new Bitmap(100, 100, original);
             Graphics gr = Graphics.FromImage(bmp);
 
index 61f64f6..83e9f3e 100644 (file)
@@ -4,8 +4,8 @@
 // JpegCodec class testing unit
 //
 // Authors:
-//     Jordi Mas i Hernàndez (jordi@ximian.com)
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Jordi Mas i Hernàndez (jordi@ximian.com)
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // (C) 2004 Ximian, Inc.  http://www.ximian.com
 // Copyright (C) 2004-2007 Novell, Inc (http://www.novell.com)
@@ -360,7 +360,7 @@ namespace MonoTests.System.Drawing.Imaging
         {
             string sOutFile = $"linerect-{expected}.jpeg";
 
-            // Save            
+            // Save
             Bitmap bmp = new Bitmap(100, 100, original);
             Graphics gr = Graphics.FromImage(bmp);
 
@@ -374,7 +374,7 @@ namespace MonoTests.System.Drawing.Imaging
             {
                 bmp.Save(sOutFile, ImageFormat.Jpeg);
 
-                // Load                        
+                // Load
                 using (Bitmap bmpLoad = new Bitmap(sOutFile))
                 {
                     Assert.Equal(expected, bmpLoad.PixelFormat);
index cba232a..24818cf 100644 (file)
@@ -4,8 +4,8 @@
 // PNG Codec class testing unit
 //
 // Authors:
-//     Jordi Mas i Hernàndez (jordi@ximian.com)
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Jordi Mas i Hernàndez (jordi@ximian.com)
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // Copyright (C) 2006, 2007 Novell, Inc (http://www.novell.com)
 //
@@ -621,7 +621,7 @@ namespace MonoTests.System.Drawing.Imaging
         {
             string sOutFile = $"linerect-{expected}.png";
 
-            // Save            
+            // Save
             Bitmap bmp = new Bitmap(100, 100, original);
             Graphics gr = Graphics.FromImage(bmp);
 
index fe3752d..bc40c6a 100644 (file)
@@ -4,8 +4,8 @@
 // TIFF Codec class testing unit
 //
 // Authors:
-//     Jordi Mas i Hernàndez (jordi@ximian.com)
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Jordi Mas i Hernàndez (jordi@ximian.com)
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // Copyright (C) 2006, 2007 Novell, Inc (http://www.novell.com)
 //
@@ -49,7 +49,7 @@ namespace MonoTests.System.Drawing.Imaging
                 GraphicsUnit unit = GraphicsUnit.World;
                 RectangleF rect = bmp.GetBounds(ref unit);
                 // MS reports 24 bpp while we report 32 bpp
-                //                             Assert.Equal (PixelFormat.Format24bppRgb, bmp.PixelFormat);
+                //                Assert.Equal (PixelFormat.Format24bppRgb, bmp.PixelFormat);
                 Assert.Equal(173, bmp.Width);
                 Assert.Equal(183, bmp.Height);
 
@@ -249,7 +249,7 @@ namespace MonoTests.System.Drawing.Imaging
         {
             string sOutFile = $"linerect-{expected}.tif";
 
-            // Save            
+            // Save
             Bitmap bmp = new Bitmap(100, 100, original);
             Graphics gr = Graphics.FromImage(bmp);
 
index 701fb50..d304a64 100644 (file)
@@ -4,9 +4,9 @@
 // Bitmap class testing unit
 //
 // Authors:
-//     Jordi Mas i Hernàndez (jmas@softcatala.org>
-//     Jonathan Gilbert <logic@deltaq.org>
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Jordi Mas i Hernàndez (jmas@softcatala.org>
+//  Jonathan Gilbert <logic@deltaq.org>
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // (C) 2004 Ximian, Inc.  http://www.ximian.com
 // Copyright (C) 2004,2006-2007 Novell, Inc (http://www.novell.com)
@@ -52,7 +52,7 @@ namespace MonoTests.System.Drawing
         [ConditionalFact(Helpers.IsDrawingSupported)]
         public void TestPixels()
         {
-            // Tests GetSetPixel/SetPixel                      
+            // Tests GetSetPixel/SetPixel
             Bitmap bmp = new Bitmap(100, 100, PixelFormat.Format32bppRgb);
             bmp.SetPixel(0, 0, Color.FromArgb(255, 128, 128, 128));
             Color color = bmp.GetPixel(0, 0);
index 0240355..9418718 100644 (file)
@@ -139,7 +139,7 @@ namespace MonoTests.System.Drawing
                 g.SmoothingMode = SmoothingMode.AntiAlias;
                 g.TextRenderingHint = TextRenderingHint.SystemDefault;
 
-                //Clipping set/get tested in clipping functions                        
+                //Clipping set/get tested in clipping functions
                 Assert.Equal(CompositingMode.SourceCopy, g.CompositingMode);
                 Assert.Equal(CompositingQuality.GammaCorrected, g.CompositingQuality);
                 Assert.Equal(InterpolationMode.HighQualityBilinear, g.InterpolationMode);
index c237279..cae4370 100644 (file)
@@ -4,7 +4,7 @@
 // Metafile class unit tests
 //
 // Authors:
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // Copyright (C) 2007 Novell, Inc (http://www.novell.com)
 //
index 69a4ada..799c813 100644 (file)
@@ -167,7 +167,7 @@ namespace System.Drawing
         /// <summary>
         ///    <para>
         ///       Specifies whether this <see cref='System.Drawing.Point'/> contains
-        ///       the same coordinates as the specified <see cref='System.Object'/>.
+        ///       the same coordinates as the specified <see cref='object'/>.
         ///    </para>
         /// </summary>
         public override bool Equals(object obj) => obj is Point && Equals((Point)obj);
index ce2ab70..98949ea 100644 (file)
@@ -12,7 +12,7 @@ namespace System.Globalization.Tests
     /// According to the ToASCII algorithm, if the UseSTD3ASCIIRules flag is set,
     /// then perform these checks:
     ///
-    ///        (a) Verify the absence of non-LDH ASCII code points; that is, the absence
+    ///    (a) Verify the absence of non-LDH ASCII code points; that is, the absence
     ///      of 0..2C, 2E..2F, 3A..40, 5B..60, and 7B..7F.
     ///
     /// (b) Verify the absence of leading and trailing hyphen-minus; that is, the
index 18b32be..1271749 100644 (file)
@@ -42,7 +42,7 @@ namespace System.Globalization.Tests
 
             if (PlatformDetection.IsWindows && PlatformDetection.WindowsVersion < 10)
             {
-               Assert.Throws<CultureNotFoundException>(() => new CultureInfo("no-such-culture"));
+                Assert.Throws<CultureNotFoundException>(() => new CultureInfo("no-such-culture"));
                 Assert.Throws<CultureNotFoundException>(() => new CultureInfo("en-US-CUSTOM"));
                 Assert.Throws<CultureNotFoundException>(() => new CultureInfo("xx-XX"));
             }
index 0d94422..381e2dc 100644 (file)
@@ -26,11 +26,11 @@ namespace System.Globalization.Tests
             DateTimeFormatInfo readOnlyFormat = DateTimeFormatInfo.ReadOnly(format);
             if (originalFormatIsReadOnly) 
             {
-               Assert.Same(format, readOnlyFormat);
+                Assert.Same(format, readOnlyFormat);
             }
             else 
             {
-               Assert.NotSame(format, readOnlyFormat);
+                Assert.NotSame(format, readOnlyFormat);
             }
             Assert.True(readOnlyFormat.IsReadOnly);
         }
index f10d357..6b8d4d6 100644 (file)
@@ -71,10 +71,10 @@ class StripHeaderAndFooter
         while ((value = inputStream.ReadByte()) != -1)
         {
             bitlist.Add((byte)value);
-            //                         outputStream.WriteByte((Byte)value);
+            //                outputStream.WriteByte((Byte)value);
         }
 
-        //                     outputStream.Close();
+        //            outputStream.Close();
         inputStream.Dispose();
 
         //Footer
@@ -83,10 +83,10 @@ class StripHeaderAndFooter
         //We can confirm this by comparing the size of the decompressed file with the size specified in the footer
         //To do this, we need to decompress the file
         //@TODO!! - is it worth it??
-        //                     outputStream = new MemoryStream(outputFileName, FileMode.Create, FileAccess.Write);
-        //                     inputStream = new MemoryStream(inputFileName, FileMode.Open, FileAccess.Read, FileShare.Read);
+        //            outputStream = new MemoryStream(outputFileName, FileMode.Create, FileAccess.Write);
+        //            inputStream = new MemoryStream(inputFileName, FileMode.Open, FileAccess.Read, FileShare.Read);
 
-        //                     outputStream.Flush();
+        //            outputStream.Flush();
         byte[] bits = new byte[bitlist.Count - 8];
         bitlist.CopyTo(0, bits, 0, bitlist.Count - 8);
         outputStream.Write(bits, 0, bits.Length);
index d0be36b..6dd6385 100644 (file)
@@ -9,6 +9,7 @@ using System.Runtime.InteropServices;
 using System.Threading;
 using System.Text;
 
+#pragma warning disable SA1121 // we don't want to simplify built-ins here as we're using aliasing
 using CFStringRef = System.IntPtr;
 using FSEventStreamRef = System.IntPtr;
 using size_t = System.IntPtr;
index 4bde60c..06e68ff 100644 (file)
@@ -328,19 +328,19 @@ namespace System.IO.Tests
 
                     File.Move(filePath, filePathRenamed);
                     Assert.True(WaitHandle.WaitAll(
-                       new[] { autoResetEvent1_created, autoResetEvent1_deleted, autoResetEvent2_created, autoResetEvent2_deleted },
-                       WaitForExpectedEventTimeout_NoRetry));
+                        new[] { autoResetEvent1_created, autoResetEvent1_deleted, autoResetEvent2_created, autoResetEvent2_deleted },
+                        WaitForExpectedEventTimeout_NoRetry));
 
                     File.Move(filePathRenamed, filePath);
                     watcher1.EnableRaisingEvents = false;
 
                     File.Move(filePath, filePathRenamed);
                     Assert.False(WaitHandle.WaitAll(
-                       new[] { autoResetEvent1_created, autoResetEvent1_deleted },
-                       WaitForUnexpectedEventTimeout));
+                        new[] { autoResetEvent1_created, autoResetEvent1_deleted },
+                        WaitForUnexpectedEventTimeout));
                     Assert.True(WaitHandle.WaitAll(
-                       new[] { autoResetEvent2_created, autoResetEvent2_deleted },
-                       WaitForExpectedEventTimeout_NoRetry));
+                        new[] { autoResetEvent2_created, autoResetEvent2_deleted },
+                        WaitForExpectedEventTimeout_NoRetry));
                 }
             });
         }
index 5c1fba0..c690d1f 100644 (file)
@@ -18,7 +18,7 @@ namespace System.IO.Enumeration
         // is the directory separator and cannot be part of any path segment in Windows). The other three are the
         // special case wildcards that we'll convert some * and ? into. They're also valid as filenames on Unix,
         // which is not true in Windows and as such we'll escape any that occur on the input string.
-        private readonly static char[] s_unixEscapeChars = { '\\', '"', '<', '>' };
+        private static readonly char[] s_unixEscapeChars = { '\\', '"', '<', '>' };
 
         /// <summary>
         /// Validates the directory and expression strings to check that they have no invalid characters, any special DOS wildcard characters in Win32 in the expression get replaced with their proper escaped representation, and if the expression string begins with a directory name, the directory name is moved and appended at the end of the directory string.
index 35b2f0f..b2ffb7b 100644 (file)
@@ -7,7 +7,7 @@ This testcase attempts to delete some directories in a mounted volume
  - Different drive is mounted on the current drive
  - Current drive is mounted on a different drive
  - Current drive is mounted on current directory
-        - refer to the directory in a recursive manner in addition to the normal one
+   - refer to the directory in a recursive manner in addition to the normal one
 **/
 using System;
 using System.IO;
index 87007cd..0e883be 100644 (file)
@@ -100,38 +100,38 @@ namespace System.IO.Tests
             }
         }
 
-       [Fact]
-       public void VariableLengthFileNames_AllCreatableFilesAreEnumerable()
-       {
-           DirectoryInfo testDirectory = Directory.CreateDirectory(GetTestFilePath());
-           var names = new List<string>();
-
-           for (int length = 1; length < 10_000; length++) // arbitrarily large limit for the test
-           {
-               string name = new string('a', length);
-               try { File.Create(Path.Join(testDirectory.FullName, name)).Dispose(); }
-               catch { break; }
-               names.Add(name);
-           }
-           Assert.InRange(names.Count, 1, int.MaxValue);
-           Assert.Equal(names.OrderBy(n => n), Directory.GetFiles(testDirectory.FullName).Select(n => Path.GetFileName(n)).OrderBy(n => n));
-       }
-
-       [Fact]
-       public void VariableLengthDirectoryNames_AllCreatableDirectoriesAreEnumerable()
-       {
-           DirectoryInfo testDirectory = Directory.CreateDirectory(GetTestFilePath());
-           var names = new List<string>();
-
-           for (int length = 1; length < 10_000; length++) // arbitrarily large limit for the test
-           {
-               string name = new string('a', length);
-               try { Directory.CreateDirectory(Path.Join(testDirectory.FullName, name)); }
-               catch { break; }
-               names.Add(name);
-           }
-           Assert.InRange(names.Count, 1, int.MaxValue);
-           Assert.Equal(names.OrderBy(n => n), Directory.GetDirectories(testDirectory.FullName).Select(n => Path.GetFileName(n)).OrderBy(n => n));
-       }
+    [Fact]
+    public void VariableLengthFileNames_AllCreatableFilesAreEnumerable()
+    {
+        DirectoryInfo testDirectory = Directory.CreateDirectory(GetTestFilePath());
+        var names = new List<string>();
+
+        for (int length = 1; length < 10_000; length++) // arbitrarily large limit for the test
+        {
+            string name = new string('a', length);
+            try { File.Create(Path.Join(testDirectory.FullName, name)).Dispose(); }
+            catch { break; }
+            names.Add(name);
+        }
+        Assert.InRange(names.Count, 1, int.MaxValue);
+        Assert.Equal(names.OrderBy(n => n), Directory.GetFiles(testDirectory.FullName).Select(n => Path.GetFileName(n)).OrderBy(n => n));
+    }
+
+    [Fact]
+    public void VariableLengthDirectoryNames_AllCreatableDirectoriesAreEnumerable()
+    {
+        DirectoryInfo testDirectory = Directory.CreateDirectory(GetTestFilePath());
+        var names = new List<string>();
+
+        for (int length = 1; length < 10_000; length++) // arbitrarily large limit for the test
+        {
+            string name = new string('a', length);
+            try { Directory.CreateDirectory(Path.Join(testDirectory.FullName, name)); }
+            catch { break; }
+            names.Add(name);
+        }
+        Assert.InRange(names.Count, 1, int.MaxValue);
+        Assert.Equal(names.OrderBy(n => n), Directory.GetDirectories(testDirectory.FullName).Select(n => Path.GetFileName(n)).OrderBy(n => n));
+    }
     }
 }
index c989f38..1aabe7b 100644 (file)
@@ -97,17 +97,17 @@ public static class MountHelper
     /// For standalone debugging help. Change Main0 to Main
      public static void Main0(string[] args)
     {
-               try
+         try
         {
-                       if(args[0]=="-m")
-                               Mount(args[1], args[2]);
-                       if(args[0]=="-u")
-                               Unmount(args[1]);
-               }
+            if(args[0]=="-m")
+                Mount(args[1], args[2]);
+            if(args[0]=="-u")
+                Unmount(args[1]);
+         }
         catch(Exception ex)
         {
-                       Console.WriteLine(ex);
-               }
-    }  
+             Console.WriteLine(ex);
+        }
+    }    
 
 }
index 04ac3f3..ee33859 100644 (file)
@@ -101,7 +101,7 @@ namespace System.IO.Packaging
             absolutePackageUri = absolutePackageUri.Replace('/', ',');
 
             // Step 5 - Append pack:// at the begining and a '/' at the end of the pack uri obtained so far            
-            absolutePackageUri = String.Concat(PackUriHelper.UriSchemePack, Uri.SchemeDelimiter, absolutePackageUri);
+            absolutePackageUri = string.Concat(PackUriHelper.UriSchemePack, Uri.SchemeDelimiter, absolutePackageUri);
 
             Uri packUri = new Uri(absolutePackageUri);
 
@@ -111,7 +111,7 @@ namespace System.IO.Packaging
 
             // Step 7 - Append fragment if present
             if (fragment != null)
-                packUri = new Uri(String.Concat(packUri.GetComponents(UriComponents.AbsoluteUri, UriFormat.UriEscaped), fragment));
+                packUri = new Uri(string.Concat(packUri.GetComponents(UriComponents.AbsoluteUri, UriFormat.UriEscaped), fragment));
 
             // We want to ensure that internal content of resulting Uri has canonical form
             // i.e.  result.OrignalString would appear as perfectly formatted Uri string 
@@ -302,7 +302,7 @@ namespace System.IO.Packaging
             Debug.Assert(packUri != null, "packUri parameter cannot be null");
 
             //Step 1 - Get the authority part of the URI. This section represents that package URI
-            String hostAndPort = packUri.GetComponents(UriComponents.HostAndPort, UriFormat.UriEscaped);
+            string hostAndPort = packUri.GetComponents(UriComponents.HostAndPort, UriFormat.UriEscaped);
 
             //Step 2 - Replace the ',' with '/' to reconstruct the package URI
             hostAndPort = hostAndPort.Replace(',', '/');
@@ -310,7 +310,7 @@ namespace System.IO.Packaging
             //Step 3 - Unescape the special characters that we had escaped to construct the packUri
             Uri packageUri = new Uri(Uri.UnescapeDataString(hostAndPort));
 
-            if (packageUri.Fragment != String.Empty)
+            if (packageUri.Fragment != string.Empty)
                 throw new ArgumentException(SR.InnerPackageUriHasFragment);
 
             return packageUri;
@@ -323,7 +323,7 @@ namespace System.IO.Packaging
             
             string partName = GetStringForPartUriFromAnyUri(packUri);
 
-            if (partName == String.Empty)
+            if (partName == string.Empty)
                 return null;
             else
                 return ValidatePartUri(new Uri(partName, UriKind.Relative));
index e432148..f5cc11b 100644 (file)
@@ -1054,7 +1054,7 @@ namespace System.IO.Ports
                     if (numCharsRead > 1)
                     {
                         for (int i = 0; i < numCharsRead; i++)
-                            Debug.Assert((Char.IsSurrogate(_singleCharBuffer[i])), "number of chars read should be more than one only for surrogate characters!");
+                            Debug.Assert((char.IsSurrogate(_singleCharBuffer[i])), "number of chars read should be more than one only for surrogate characters!");
                     }
 #endif
                     Debug.Assert((numCharsRead > 0), "possible bug in ReadBufferIntoChars, reading surrogate char?");
index 507de7f..e2889af 100644 (file)
@@ -57,7 +57,7 @@ namespace System.IO.Ports
         private byte[] _tempBuf;                 // used to avoid multiple array allocations in ReadByte()
 
         // called whenever any async i/o operation completes.
-        private unsafe static readonly IOCompletionCallback s_IOCallback = new IOCompletionCallback(AsyncFSCallback);
+        private static unsafe readonly IOCompletionCallback s_IOCallback = new IOCompletionCallback(AsyncFSCallback);
 
         // ----- new get-set properties -----------------*
 
index b1956da..d975b8e 100644 (file)
@@ -291,9 +291,9 @@ namespace System.IO.Ports.Tests
 
                 com2.Write(xmitChars, 0, xmitChars.Length);
 
-                //             for(int i=0; i<xmitChars.Length; ++i) {
-                //                     Debug.WriteLine("{0},", (int)xmitChars[i]);
-                //             }
+                //        for(int i=0; i<xmitChars.Length; ++i) {
+                //            Debug.WriteLine("{0},", (int)xmitChars[i]);
+                //        }
 
                 while (com1.BytesToRead < xmitBytes.Length)
                 {
index a8de781..75f6474 100644 (file)
@@ -131,7 +131,7 @@ namespace System.IO.Ports.Tests
 
             newReadBufferSize &= 0xFFFFFFFE; //Make sure the new buffer size is even by clearing the lowest order bit
 
-            //         if(!VerifyReadBufferSize((int)newReadBufferSize)){
+            //        if(!VerifyReadBufferSize((int)newReadBufferSize)){
             VerifyReadBufferSize(11620);
         }
 
index 4fe648c..987ff7f 100644 (file)
@@ -96,7 +96,7 @@ namespace System.IO.Ports.Tests
                 Random rndGen = new Random(-55);
 
                 com.ReadTimeout = rndGen.Next(minRandomTimeout, maxRandomTimeout);
-                //             com.Encoding = new System.Text.UTF7Encoding();
+                //        com.Encoding = new System.Text.UTF7Encoding();
                 com.Encoding = Encoding.Unicode;
 
                 Debug.WriteLine("Verifying ReadTimeout={0} with successive call to read method and no data", com.ReadTimeout);
@@ -171,7 +171,7 @@ namespace System.IO.Ports.Tests
         {
             Random rndGen = new Random(-55);
 
-            //         if(!VerifyParityReplaceByte((int)'\0', rndGen.Next(0, numRndByte - 1), new System.Text.UTF7Encoding())){
+            //        if(!VerifyParityReplaceByte((int)'\0', rndGen.Next(0, numRndByte - 1), new System.Text.UTF7Encoding())){
             VerifyParityReplaceByte('\0', rndGen.Next(0, numRndByte - 1), new UTF32Encoding());
         }
 
index b31300c..975d1de 100644 (file)
@@ -97,7 +97,7 @@ namespace System.IO.Ports.Tests
                 Random rndGen = new Random(-55);
 
                 com.ReadTimeout = rndGen.Next(minRandomTimeout, maxRandomTimeout);
-                //             com.Encoding = new System.Text.UTF7Encoding();
+                //        com.Encoding = new System.Text.UTF7Encoding();
                 com.Encoding = Encoding.Unicode;
 
                 Debug.WriteLine("Verifying ReadTimeout={0} with successive call to read method and no data", com.ReadTimeout);
index 2cb6895..9b51e78 100644 (file)
@@ -694,7 +694,7 @@ namespace System.IO.Ports.Tests
                 bytesRead = com1.Encoding.GetByteCount(rcvCharBuffer, 0, charsRead);
                 totalBytesRead += bytesRead + numNewLineBytes;
 
-                //                     indexOfNewLine = strToWrite.IndexOf(com1.NewLine, lastIndexOfNewLine + newLineStringLength);
+                //            indexOfNewLine = strToWrite.IndexOf(com1.NewLine, lastIndexOfNewLine + newLineStringLength);
                 indexOfNewLine = TCSupport.OrdinalIndexOf(expectedString, lastIndexOfNewLine + newLineStringLength, newLine);
                 //SerialPort does a Ordinal comparison
 
index 596140a..457701c 100644 (file)
@@ -106,7 +106,7 @@ namespace System.IO.Ports.Tests
                 Random rndGen = new Random(-55);
 
                 com.ReadTimeout = rndGen.Next(minRandomTimeout, maxRandomTimeout);
-                //             com.Encoding = new System.Text.UTF7Encoding();
+                //        com.Encoding = new System.Text.UTF7Encoding();
                 com.Encoding = Encoding.Unicode;
                 Debug.WriteLine("Verifying ReadTimeout={0} with successive call to read method and no data", com.ReadTimeout);
                 com.Open();
index b5d5d35..4a63d75 100644 (file)
@@ -726,7 +726,7 @@ namespace System.IO.Ports.Tests
                     totalBytesRead += bytesRead + numNewLineBytes;
                 }
 
-                //                     indexOfNewLine = strToWrite.IndexOf(newLine, lastIndexOfNewLine + newLineStringLength);
+                //            indexOfNewLine = strToWrite.IndexOf(newLine, lastIndexOfNewLine + newLineStringLength);
                 int indexOfNewLine = TCSupport.OrdinalIndexOf(expectedString, lastIndexOfNewLine + newLineStringLength, newLine);
 
 
index b8b2537..b7d1bfc 100644 (file)
@@ -105,7 +105,7 @@ namespace System.IO.Ports.Tests
                 Random rndGen = new Random(-55);
 
                 com.ReadTimeout = rndGen.Next(minRandomTimeout, maxRandomTimeout);
-                //             com.Encoding = new System.Text.UTF7Encoding();
+                //        com.Encoding = new System.Text.UTF7Encoding();
                 com.Encoding = Encoding.Unicode;
 
                 Debug.WriteLine("Verifying ReadTimeout={0} with successive call to read method and no data", com.ReadTimeout);
index 46ce827..1371e12 100644 (file)
@@ -107,7 +107,7 @@ namespace System.IO.Ports.Tests
                 Random rndGen = new Random();
 
                 com.ReadTimeout = rndGen.Next(minRandomTimeout, maxRandomTimeout);
-                //             com.Encoding = new System.Text.UTF7Encoding();
+                //        com.Encoding = new System.Text.UTF7Encoding();
                 com.Encoding = Encoding.Unicode;
 
                 Debug.WriteLine("Verifying ReadTimeout={0} with successive call to read method and no data", com.ReadTimeout);
index 7307193..be574dc 100644 (file)
@@ -537,8 +537,8 @@ namespace System.IO.Ports.Tests
 
                 com2.Write(byteXmitBuffer, 3, byteXmitBuffer.Length - 3);
 
-                //             retValue &= TCSupport.WaitForPredicate(delegate() {return com1.BytesToRead == byteXmitBuffer.Length; }, 
-                //                     5000, "Err_91818aheid Expected BytesToRead={0} actual={1}", byteXmitBuffer.Length, com1.BytesToRead);
+                //        retValue &= TCSupport.WaitForPredicate(delegate() {return com1.BytesToRead == byteXmitBuffer.Length; }, 
+                //            5000, "Err_91818aheid Expected BytesToRead={0} actual={1}", byteXmitBuffer.Length, com1.BytesToRead);
 
                 TCSupport.WaitForExpected(() => com1.BytesToRead, byteXmitBuffer.Length,
                     5000, "Err_91818aheid BytesToRead");
@@ -987,7 +987,7 @@ namespace System.IO.Ports.Tests
     
                 for(int i=0; i<xmitCharBuffer.Length; ++i) {
                     Debug.WriteLine("{0}, ", (int)xmitByteBuffer[i]);
-                }                      
+                }            
             }*/
             }
         }
index fb63151..c37b31c 100644 (file)
@@ -110,7 +110,7 @@ namespace System.IO.Ports.Tests
 
 
                 com.ReadTimeout = rndGen.Next(minRandomTimeout, maxRandomTimeout);
-                //             com.Encoding = new System.Text.UTF7Encoding();
+                //        com.Encoding = new System.Text.UTF7Encoding();
                 com.Encoding = Encoding.Unicode;
 
                 Debug.WriteLine("Verifying ReadTimeout={0} with successive call to read method and no data", com.ReadTimeout);
index f8951e2..452656e 100644 (file)
@@ -55,7 +55,7 @@ namespace System.IO.Ports.Tests
                                     Math.Min(xmitCharBuffer.Length, maxNumberOfCharactes) + 1);
                                 int expectedBytesToRead = com2.BytesToRead + 2 * numberOfCharacters;
 
-                                //                                             Debug.WriteLine("Writing {0,5} characters BytesToRead={1,5}", numberOfCharacters, com2.BytesToRead);
+                                //                        Debug.WriteLine("Writing {0,5} characters BytesToRead={1,5}", numberOfCharacters, com2.BytesToRead);
                                 com1.Write(xmitCharBuffer, 0, numberOfCharacters);
                                 buffer.Append(xmitCharBuffer, 0, numberOfCharacters);
 
@@ -74,7 +74,7 @@ namespace System.IO.Ports.Tests
                                 int actualNumberOfCharactersRead;
                                 int expectedBytesToRead = com2.BytesToRead - (2 * numberOfCharacters);
 
-                                //                                             Debug.WriteLine("Reading {0,5} characters BytesToRead={1,5}", numberOfCharacters, com2.BytesToRead);
+                                //                        Debug.WriteLine("Reading {0,5} characters BytesToRead={1,5}", numberOfCharacters, com2.BytesToRead);
                                 actualNumberOfCharactersRead = com2.Read(rcvCharBuffer, 0, numberOfCharacters);
 
                                 if (actualNumberOfCharactersRead == numberOfCharacters)
index 7a82837..bb7b8c7 100644 (file)
@@ -121,7 +121,7 @@ namespace System.IO.Ports.Tests
 
                 com.WriteTimeout = rndGen.Next(minRandomTimeout, maxRandomTimeout);
                 com.Handshake = Handshake.RequestToSendXOnXOff;
-                //             com.Encoding = new System.Text.UTF7Encoding();
+                //        com.Encoding = new System.Text.UTF7Encoding();
                 com.Encoding = Encoding.Unicode;
 
                 Debug.WriteLine("Verifying WriteTimeout={0} with successive call to write method", com.WriteTimeout);
index d5a453b..df2c23d 100644 (file)
@@ -118,7 +118,7 @@ namespace System.IO.Ports.Tests
 
                 com.WriteTimeout = rndGen.Next(minRandomTimeout, maxRandomTimeout);
                 com.Handshake = Handshake.RequestToSendXOnXOff;
-                //             com.Encoding = new System.Text.UTF7Encoding();
+                //        com.Encoding = new System.Text.UTF7Encoding();
                 com.Encoding = Encoding.Unicode;
 
                 Debug.WriteLine("Verifying WriteTimeout={0} with successive call to write method", com.WriteTimeout);
index f8dd3f1..fa32b23 100644 (file)
@@ -135,7 +135,7 @@ namespace System.IO.Ports.Tests
         {
             var rndGen = new Random(-55);
 
-            //                 if(!VerifyParityReplaceByte((int)'\0', rndGen.Next(0, numRndBytesPairty - 1), new System.Text.UTF7Encoding())){
+            //         if(!VerifyParityReplaceByte((int)'\0', rndGen.Next(0, numRndBytesPairty - 1), new System.Text.UTF7Encoding())){
             VerifyParityReplaceByte((int)'\0', rndGen.Next(0, numRndBytesPairty - 1), Encoding.Unicode);
         }
 
@@ -229,7 +229,7 @@ namespace System.IO.Ports.Tests
         [ConditionalFact(nameof(HasNullModem))]
         public void BytesToRead_1_Buffer_Size()
         {
-            //                 if(!VerifyBytesToRead(1, new System.Text.UTF7Encoding())){
+            //         if(!VerifyBytesToRead(1, new System.Text.UTF7Encoding())){
             VerifyBytesToRead(1, Encoding.UTF32);
         }
 
index e1f4532..2bb9317 100644 (file)
@@ -98,7 +98,7 @@ namespace System.IO.Ports.Tests
 
                 com.WriteTimeout = rndGen.Next(minRandomTimeout, maxRandomTimeout);
                 com.Handshake = Handshake.RequestToSendXOnXOff;
-                //             com.Encoding = new System.Text.UTF7Encoding();
+                //         com.Encoding = new System.Text.UTF7Encoding();
                 com.Encoding = Encoding.Unicode;
 
                 Debug.WriteLine("Verifying WriteTimeout={0} with successive call to write method",
index cf7a066..5d9e27f 100644 (file)
@@ -110,7 +110,7 @@ namespace System.IO.Ports.Tests
 
                 com.WriteTimeout = rndGen.Next(minRandomTimeout, maxRandomTimeout);
                 com.Handshake = Handshake.RequestToSendXOnXOff;
-                //             com.Encoding = new System.Text.UTF7Encoding();
+                //         com.Encoding = new System.Text.UTF7Encoding();
                 com.Encoding = Encoding.Unicode;
 
                 Debug.WriteLine("Verifying WriteTimeout={0} with successive call to write method", com.WriteTimeout);
index aac73b9..64d3437 100644 (file)
@@ -250,7 +250,7 @@ namespace System.IO.Tests
                     return --readsLeft; // CopyTo will call Read on this ReadLimit times before stopping 
                 });
 
-               var src = new CallTrackingStream(srcBase);
+            var src = new CallTrackingStream(srcBase);
 
             var destBase = new DelegateStream(
                 canWriteFunc: () => true,
@@ -305,7 +305,7 @@ namespace System.IO.Tests
                     return --readsLeft; // CopyTo will call Read on this ReadLimit times before stopping 
                 });
 
-               var src = new CallTrackingStream(srcBase);
+            var src = new CallTrackingStream(srcBase);
 
             var destBase = new DelegateStream(
                 canWriteFunc: () => true,
index 9718398..ef74b9d 100644 (file)
@@ -43,9 +43,9 @@ namespace System.Linq.Expressions
         public Expression Filter { get; }
 
         /// <summary>
-        /// Returns a <see cref="String"/> that represents the current <see cref="Object"/>.
+        /// Returns a <see cref="string"/> that represents the current <see cref="object"/>.
         /// </summary>
-        /// <returns>A <see cref="String"/> that represents the current <see cref="Object"/>.</returns>
+        /// <returns>A <see cref="string"/> that represents the current <see cref="object"/>.</returns>
         public override string ToString()
         {
             return ExpressionStringBuilder.CatchBlockToString(this);
index 8ae7b0a..4dfaa4c 100644 (file)
@@ -72,7 +72,7 @@ namespace System.Linq.Expressions
         /// <summary>
         /// Creates a <see cref="ConstantExpression"/> that has the <see cref="ConstantExpression.Value"/> property set to the specified value. .
         /// </summary>
-        /// <param name="value">An <see cref="Object"/> to set the <see cref="ConstantExpression.Value"/> property equal to.</param>
+        /// <param name="value">An <see cref="object"/> to set the <see cref="ConstantExpression.Value"/> property equal to.</param>
         /// <returns>
         /// A <see cref="ConstantExpression"/> that has the <see cref="NodeType"/> property equal to
         /// <see cref="ExpressionType.Constant"/> and the <see cref="ConstantExpression.Value"/> property set to the specified value.
@@ -86,7 +86,7 @@ namespace System.Linq.Expressions
         /// Creates a <see cref="ConstantExpression"/> that has the <see cref="ConstantExpression.Value"/>
         /// and <see cref="ConstantExpression.Type"/> properties set to the specified values. .
         /// </summary>
-        /// <param name="value">An <see cref="Object"/> to set the <see cref="ConstantExpression.Value"/> property equal to.</param>
+        /// <param name="value">An <see cref="object"/> to set the <see cref="ConstantExpression.Value"/> property equal to.</param>
         /// <param name="type">A <see cref="Type"/> to set the <see cref="Type"/> property equal to.</param>
         /// <returns>
         /// A <see cref="ConstantExpression"/> that has the <see cref="NodeType"/> property equal to
index 558da81..d8645fd 100644 (file)
@@ -43,9 +43,9 @@ namespace System.Linq.Expressions
         public int ArgumentCount => Arguments.Count;
 
         /// <summary>
-        /// Creates a <see cref="String"/> representation of the node.
+        /// Creates a <see cref="string"/> representation of the node.
         /// </summary>
-        /// <returns>A <see cref="String"/> representation of the node.</returns>
+        /// <returns>A <see cref="string"/> representation of the node.</returns>
         public override string ToString()
         {
             return ExpressionStringBuilder.ElementInitBindingToString(this);
index de52946..6a73a2c 100644 (file)
@@ -203,18 +203,18 @@ comparand: null
         }
 
         /// <summary>
-        /// Creates a <see cref="String"/> representation of the Expression.
+        /// Creates a <see cref="string"/> representation of the Expression.
         /// </summary>
-        /// <returns>A <see cref="String"/> representation of the Expression.</returns>
+        /// <returns>A <see cref="string"/> representation of the Expression.</returns>
         public override string ToString()
         {
             return ExpressionStringBuilder.ExpressionToString(this);
         }
 
         /// <summary>
-        /// Creates a <see cref="String"/> representation of the Expression.
+        /// Creates a <see cref="string"/> representation of the Expression.
         /// </summary>
-        /// <returns>A <see cref="String"/> representation of the Expression.</returns>
+        /// <returns>A <see cref="string"/> representation of the Expression.</returns>
         private string DebugView
         {
             // Note that this property is often accessed using reflection. As such it will have more dependencies than one
index 8c2608c..b8e407c 100644 (file)
@@ -31,9 +31,9 @@ namespace System.Linq.Expressions
         public Type Type { get; }
 
         /// <summary>
-        /// Returns a <see cref="String"/> that represents the current <see cref="Object"/>.
+        /// Returns a <see cref="string"/> that represents the current <see cref="object"/>.
         /// </summary>
-        /// <returns>A <see cref="String"/> that represents the current <see cref="Object"/>.</returns>
+        /// <returns>A <see cref="string"/> that represents the current <see cref="object"/>.</returns>
         public override string ToString()
         {
             return string.IsNullOrEmpty(Name) ? "UnamedLabel" : Name;
index c1c5884..22d6415 100644 (file)
@@ -53,9 +53,9 @@ namespace System.Linq.Expressions
         public MemberInfo Member { get; }
 
         /// <summary>
-        /// Returns a <see cref="String"/> that represents the current <see cref="Object"/>.
+        /// Returns a <see cref="string"/> that represents the current <see cref="object"/>.
         /// </summary>
-        /// <returns>A <see cref="String"/> that represents the current <see cref="Object"/>.</returns>
+        /// <returns>A <see cref="string"/> that represents the current <see cref="object"/>.</returns>
         public override string ToString()
         {
             return ExpressionStringBuilder.MemberBindingToString(this);
index bb97b9b..98a1561 100644 (file)
@@ -1400,7 +1400,7 @@ namespace System.Linq.Expressions
         /// <exception cref="ArgumentNullException">
         /// <paramref name="array"/> or <paramref name="indexes"/> is null.</exception>
         /// <exception cref="ArgumentException">
-        /// <paramref name="array"/>.Type does not represent an array type.-or-The rank of <paramref name="array"/>.Type does not match the number of elements in <paramref name="indexes"/>.-or-The <see cref="Expression.Type"/> property of one or more elements of <paramref name="indexes"/> does not represent the <see cref="Int32"/> type.</exception>
+        /// <paramref name="array"/>.Type does not represent an array type.-or-The rank of <paramref name="array"/>.Type does not match the number of elements in <paramref name="indexes"/>.-or-The <see cref="Expression.Type"/> property of one or more elements of <paramref name="indexes"/> does not represent the <see cref="int"/> type.</exception>
         public static MethodCallExpression ArrayIndex(Expression array, IEnumerable<Expression> indexes)
         {
             ExpressionUtils.RequiresCanRead(array, nameof(array), -1);
index f456972..002d059 100644 (file)
@@ -32,9 +32,9 @@ namespace System.Linq.Expressions
         public Expression Body { get; }
 
         /// <summary>
-        /// Returns a <see cref="String"/> that represents the current <see cref="Object"/>.
+        /// Returns a <see cref="string"/> that represents the current <see cref="object"/>.
         /// </summary>
-        /// <returns>A <see cref="String"/> that represents the current <see cref="Object"/>.</returns>
+        /// <returns>A <see cref="string"/> that represents the current <see cref="object"/>.</returns>
         public override string ToString()
         {
             return ExpressionStringBuilder.SwitchCaseToString(this);
index 6471a76..74f295e 100644 (file)
@@ -79,7 +79,7 @@ namespace System.Linq.Expressions
         /// <summary>
         /// Creates an instance of <see cref="SymbolDocumentInfo"/>.
         /// </summary>
-        /// <param name="fileName">A <see cref="String"/> to set the <see cref="SymbolDocumentInfo.FileName"/> equal to.</param>
+        /// <param name="fileName">A <see cref="string"/> to set the <see cref="SymbolDocumentInfo.FileName"/> equal to.</param>
         /// <returns>A <see cref="SymbolDocumentInfo"/> that has the <see cref="SymbolDocumentInfo.FileName"/> property set to the specified value.</returns>
         public static SymbolDocumentInfo SymbolDocument(string fileName)
         {
@@ -89,7 +89,7 @@ namespace System.Linq.Expressions
         /// <summary>
         /// Creates an instance of <see cref="SymbolDocumentInfo"/>.
         /// </summary>
-        /// <param name="fileName">A <see cref="String"/> to set the <see cref="SymbolDocumentInfo.FileName"/> equal to.</param>
+        /// <param name="fileName">A <see cref="string"/> to set the <see cref="SymbolDocumentInfo.FileName"/> equal to.</param>
         /// <param name="language">A <see cref="Guid"/> to set the <see cref="SymbolDocumentInfo.Language"/> equal to.</param>
         /// <returns>A <see cref="SymbolDocumentInfo"/> that has the <see cref="SymbolDocumentInfo.FileName"/>
         /// and <see cref="SymbolDocumentInfo.Language"/> properties set to the specified value.</returns>
@@ -101,7 +101,7 @@ namespace System.Linq.Expressions
         /// <summary>
         /// Creates an instance of <see cref="SymbolDocumentInfo"/>.
         /// </summary>
-        /// <param name="fileName">A <see cref="String"/> to set the <see cref="SymbolDocumentInfo.FileName"/> equal to.</param>
+        /// <param name="fileName">A <see cref="string"/> to set the <see cref="SymbolDocumentInfo.FileName"/> equal to.</param>
         /// <param name="language">A <see cref="Guid"/> to set the <see cref="SymbolDocumentInfo.Language"/> equal to.</param>
         /// <param name="languageVendor">A <see cref="Guid"/> to set the <see cref="SymbolDocumentInfo.LanguageVendor"/> equal to.</param>
         /// <returns>A <see cref="SymbolDocumentInfo"/> that has the <see cref="SymbolDocumentInfo.FileName"/>
@@ -115,7 +115,7 @@ namespace System.Linq.Expressions
         /// <summary>
         /// Creates an instance of <see cref="SymbolDocumentInfo"/>.
         /// </summary>
-        /// <param name="fileName">A <see cref="String"/> to set the <see cref="SymbolDocumentInfo.FileName"/> equal to.</param>
+        /// <param name="fileName">A <see cref="string"/> to set the <see cref="SymbolDocumentInfo.FileName"/> equal to.</param>
         /// <param name="language">A <see cref="Guid"/> to set the <see cref="SymbolDocumentInfo.Language"/> equal to.</param>
         /// <param name="languageVendor">A <see cref="Guid"/> to set the <see cref="SymbolDocumentInfo.LanguageVendor"/> equal to.</param>
         /// <param name="documentType">A <see cref="Guid"/> to set the <see cref="SymbolDocumentInfo.DocumentType"/> equal to.</param>
index 0b5f4ee..d3e8541 100644 (file)
@@ -7,7 +7,7 @@ using System.Collections.Generic;
 namespace System.Runtime.CompilerServices
 {
     /// <summary>
-    /// Indicates that the use of <see cref="System.Object"/> on a member is meant to be treated as a dynamically dispatched type.
+    /// Indicates that the use of <see cref="object"/> on a member is meant to be treated as a dynamically dispatched type.
     /// </summary>
     [AttributeUsage(AttributeTargets.Field | AttributeTargets.Parameter | AttributeTargets.Property | AttributeTargets.ReturnValue | AttributeTargets.Class | AttributeTargets.Struct)]
     public sealed class DynamicAttribute : Attribute
@@ -21,7 +21,7 @@ namespace System.Runtime.CompilerServices
         /// When used in an attribute specification, the default constructor is semantically
         /// equivalent to <c>DynamicAttribute({ true })</c>, and can be considered
         /// a shorthand for that expression. It should therefore only be used on an element
-        /// of type <see cref="System.Object"/>.
+        /// of type <see cref="object"/>.
         /// </remarks>
         public DynamicAttribute()
         {
@@ -32,13 +32,13 @@ namespace System.Runtime.CompilerServices
         /// Initializes a new instance of the <see cref="DynamicAttribute"/> class.
         /// </summary>
         /// <param name="transformFlags">Specifies, in a prefix traversal of a type's
-        /// construction, which <see cref="System.Object"/> occurrences are meant to
+        /// construction, which <see cref="object"/> occurrences are meant to
         /// be treated as a dynamically dispatched type.</param>
         /// <remarks>
         /// This constructor is meant to be used on types that are built on an underlying
-        /// occurrence of <see cref="System.Object"/> that is meant to be treated dynamically.
+        /// occurrence of <see cref="object"/> that is meant to be treated dynamically.
         /// For instance, if <c>C</c> is a generic type with two type parameters, then a
-        /// use of the constructed type<c>C&lt;<see cref="System.Object"/>, <see cref="System.Object"/>&gt;</c>
+        /// use of the constructed type<c>C&lt;<see cref="object"/>, <see cref="object"/>&gt;</c>
         /// might be intended to treat the first type argument dynamically and the second
         /// normally, in which case the appropriate attribute specification should
         /// use a <c>transformFlags</c> value of <c>{ false, true, false }</c>.
@@ -55,7 +55,7 @@ namespace System.Runtime.CompilerServices
 
         /// <summary>
         /// Specifies, in a prefix traversal of a type's
-        /// construction, which <see cref="System.Object"/> occurrences are meant to
+        /// construction, which <see cref="object"/> occurrences are meant to
         /// be treated as a dynamically dispatched type.
         /// </summary>
         public IList<bool> TransformFlags
index f1d49a2..75c69a8 100644 (file)
@@ -419,7 +419,7 @@ namespace System.Linq
         /// <exception cref="System.ArgumentOutOfRangeException">
         /// <paramref name="count"/> is less than 0
         /// -or-
-        /// <paramref name="start"/> + <paramref name="count"/> - 1 is larger than <see cref="System.Int32.MaxValue"/>.
+        /// <paramref name="start"/> + <paramref name="count"/> - 1 is larger than <see cref="int.MaxValue"/>.
         /// </exception>
         public static ParallelQuery<int> Range(int start, int count)
         {
@@ -1858,7 +1858,7 @@ namespace System.Linq
         /// <paramref name="source"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The number of elements in source is larger than <see cref="System.Int32.MaxValue"/>.
+        /// The number of elements in source is larger than <see cref="int.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -1902,7 +1902,7 @@ namespace System.Linq
         /// <paramref name="source"/> or <paramref name="predicate"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The number of elements in source is larger than <see cref="System.Int32.MaxValue"/>.
+        /// The number of elements in source is larger than <see cref="int.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -1931,7 +1931,7 @@ namespace System.Linq
         /// <paramref name="source"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The number of elements in source is larger than <see cref="System.Int64.MaxValue"/>.
+        /// The number of elements in source is larger than <see cref="long.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -1971,7 +1971,7 @@ namespace System.Linq
         /// <paramref name="source"/> or <paramref name="predicate"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The number of elements in source is larger than <see cref="System.Int64.MaxValue"/>.
+        /// The number of elements in source is larger than <see cref="long.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -2000,7 +2000,7 @@ namespace System.Linq
         /// <paramref name="source"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum is larger than <see cref="System.Int32.MaxValue"/>.
+        /// The sum is larger than <see cref="int.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -2022,7 +2022,7 @@ namespace System.Linq
         /// <paramref name="source"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum is larger than <see cref="System.Int32.MaxValue"/>.
+        /// The sum is larger than <see cref="int.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -2044,7 +2044,7 @@ namespace System.Linq
         /// <paramref name="source"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum is larger than <see cref="System.Int64.MaxValue"/>.
+        /// The sum is larger than <see cref="long.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -2066,7 +2066,7 @@ namespace System.Linq
         /// <paramref name="source"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum is larger than <see cref="System.Int64.MaxValue"/>.
+        /// The sum is larger than <see cref="long.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -2168,7 +2168,7 @@ namespace System.Linq
         /// <paramref name="source"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum is larger than <see cref="System.Decimal.MaxValue"/>.
+        /// The sum is larger than <see cref="decimal.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -2190,7 +2190,7 @@ namespace System.Linq
         /// <paramref name="source"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum is larger than <see cref="System.Decimal.MaxValue"/>.
+        /// The sum is larger than <see cref="decimal.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -2214,7 +2214,7 @@ namespace System.Linq
         /// <paramref name="source"/> or <paramref name="selector"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum is larger than <see cref="System.Int32.MaxValue"/>.
+        /// The sum is larger than <see cref="int.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -2238,7 +2238,7 @@ namespace System.Linq
         /// <paramref name="source"/> or <paramref name="selector"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum is larger than <see cref="System.Int32.MaxValue"/>.
+        /// The sum is larger than <see cref="int.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -2262,7 +2262,7 @@ namespace System.Linq
         /// <paramref name="source"/> or <paramref name="selector"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum is larger than <see cref="System.Int64.MaxValue"/>.
+        /// The sum is larger than <see cref="long.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -2286,7 +2286,7 @@ namespace System.Linq
         /// <paramref name="source"/> or <paramref name="selector"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum is larger than <see cref="System.Int64.MaxValue"/>.
+        /// The sum is larger than <see cref="long.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -2398,7 +2398,7 @@ namespace System.Linq
         /// <paramref name="source"/> or <paramref name="selector"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum is larger than <see cref="System.Decimal.MaxValue"/>.
+        /// The sum is larger than <see cref="decimal.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -2422,7 +2422,7 @@ namespace System.Linq
         /// <paramref name="source"/> or <paramref name="selector"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum is larger than <see cref="System.Decimal.MaxValue"/>.
+        /// The sum is larger than <see cref="decimal.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -3467,7 +3467,7 @@ namespace System.Linq
         /// <paramref name="source"/> contains no elements.
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum or count of the elements in the sequence is larger than <see cref="System.Int32.MaxValue"/>.
+        /// The sum or count of the elements in the sequence is larger than <see cref="int.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -3489,7 +3489,7 @@ namespace System.Linq
         /// <paramref name="source"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum or count of the elements in the sequence is larger than <see cref="System.Int32.MaxValue"/>.
+        /// The sum or count of the elements in the sequence is larger than <see cref="int.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -3514,7 +3514,7 @@ namespace System.Linq
         /// <paramref name="source"/> contains no elements.
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum or count of the elements in the sequence is larger than <see cref="System.Int32.MaxValue"/>.
+        /// The sum or count of the elements in the sequence is larger than <see cref="int.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -3536,7 +3536,7 @@ namespace System.Linq
         /// <paramref name="source"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum or count of the elements in the sequence is larger than <see cref="System.Int32.MaxValue"/>.
+        /// The sum or count of the elements in the sequence is larger than <see cref="int.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -3693,7 +3693,7 @@ namespace System.Linq
         /// <paramref name="source"/> contains no elements.
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum or count of the elements in the sequence is larger than <see cref="System.Int32.MaxValue"/>.
+        /// The sum or count of the elements in the sequence is larger than <see cref="int.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -3717,7 +3717,7 @@ namespace System.Linq
         /// <paramref name="source"/> or <paramref name="selector"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum or count of the elements in the sequence is larger than <see cref="System.Int32.MaxValue"/>.
+        /// The sum or count of the elements in the sequence is larger than <see cref="int.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -3744,7 +3744,7 @@ namespace System.Linq
         /// <paramref name="source"/> contains no elements.
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum or count of the elements in the sequence is larger than <see cref="System.Int32.MaxValue"/>.
+        /// The sum or count of the elements in the sequence is larger than <see cref="int.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
@@ -3768,7 +3768,7 @@ namespace System.Linq
         /// <paramref name="source"/> or <paramref name="selector"/> is a null reference (Nothing in Visual Basic).
         /// </exception>
         /// <exception cref="System.AggregateException">
-        /// The sum or count of the elements in the sequence is larger than <see cref="System.Int64.MaxValue"/>.
+        /// The sum or count of the elements in the sequence is larger than <see cref="long.MaxValue"/>.
         /// -or-
         /// One or more exceptions occurred during the evaluation of the query.
         /// </exception>
index dfdcf30..ef3ff0f 100644 (file)
@@ -471,7 +471,7 @@ namespace System.Management
         /// </summary>
         /// <param name='propertyName'>The name of the property of interest. </param>
         /// <value>
-        ///    An <see cref='System.Object'/> containing the
+        ///    An <see cref='object'/> containing the
         ///    value of the requested property.
         /// </value>
         public object this[string propertyName] 
index afd0b01..5d55333 100644 (file)
@@ -9,11 +9,11 @@ using System.CodeDom;
 
 namespace System.Management
 {
-    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//        
+    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//
     /// <summary>
     ///    <para> Represents a CIM management class from WMI. CIM (Common Information Model) classes 
-    ///                        represent management information including hardware, software, processes, etc.
-    ///                        For more information about the CIM classes available in Windows search for ï¿½win32 classes�.</para>
+    ///            represent management information including hardware, software, processes, etc.
+    ///            For more information about the CIM classes available in Windows search for ï¿½win32 classes�.</para>
     /// </summary>
     /// <example>
     ///    <code lang='C#'>using System;
@@ -103,8 +103,8 @@ namespace System.Management
                 // (Options, Path and Scope) would mark it as unbound
                 //
                 // ***
-                // *   Changed isBound flag to wbemObject==null check.
-                // *   newClass.IsBound = true;
+                // *    Changed isBound flag to wbemObject==null check.
+                // *    newClass.IsBound = true;
                 // ***
             }
 
@@ -466,8 +466,8 @@ namespace System.Management
             //The only flags in EnumerationOptions not valid for enumerations are EnsureLocatable & PrototypeOnly.
             o.EnsureLocatable = false; o.PrototypeOnly = false;
 
-            SecurityHandler securityHandler    = null;
-            int status                                         = (int)ManagementStatus.NoError;
+            SecurityHandler securityHandler = null;
+            int status                      = (int)ManagementStatus.NoError;
 
             try
             {
@@ -602,8 +602,8 @@ namespace System.Management
             
             WmiEventSink sink = watcher.GetNewSink(Scope, o.Context);
 
-            SecurityHandler securityHandler    = null;
-            int status                                         = (int)ManagementStatus.NoError;
+            SecurityHandler securityHandler = null;
+            int status                      = (int)ManagementStatus.NoError;
 
             securityHandler = Scope.GetSecurityHandler();
 
@@ -691,7 +691,7 @@ namespace System.Management
             o.EnsureLocatable = false; o.PrototypeOnly = false;
 
             SecurityHandler securityHandler = null;
-            int status                                         = (int)ManagementStatus.NoError;
+            int status                      = (int)ManagementStatus.NoError;
 
             try
             {
@@ -736,7 +736,7 @@ namespace System.Management
         /// <param name='options'>The specified additional options to use in the derived class retrieval.</param>
         public void GetSubclasses(ManagementOperationObserver watcher,
                                         EnumerationOptions options) 
-        {                              
+        {
             if (null == watcher)
                 throw new ArgumentNullException(nameof(watcher));
             
@@ -762,7 +762,7 @@ namespace System.Management
             WmiEventSink sink = watcher.GetNewSink(Scope, o.Context);
 
             SecurityHandler securityHandler = null;
-            int status                                         = (int)ManagementStatus.NoError;
+            int status                      = (int)ManagementStatus.NoError;
 
             securityHandler = Scope.GetSecurityHandler();
 
@@ -1040,7 +1040,7 @@ namespace System.Management
             //Ensure EnumerateDeep flag bit is turned off as it's invalid for queries
             o.EnumerateDeep = true;
 
-            RelatedObjectQuery q = new RelatedObjectQuery(true,        Path.Path, 
+            RelatedObjectQuery q = new RelatedObjectQuery(true,    Path.Path, 
                                                             relatedClass,
                                                             relationshipClass, 
                                                             relatedQualifier,
@@ -1048,7 +1048,7 @@ namespace System.Management
                                                             relatedRole, thisRole);
 
             SecurityHandler securityHandler = null;
-            int status                                         = (int)ManagementStatus.NoError;
+            int status                      = (int)ManagementStatus.NoError;
 
             try
             {
@@ -1159,7 +1159,7 @@ namespace System.Management
                                                                 relatedRole, thisRole);
             
                 SecurityHandler securityHandler = null;
-                int status                                             = (int)ManagementStatus.NoError;
+                int status                      = (int)ManagementStatus.NoError;
 
                 securityHandler = Scope.GetSecurityHandler();
 
@@ -1254,7 +1254,7 @@ namespace System.Management
                                                         relationshipQualifier, thisRole);
             
             SecurityHandler securityHandler = null;
-            int status                                         = (int)ManagementStatus.NoError;
+            int status                      = (int)ManagementStatus.NoError;
 
             //Execute WMI query
             try
@@ -1359,7 +1359,7 @@ namespace System.Management
                         relationshipQualifier, thisRole);
 
                 SecurityHandler securityHandler = null;
-                int status                                             = (int)ManagementStatus.NoError;
+                int status                      = (int)ManagementStatus.NoError;
 
                 securityHandler = Scope.GetSecurityHandler();
 
index b043071..4335ac8 100644 (file)
@@ -85,28 +85,28 @@ namespace System.Management
 
         /// <summary>
         /// <para>Converts a given DMTF datetime to <see cref='System.DateTime'/> object. The returned DateTime will be in the 
-        ///                    current TimeZone of the system.</para>
+        ///            current TimeZone of the system.</para>
         /// </summary>
         /// <param name='dmtfDate'>A string representing the datetime in DMTF format.</param>
         /// <returns>
         /// <para>A <see cref='System.DateTime'/> object that represents the given DMTF datetime.</para>
         /// </returns>
         /// <remarks>
-        ///                    <para> Date and time in WMI is represented in DMTF datetime format. This format is explained in WMI SDK documentation.
-        ///                            DMTF datetime string has an UTC offset which this datetime string represents.
-        ///                             During conversion to <see cref='System.DateTime'/>, UTC offset is used to convert the date to the 
-        ///                            current timezone. According to DMTF format a particular field can be represented by the character 
-        ///                            '*'. This will be converted to the MinValue of this field that can be represented in <see cref='System.DateTime'/>.
-        ///                    </para>
+        ///            <para> Date and time in WMI is represented in DMTF datetime format. This format is explained in WMI SDK documentation.
+        ///                DMTF datetime string has an UTC offset which this datetime string represents.
+        ///                 During conversion to <see cref='System.DateTime'/>, UTC offset is used to convert the date to the 
+        ///                current timezone. According to DMTF format a particular field can be represented by the character 
+        ///                '*'. This will be converted to the MinValue of this field that can be represented in <see cref='System.DateTime'/>.
+        ///            </para>
         /// </remarks>
         /// <example>
         ///    <code lang='C#'>
-        ///    // Convert a DMTF datetime to System.DateTime 
-        ///    DateTime date = ManagementDateTimeConverter.ToDateTime("20020408141835.999999-420");
+        /// // Convert a DMTF datetime to System.DateTime 
+        /// DateTime date = ManagementDateTimeConverter.ToDateTime("20020408141835.999999-420");
         ///    </code>
         ///    <code lang='VB'>
-        ///    ' Convert a DMTF datetime to System.DateTime
-        ///    Dim date as DateTime = ManagementDateTimeConverter.ToDateTime("20020408141835.999999-420")
+        /// ' Convert a DMTF datetime to System.DateTime
+        /// Dim date as DateTime = ManagementDateTimeConverter.ToDateTime("20020408141835.999999-420")
         ///    </code>
         /// </example>
         public static DateTime ToDateTime(string dmtfDate)
@@ -207,29 +207,29 @@ namespace System.Management
 
         /// <summary>
         /// <para>Converts a given <see cref='System.DateTime'/> object to DMTF format.</para>
-        ///            
+        ///        
         /// </summary>
         /// <param name='date'>A <see cref='System.DateTime'/> object representing the datetime to be converted to DMTF datetime.</param>
         /// <returns>
         /// <para>A string that represents the DMTF datetime for the given DateTime object.</para>
         /// </returns>
         /// <remarks>
-        ///                    <para> Date and time in WMI is represented in DMTF datetime format. This format is explained in WMI SDK documentation.
-        ///                            The DMTF datetime string represented will be with respect to the UTC offset of the 
-        ///                            current timezone. The lowest precision in DMTF is microseconds and 
-        ///                            in <see cref='System.DateTime'/> is Ticks , which is equivalent to 100 of nanoseconds.
-        ///                             During conversion these Ticks are converted to microseconds and rounded 
-        ///                             off to the nearest microsecond.
-        ///                    </para>
+        ///            <para> Date and time in WMI is represented in DMTF datetime format. This format is explained in WMI SDK documentation.
+        ///                The DMTF datetime string represented will be with respect to the UTC offset of the 
+        ///                current timezone. The lowest precision in DMTF is microseconds and 
+        ///                in <see cref='System.DateTime'/> is Ticks , which is equivalent to 100 of nanoseconds.
+        ///                 During conversion these Ticks are converted to microseconds and rounded 
+        ///                 off to the nearest microsecond.
+        ///            </para>
         /// </remarks>
         /// <example>
         ///    <code lang='C#'>
-        ///    // Convert the current time in System.DateTime to DMTF format
-        ///    string dmtfDateTime = ManagementDateTimeConverter.ToDmtfDateTime(DateTime.Now);
+        /// // Convert the current time in System.DateTime to DMTF format
+        /// string dmtfDateTime = ManagementDateTimeConverter.ToDmtfDateTime(DateTime.Now);
         ///    </code>
         ///    <code lang='VB'>
-        ///    ' Convert the current time in System.DateTime to DMTF format
-        ///    Dim dmtfDateTime as String = ManagementDateTimeConverter.ToDmtfDateTime(DateTime.Now)
+        /// ' Convert the current time in System.DateTime to DMTF format
+        /// Dim dmtfDateTime as String = ManagementDateTimeConverter.ToDmtfDateTime(DateTime.Now)
         ///    </code>
         /// </example>
         public static string ToDmtfDateTime(DateTime date)
@@ -277,7 +277,7 @@ namespace System.Management
             string strMicrosec = microsec.ToString((IFormatProvider)CultureInfo.InvariantCulture.GetFormat(typeof(long)));
             if(strMicrosec.Length > 6)
             {
-                strMicrosec = strMicrosec.Substring(0,6);                              
+                strMicrosec = strMicrosec.Substring(0,6);                
             }
             dmtfDateTime = dmtfDateTime + strMicrosec.PadLeft(6,'0');
             // adding the UTC offset
@@ -293,19 +293,19 @@ namespace System.Management
         /// <para>A <see cref='System.TimeSpan'/> object that represents the given DMTF time interval.</para>
         /// </returns>
         /// <remarks>
-        ///                    <para> Time interval in WMI is represented in DMTF format. This format is explained in WMI SDK documentation.
-        ///                                    If the DMTF time interval value is more than that of 
-        ///                                    <see cref='System.TimeSpan.MaxValue'/> then <see cref='System.ArgumentOutOfRangeException'/> is thrown.
-        ///                    </para>
+        ///            <para> Time interval in WMI is represented in DMTF format. This format is explained in WMI SDK documentation.
+        ///                    If the DMTF time interval value is more than that of 
+        ///                    <see cref='System.TimeSpan.MaxValue'/> then <see cref='System.ArgumentOutOfRangeException'/> is thrown.
+        ///            </para>
         /// </remarks>
         /// <example>
         ///    <code lang='C#'>
-        ///    // Convert a DMTF time interval to System.TimeSpan
-        ///    TimeSpan dmtfTimeInterval = ManagementDateTimeConverter.ToTimeSpan("00000010122532:123456:000");
+        /// // Convert a DMTF time interval to System.TimeSpan
+        /// TimeSpan dmtfTimeInterval = ManagementDateTimeConverter.ToTimeSpan("00000010122532:123456:000");
         ///    </code>
         ///    <code lang='VB'>
-        ///    ' Convert a DMTF time interval to System.TimeSpan
-        ///    Dim ts as TimeSpan = ManagementDateTimeConverter.ToTimeSpan("00000010122532:123456:000")
+        /// ' Convert a DMTF time interval to System.TimeSpan
+        /// Dim ts as TimeSpan = ManagementDateTimeConverter.ToTimeSpan("00000010122532:123456:000")
         ///    </code>
         /// </example>
         public static TimeSpan ToTimeSpan(string dmtfTimespan)
@@ -385,29 +385,29 @@ namespace System.Management
         /// <para>A string that represents the DMTF time interval for the given TimeSpan object.</para>
         /// </returns>
         /// <remarks>
-        ///                    <para> Time interval in WMI is represented in DMTF datetime format. This format 
-        ///                            is explained in WMI SDK documentation. The lowest precision in 
-        ///                            DMTF is microseconds and in <see cref='System.TimeSpan'/> is Ticks , which is equivalent 
-        ///                            to 100 of nanoseconds.During conversion these Ticks are converted to 
-        ///                            microseconds and rounded off to the nearest microsecond.
-        ///                    </para>
+        ///            <para> Time interval in WMI is represented in DMTF datetime format. This format 
+        ///                is explained in WMI SDK documentation. The lowest precision in 
+        ///                DMTF is microseconds and in <see cref='System.TimeSpan'/> is Ticks , which is equivalent 
+        ///                to 100 of nanoseconds.During conversion these Ticks are converted to 
+        ///                microseconds and rounded off to the nearest microsecond.
+        ///            </para>
         /// </remarks>
         /// <example>
         ///    <code lang='C#'>
-        ///    // Construct a Timespan object and convert it to DMTF format
-        ///    System.TimeSpan ts = new System.TimeSpan(10,12,25,32,456);
-        ///    String dmtfTimeInterval = ManagementDateTimeConverter.ToDmtfTimeInterval(ts);
+        /// // Construct a Timespan object and convert it to DMTF format
+        /// System.TimeSpan ts = new System.TimeSpan(10,12,25,32,456);
+        /// String dmtfTimeInterval = ManagementDateTimeConverter.ToDmtfTimeInterval(ts);
         ///    </code>
         ///    <code lang='VB'>
-        ///    // Construct a Timespan object and convert it to DMTF format
-        ///    Dim ts as System.TimeSpan = new System.TimeSpan(10,12,25,32,456)
-        ///    Dim dmtfTimeInterval as String = ManagementDateTimeConverter.ToDmtfTimeInterval(ts)
+        /// // Construct a Timespan object and convert it to DMTF format
+        /// Dim ts as System.TimeSpan = new System.TimeSpan(10,12,25,32,456)
+        /// Dim dmtfTimeInterval as String = ManagementDateTimeConverter.ToDmtfTimeInterval(ts)
         ///    </code>
         /// </example>
         public static string ToDmtfTimeInterval(TimeSpan timespan)
         {
             
-            string dmtftimespan = timespan.Days.ToString((IFormatProvider)CultureInfo.InvariantCulture.GetFormat(typeof(System.Int32))).PadLeft(8,'0');
+            string dmtftimespan = timespan.Days.ToString((IFormatProvider)CultureInfo.InvariantCulture.GetFormat(typeof(int))).PadLeft(8,'0');
             IFormatProvider frmInt32 = (IFormatProvider)CultureInfo.InvariantCulture.GetFormat(typeof(int));
             
             // Days that can be represented is more than what can be represented
@@ -429,10 +429,10 @@ namespace System.Management
             long microsec = ((timespan.Ticks-tsTemp.Ticks) * 1000) / System.TimeSpan.TicksPerMillisecond;
             
             // fill the microseconds field
-            string strMicrosec = microsec.ToString((IFormatProvider)CultureInfo.InvariantCulture.GetFormat(typeof(long)));             
+            string strMicrosec = microsec.ToString((IFormatProvider)CultureInfo.InvariantCulture.GetFormat(typeof(long)));
             if(strMicrosec.Length > 6)
             {
-                strMicrosec = strMicrosec.Substring(0,6);                              
+                strMicrosec = strMicrosec.Substring(0,6);
             }
             dmtftimespan = dmtftimespan + strMicrosec.PadLeft(6,'0');
             
index 9efe11b..c903272 100644 (file)
@@ -188,9 +188,9 @@ public class ObjectPutEventArgs : ManagementEventArgs
 /// </summary>
 public class ProgressEventArgs : ManagementEventArgs
 {
-    private int                        upperBound;
-    private int                        current;
-    private string             message;
+    private int    upperBound;
+    private int    current;
+    private string message;
     
     /// <summary>
     /// Constructor
index a327f28..b48b2e3 100644 (file)
@@ -16,55 +16,55 @@ namespace System.Management
         /// <summary>
         ///    The operation was successful.
         /// </summary>
-        NoError                                                        = 0,
+        NoError                         = 0,
         /// <summary>
         ///    <para> This value is returned when no more objects 
         ///       are available, the number of objects returned is less than the number requested,
         ///       or at the end of an enumeration. It is also returned when the method is called
         ///       with a value of 0 for the "uCount" parameter.</para>
         /// </summary>
-        False                                                  = 1,
+        False                           = 1,
         /// <summary>
         ///    <para>An overridden property was deleted. This value is
         ///       returned to signal that the original, non-overridden value has been restored as a
         ///       result of the deletion.</para>
         /// </summary>
-        ResetToDefault                                 = 0x40002,
+        ResetToDefault                  = 0x40002,
         /// <summary>
         ///    <para> The compared items (such as objects and classes)
         ///       are not identical.</para>
         /// </summary>
-        Different                              = 0x40003,
+        Different                       = 0x40003,
         /// <summary>
         ///    <para> A call timed out. This is not an
         ///       error condition; therefore, some results may have been returned.</para>
         /// </summary>
-        Timedout                                               = 0x40004,
+        Timedout                        = 0x40004,
         /// <summary>
         ///    <para> No more data is available from the enumeration; the 
         ///       user should terminate the enumeration. </para>
         /// </summary>
-        NoMoreData                                             = 0x40005,
+        NoMoreData                      = 0x40005,
         /// <summary>
         ///    <para> The operation was
         ///       canceled.</para>
         /// </summary>
-        OperationCanceled                              = 0x40006,
+        OperationCanceled               = 0x40006,
         /// <summary>
         ///    <para>A request is still in progress; however, the results are not
         ///       yet available.</para>
         /// </summary>
-        Pending                                        = 0x40007,
+        Pending                         = 0x40007,
         /// <summary>
         ///    <para> More than one copy of the same object was detected in 
         ///       the result set of an enumeration. </para>
         /// </summary>
-        DuplicateObjects                               = 0x40008,
+        DuplicateObjects                = 0x40008,
         /// <summary>
         ///    <para>The user did not receive all of the requested objects
         ///       because of inaccessible resources (other than security violations).</para>
         /// </summary>
-        PartialResults                                 = 0x40010,
+        PartialResults                  = 0x40010,
         /// <summary>
         ///    <para>The call failed.</para>
         /// </summary>
@@ -138,16 +138,16 @@ namespace System.Management
         ///    A provider referenced in the schema does not have a
         ///    corresponding registration.
         /// </summary>
-        ProviderNotFound                               = unchecked((int)0x80041011),
+        ProviderNotFound                = unchecked((int)0x80041011),
         /// <summary>
         ///    A provider referenced in the schema has an incorrect or
         ///    incomplete registration.
         /// </summary>
-        InvalidProviderRegistration            = unchecked((int)0x80041012),
+        InvalidProviderRegistration     = unchecked((int)0x80041012),
         /// <summary>
         ///    COM cannot locate a provider referenced in the schema.
         /// </summary>
-        ProviderLoadFailure                            = unchecked((int)0x80041013),
+        ProviderLoadFailure             = unchecked((int)0x80041013),
         /// <summary>
         ///  A component, such as a provider, failed to initialize for internal reasons. 
         /// </summary>
@@ -169,7 +169,7 @@ namespace System.Management
         /// <summary>
         ///    <para>The requested query language is not supported.</para>
         /// </summary>
-        InvalidQueryType                               = unchecked((int)0x80041018),
+        InvalidQueryType                = unchecked((int)0x80041018),
         /// <summary>
         /// <para>In a put operation, the <see langword='wbemChangeFlagCreateOnly'/>
         /// flag was specified, but the instance already exists.</para>
@@ -179,7 +179,7 @@ namespace System.Management
         ///    <para>The add operation cannot be performed on the qualifier 
         ///       because the owning object does not permit overrides.</para>
         /// </summary>
-        OverrideNotAllowed                             = unchecked((int)0x8004101A),
+        OverrideNotAllowed               = unchecked((int)0x8004101A),
         /// <summary>
         ///    <para> The user attempted to delete a qualifier that was not 
         ///       owned. The qualifier was inherited from a parent class. </para>
@@ -205,7 +205,7 @@ namespace System.Management
         ///       on a property that cannot be a key. The keys are specified in the class
         ///       definition for an object and cannot be altered on a per-instance basis.</para>
         /// </summary>
-        CannotBeKey                                            = unchecked((int)0x8004101F),
+        CannotBeKey                     = unchecked((int)0x8004101F),
         /// <summary>
         ///    <para>The current object is not a valid class definition.
         ///       Either it is incomplete, or it has not been registered with WMI using
@@ -229,21 +229,21 @@ namespace System.Management
         ///       as requesting a query that is too complex, retrieving an instance, creating or
         ///       updating a class, deleting a class, or enumerating a class. </para>
         /// </summary>
-        ProviderNotCapable                             = unchecked((int)0x80041024),
+        ProviderNotCapable               = unchecked((int)0x80041024),
         /// <summary>
         ///    <para>An attempt was made to make a change that would
         ///       invalidate a derived class.</para>
         /// </summary>
-        ClassHasChildren                               = unchecked((int)0x80041025),
+        ClassHasChildren                 = unchecked((int)0x80041025),
         /// <summary>
         ///    <para> An attempt has been made to delete or modify a class that 
         ///       has instances. </para>
         /// </summary>
-        ClassHasInstances                              = unchecked((int)0x80041026),
+        ClassHasInstances                = unchecked((int)0x80041026),
         /// <summary>
         ///    Reserved for future use.
         /// </summary>
-        QueryNotImplemented                            = unchecked((int)0x80041027),
+        QueryNotImplemented              = unchecked((int)0x80041027),
         /// <summary>
         ///    <para> A value of null was specified for a property that may
         ///       not be null, such as one that is marked by a <see langword='Key'/>, <see langword='Indexed'/>, or
@@ -254,25 +254,25 @@ namespace System.Management
         ///    <para> The value provided for a qualifier was not a 
         ///       legal qualifier type.</para>
         /// </summary>
-        InvalidQualifierType                   = unchecked((int)0x80041029),
+        InvalidQualifierType             = unchecked((int)0x80041029),
         /// <summary>
         ///    The CIM type specified for a property is not valid.
         /// </summary>
-        InvalidPropertyType                            = unchecked((int)0x8004102A),
+        InvalidPropertyType              = unchecked((int)0x8004102A),
         /// <summary>
         ///    <para> The request was made with an out-of-range value, or is 
         ///       incompatible with the type. </para>
         /// </summary>
-        ValueOutOfRange                                        = unchecked((int)0x8004102B),
+        ValueOutOfRange                  = unchecked((int)0x8004102B),
         /// <summary>
         ///    <para>An illegal attempt was made to make a class singleton, 
         ///       such as when the class is derived from a non-singleton class.</para>
         /// </summary>
-        CannotBeSingleton                              = unchecked((int)0x8004102C),
+        CannotBeSingleton                = unchecked((int)0x8004102C),
         /// <summary>
         ///    The CIM type specified is not valid.
         /// </summary>
-        InvalidCimType                                 = unchecked((int)0x8004102D),
+        InvalidCimType                   = unchecked((int)0x8004102D),
         /// <summary>
         ///    The requested method is not available.
         /// </summary>
@@ -281,7 +281,7 @@ namespace System.Management
         ///    <para> The parameters provided for the method are not valid. 
         ///    </para>
         /// </summary>
-        InvalidMethodParameters                        = unchecked((int)0x8004102F),
+        InvalidMethodParameters          = unchecked((int)0x8004102F),
         /// <summary>
         ///    There was an attempt to get qualifiers on a system
         ///    property.
@@ -316,133 +316,133 @@ namespace System.Management
         /// <summary>
         ///    A parameter was missing from the method call.
         /// </summary>
-        MissingParameterID                     = unchecked((int)0x80041036),
+        MissingParameterID              = unchecked((int)0x80041036),
         /// <summary>
         ///    A method parameter has an invalid <see langword='ID'/> qualifier.
         /// </summary>
-        InvalidParameterID                             = unchecked((int)0x80041037),
+        InvalidParameterID              = unchecked((int)0x80041037),
         /// <summary>
         /// <para> One or more of the method parameters have <see langword='ID'/> 
         /// qualifiers that are out of sequence. </para>
         /// </summary>
-        NonconsecutiveParameterIDs             = unchecked((int)0x80041038),
+        NonconsecutiveParameterIDs      = unchecked((int)0x80041038),
         /// <summary>
         /// <para> The return value for a method has an <see langword='ID'/> qualifier. 
         /// </para>
         /// </summary>
-        ParameterIDOnRetval                            = unchecked((int)0x80041039),
+        ParameterIDOnRetval             = unchecked((int)0x80041039),
         /// <summary>
         ///    The specified object path was invalid.
         /// </summary>
-        InvalidObjectPath                              = unchecked((int)0x8004103A),
+        InvalidObjectPath               = unchecked((int)0x8004103A),
         /// <summary>
         ///    <para> There is not enough free disk space to continue the 
         ///       operation. </para>
         /// </summary>
-        OutOfDiskSpace                                 = unchecked((int)0x8004103B),
+        OutOfDiskSpace                  = unchecked((int)0x8004103B),
         /// <summary>
         ///    <para> The supplied buffer was too small to hold all the objects 
         ///       in the enumerator or to read a string property. </para>
         /// </summary>
-        BufferTooSmall                                 = unchecked((int)0x8004103C),
+        BufferTooSmall                  = unchecked((int)0x8004103C),
         /// <summary>
         ///    The provider does not support the requested put
         ///    operation.
         /// </summary>
-        UnsupportedPutExtension                        = unchecked((int)0x8004103D),
+        UnsupportedPutExtension         = unchecked((int)0x8004103D),
         /// <summary>
         ///    <para> An object with an incorrect type or version was 
         ///       encountered during marshaling. </para>
         /// </summary>
-        UnknownObjectType                              = unchecked((int)0x8004103E),
+        UnknownObjectType               = unchecked((int)0x8004103E),
         /// <summary>
         ///    <para> A packet with an incorrect type or version was 
         ///       encountered during marshaling. </para>
         /// </summary>
-        UnknownPacketType                              = unchecked((int)0x8004103F),
+        UnknownPacketType               = unchecked((int)0x8004103F),
         /// <summary>
         ///    The packet has an unsupported version.
         /// </summary>
-        MarshalVersionMismatch                 = unchecked((int)0x80041040),
+        MarshalVersionMismatch          = unchecked((int)0x80041040),
         /// <summary>
         ///    <para>The packet is corrupted.</para>
         /// </summary>
-        MarshalInvalidSignature                        = unchecked((int)0x80041041),
+        MarshalInvalidSignature         = unchecked((int)0x80041041),
         /// <summary>
         ///    An attempt has been made to mismatch qualifiers, such as
         ///    putting [key] on an object instead of a property.
         /// </summary>
-        InvalidQualifier                               = unchecked((int)0x80041042),
+        InvalidQualifier                = unchecked((int)0x80041042),
         /// <summary>
         ///    A duplicate parameter has been declared in a CIM method.
         /// </summary>
-        InvalidDuplicateParameter              = unchecked((int)0x80041043),
+        InvalidDuplicateParameter       = unchecked((int)0x80041043),
         /// <summary>
         ///    <para> Reserved for future use. </para>
         /// </summary>
-        TooMuchData                                            = unchecked((int)0x80041044),
+        TooMuchData                     = unchecked((int)0x80041044),
         /// <summary>
         ///    <para>The delivery of an event has failed. The provider may 
         ///       choose to re-raise the event.</para>
         /// </summary>
-        ServerTooBusy                                  = unchecked((int)0x80041045),
+        ServerTooBusy                   = unchecked((int)0x80041045),
         /// <summary>
         ///    The specified flavor was invalid.
         /// </summary>
-        InvalidFlavor                                  = unchecked((int)0x80041046),
+        InvalidFlavor                   = unchecked((int)0x80041046),
         /// <summary>
         ///    <para> An attempt has been made to create a reference that is 
         ///       circular (for example, deriving a class from itself). </para>
         /// </summary>
-        CircularReference                              = unchecked((int)0x80041047),
+        CircularReference               = unchecked((int)0x80041047),
         /// <summary>
         ///    The specified class is not supported.
         /// </summary>
-        UnsupportedClassUpdate                 = unchecked((int)0x80041048),
+        UnsupportedClassUpdate          = unchecked((int)0x80041048),
         /// <summary>
         ///    <para> An attempt was made to change a key when instances or derived 
         ///       classes are already using the key. </para>
         /// </summary>
-        CannotChangeKeyInheritance             = unchecked((int)0x80041049),
+        CannotChangeKeyInheritance      = unchecked((int)0x80041049),
         /// <summary>
         ///    <para> An attempt was made to change an index when instances or derived 
         ///       classes are already using the index. </para>
         /// </summary>
-        CannotChangeIndexInheritance   = unchecked((int)0x80041050),
+        CannotChangeIndexInheritance    = unchecked((int)0x80041050),
         /// <summary>
         ///    <para> An attempt was made to create more properties than the 
         ///       current version of the class supports. </para>
         /// </summary>
-        TooManyProperties                              = unchecked((int)0x80041051),
+        TooManyProperties               = unchecked((int)0x80041051),
         /// <summary>
         ///    <para> A property was redefined with a conflicting type in a 
         ///       derived class. </para>
         /// </summary>
-        UpdateTypeMismatch                             = unchecked((int)0x80041052),
+        UpdateTypeMismatch              = unchecked((int)0x80041052),
         /// <summary>
         ///    <para> An attempt was made in a derived class to override a 
         ///       non-overrideable qualifier. </para>
         /// </summary>
-        UpdateOverrideNotAllowed               = unchecked((int)0x80041053),
+        UpdateOverrideNotAllowed        = unchecked((int)0x80041053),
         /// <summary>
         ///    <para> A method was redeclared with a conflicting signature in a 
         ///       derived class. </para>
         /// </summary>
-        UpdatePropagatedMethod                 = unchecked((int)0x80041054),
+        UpdatePropagatedMethod          = unchecked((int)0x80041054),
         /// <summary>
         ///    An attempt was made to execute a method not marked with
         ///    [implemented] in any relevant class.
         /// </summary>
-        MethodNotImplemented                   = unchecked((int)0x80041055),
+        MethodNotImplemented            = unchecked((int)0x80041055),
         /// <summary>
         ///    <para> An attempt was made to execute a method marked with 
         ///       [disabled]. </para>
         /// </summary>
-        MethodDisabled                         = unchecked((int)0x80041056),
+        MethodDisabled                  = unchecked((int)0x80041056),
         /// <summary>
         ///    <para> The refresher is busy with another operation. </para>
         /// </summary>
-        RefresherBusy                                  = unchecked((int)0x80041057),
+        RefresherBusy                   = unchecked((int)0x80041057),
         /// <summary>
         ///    <para> The filtering query is syntactically invalid. </para>
         /// </summary>
@@ -451,38 +451,38 @@ namespace System.Management
         ///    The FROM clause of a filtering query references a class
         ///    that is not an event class.
         /// </summary>
-        NotEventClass                                  = unchecked((int)0x80041059),
+        NotEventClass                   = unchecked((int)0x80041059),
         /// <summary>
         ///    A GROUP BY clause was used without the corresponding
         ///    GROUP WITHIN clause.
         /// </summary>
-        MissingGroupWithin                             = unchecked((int)0x8004105A),
+        MissingGroupWithin              = unchecked((int)0x8004105A),
         /// <summary>
         ///    A GROUP BY clause was used. Aggregation on all properties
         ///    is not supported.
         /// </summary>
-        MissingAggregationList                 = unchecked((int)0x8004105B),
+        MissingAggregationList          = unchecked((int)0x8004105B),
         /// <summary>
         ///    <para> Dot notation was used on a property that is not an 
         ///       embedded object. </para>
         /// </summary>
-        PropertyNotAnObject                            = unchecked((int)0x8004105C),
+        PropertyNotAnObject             = unchecked((int)0x8004105C),
         /// <summary>
         ///    A GROUP BY clause references a property that is an
         ///    embedded object without using dot notation.
         /// </summary>
-        AggregatingByObject                            = unchecked((int)0x8004105D),
+        AggregatingByObject             = unchecked((int)0x8004105D),
         /// <summary>
         ///    An event provider registration query
         ///    (<see langword='__EventProviderRegistration'/>) did not specify the classes for which
         ///    events were provided.
         /// </summary>
-        UninterpretableProviderQuery   = unchecked((int)0x8004105F),
+        UninterpretableProviderQuery    = unchecked((int)0x8004105F),
         /// <summary>
         ///    <para> An request was made to back up or restore the repository 
         ///       while WinMgmt.exe was using it. </para>
         /// </summary>
-        BackupRestoreWinmgmtRunning            = unchecked((int)0x80041060),
+        BackupRestoreWinmgmtRunning     = unchecked((int)0x80041060),
         /// <summary>
         ///    <para> The asynchronous delivery queue overflowed from the 
         ///       event consumer being too slow. </para>
@@ -492,7 +492,7 @@ namespace System.Management
         ///    The operation failed because the client did not have the
         ///    necessary security privilege.
         /// </summary>
-        PrivilegeNotHeld                               = unchecked((int)0x80041062),
+        PrivilegeNotHeld                = unchecked((int)0x80041062),
         /// <summary>
         ///    <para>The operator is not valid for this property type.</para>
         /// </summary>
@@ -507,27 +507,27 @@ namespace System.Management
         ///    <para> The class was made abstract when its base class is not 
         ///       abstract. </para>
         /// </summary>
-        CannotBeAbstract                               = unchecked((int)0x80041065),
+        CannotBeAbstract                = unchecked((int)0x80041065),
         /// <summary>
         ///    <para> An amended object was used in a put operation without the 
         ///       WBEM_FLAG_USE_AMENDED_QUALIFIERS flag being specified. </para>
         /// </summary>
-        AmendedObject                                  = unchecked((int)0x80041066),
+        AmendedObject                   = unchecked((int)0x80041066),
         /// <summary>
         ///    The client was not retrieving objects quickly enough from
         ///    an enumeration.
         /// </summary>
-        ClientTooSlow                                  = unchecked((int)0x80041067),
+        ClientTooSlow                   = unchecked((int)0x80041067),
 
         /// <summary>
         ///    <para> The provider registration overlaps with the system event 
         ///       domain. </para>
         /// </summary>
-        RegistrationTooBroad                   = unchecked((int)0x80042001),
+        RegistrationTooBroad            = unchecked((int)0x80042001),
         /// <summary>
         ///    <para> A WITHIN clause was not used in this query. </para>
         /// </summary>
-        RegistrationTooPrecise                 = unchecked((int)0x80042002)
+        RegistrationTooPrecise          = unchecked((int)0x80042002)
     }
 
     /// <summary>
@@ -589,8 +589,8 @@ namespace System.Management
     [Serializable]
     public class ManagementException : SystemException 
     {
-        private ManagementBaseObject   errorObject = null;
-        private ManagementStatus               errorCode = 0;
+        private ManagementBaseObject errorObject = null;
+        private ManagementStatus     errorCode = 0;
 
         internal static void ThrowWithExtendedInfo(ManagementStatus errorCode)
         {
@@ -704,7 +704,7 @@ namespace System.Management
         /// block that handles the inner exception.</param>
         /// </summary>
         public ManagementException(string message,Exception innerException):this(innerException, message, null)
-        {      
+        {
             // if the exception passed is not a ManagementException, then initialize the ErrorCode to Failed
             if (!(innerException is ManagementException))
                 errorCode = ManagementStatus.Failed;
index 1280a3a..47d86e5 100644 (file)
@@ -7,7 +7,7 @@ using System.Runtime.Serialization;
 
 namespace System.Management 
 {
-    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//        
+    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//
     /// <summary>
     ///    <para> Represents a collection of named values
     ///       suitable for use as context information to WMI operations. The
@@ -172,7 +172,7 @@ namespace System.Management
         /// </summary>
         /// <param name=' name'>The name of the value to be returned.</param>
         /// <value>
-        /// <para>An <see cref='System.Object'/> containing the 
+        /// <para>An <see cref='object'/> containing the 
         ///    value of the specified item in this collection.</para>
         /// </value>
         public object this[string name] 
index 0f7761e..d9801e9 100644 (file)
@@ -2427,7 +2427,7 @@ namespace System.Management
         /// </returns>
         /// <remarks>
         ///    <para> Gets the object containing the input parameters to a 
-        ///       method, and then fills in the values and passes the object to the <see cref='System.Management.ManagementObject.InvokeMethod(String, ManagementBaseObject, InvokeMethodOptions)'/> call.</para>
+        ///       method, and then fills in the values and passes the object to the <see cref='System.Management.ManagementObject.InvokeMethod(string, ManagementBaseObject, InvokeMethodOptions)'/> call.</para>
         /// </remarks>
         public ManagementBaseObject GetMethodParameters(
             string methodName)
index a615066..658ce95 100644 (file)
@@ -1153,7 +1153,7 @@ namespace System.Management
         /// <para>Initializes a new instance of the <see cref='System.Management.InvokeMethodOptions'/> class.</para>
         /// </overload>
         /// <summary>
-        /// <para>Initializes a new instance of the <see cref='System.Management.InvokeMethodOptions'/> class for the <see cref='System.Management.ManagementObject.InvokeMethod(String, ManagementBaseObject, InvokeMethodOptions) '/> operation, using default values.
+        /// <para>Initializes a new instance of the <see cref='System.Management.InvokeMethodOptions'/> class for the <see cref='System.Management.ManagementObject.InvokeMethod(string, ManagementBaseObject, InvokeMethodOptions) '/> operation, using default values.
         ///    This is the default constructor.</para>
         /// </summary>
         public InvokeMethodOptions() : base () {}
index 3a3486a..aa94c57 100644 (file)
@@ -10,7 +10,7 @@ using System.ComponentModel;
 
 namespace System.Management
 {
-    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//        
+    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//
     /// <summary>
     ///    <para> Provides an abstract base class for all management query objects.</para>
     /// </summary>
@@ -23,7 +23,7 @@ namespace System.Management
     public abstract class ManagementQuery : ICloneable
     {
         internal const string DEFAULTQUERYLANGUAGE = "WQL";
-        internal const string TokenSelect = "select "; // Keep trailing space char.
+        internal const string TokenSelect = "select ";    // Keep trailing space char.
 
         //Used when any public property on this object is changed, to signal
         //to the containing object that it needs to be refreshed.
@@ -78,7 +78,7 @@ namespace System.Management
             get {return (null != queryString) ? queryString : string.Empty;}
             set {
                 if (queryString != value) {
-                    ParseQuery (value);        // this may throw
+                    ParseQuery (value); // this may throw
                     queryString = value;
                     FireIdentifierChanged ();
                 }
@@ -116,7 +116,7 @@ namespace System.Management
         internal static void ParseToken (ref string q, string token, string op, ref bool bTokenFound, ref string tokenValue)
         {
             if (bTokenFound)
-                throw new ArgumentException (SR.InvalidQueryDuplicatedToken);  // Invalid query - duplicate token
+                throw new ArgumentException (SR.InvalidQueryDuplicatedToken);    // Invalid query - duplicate token
 
             bTokenFound = true;
             q = q.Remove (0, token.Length).TrimStart (null);
@@ -125,20 +125,20 @@ namespace System.Management
             if (op != null)
             {
                 if (0 != q.IndexOf(op, StringComparison.Ordinal))
-                    throw new ArgumentException(SR.InvalidQuery);      // Invalid query
+                    throw new ArgumentException(SR.InvalidQuery);    // Invalid query
 
                 // Strip off the op and any leading WS
                 q = q.Remove(0, op.Length).TrimStart(null);
             }
 
             if (0 == q.Length)
-                throw new ArgumentException (SR.InvalidQueryNullToken);                // Invalid query - token has no value
+                throw new ArgumentException (SR.InvalidQueryNullToken);        // Invalid query - token has no value
             
             // Next token should be the token value - look for terminating WS 
             // or end of string
             int i;
             if (-1 == (i = q.IndexOf (' ')))
-                i = q.Length;                  // No WS => consume entire string
+                i = q.Length;            // No WS => consume entire string
                 
             tokenValue = q.Substring (0, i);
             q = q.Remove (0, tokenValue.Length).TrimStart(null);
@@ -147,7 +147,7 @@ namespace System.Management
         internal static void ParseToken (ref string q, string token, ref bool bTokenFound)
         {
             if (bTokenFound)
-                throw new ArgumentException (SR.InvalidQueryDuplicatedToken);  // Invalid query - duplicate token
+                throw new ArgumentException (SR.InvalidQueryDuplicatedToken);    // Invalid query - duplicate token
 
             bTokenFound = true;
             q = q.Remove (0, token.Length).TrimStart (null);
@@ -156,7 +156,7 @@ namespace System.Management
     }//ManagementQuery
 
 
-    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//        
+    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//
     /// <summary>
     ///    <para> Represents a management query that returns instances or classes.</para>
     /// </summary>
@@ -248,7 +248,7 @@ namespace System.Management
     }//ObjectQuery
 
 
-    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//        
+    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//
     /// <summary>
     ///    <para> Represents a WMI event query.</para>
     /// </summary>
@@ -459,7 +459,7 @@ namespace System.Management
     }//EventQuery
 
 
-    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//        
+    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//
     /// <summary>
     ///    <para> Represents a WMI data query in WQL format.</para>
     /// </summary>
@@ -559,7 +559,7 @@ namespace System.Management
 
 
     
-    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//        
+    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//
     /// <summary>
     ///    <para> Represents a WQL SELECT data query.</para>
     /// </summary>
@@ -661,7 +661,7 @@ namespace System.Management
                 {
                     // Looks to be a query - do further checking.
                     //
-                    QueryString = queryOrClassName;            // Parse/validate; may throw.
+                    QueryString = queryOrClassName;        // Parse/validate; may throw.
                 }
                 else
                 {
@@ -1074,9 +1074,9 @@ namespace System.Management
 
                     // Must be some white space next
                     if ((0 == q.Length) || !char.IsWhiteSpace (q[0]))
-                        throw new ArgumentException(SR.InvalidQuery);  // Invalid query
+                        throw new ArgumentException(SR.InvalidQuery);    // Invalid query
                 
-                    q = q.TrimStart(null);     // Remove the leading whitespace
+                    q = q.TrimStart(null);    // Remove the leading whitespace
 
                     condition = q;
                 }
@@ -1119,7 +1119,7 @@ namespace System.Management
     }//SelectQuery
 
     
-    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//        
+    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//
     /// <summary>
     ///    <para> Represents a WQL ASSOCIATORS OF data query. 
     ///       It can be used for both instances and schema queries.</para>
@@ -1254,7 +1254,7 @@ namespace System.Management
                 {
                     // Looks to be a query - do further checking.
                     //
-                    QueryString = queryOrSourceObject; // Parse/validate; may throw.
+                    QueryString = queryOrSourceObject;    // Parse/validate; may throw.
                 }
                 else
                 {
@@ -1641,34 +1641,34 @@ namespace System.Management
 
             //Find "associators" clause
             if (0 != string.Compare(q, 0, TokenAssociators, 0, TokenAssociators.Length, StringComparison.OrdinalIgnoreCase))
-                throw new ArgumentException(SR.InvalidQuery,"associators");    // Invalid query
+                throw new ArgumentException(SR.InvalidQuery,"associators");    // Invalid query
             
             // Strip off the clause
             q = q.Remove(0, TokenAssociators.Length);
 
             // Must be some white space next
             if ((0 == q.Length) || !char.IsWhiteSpace (q[0]))
-                throw new ArgumentException(SR.InvalidQuery);  // Invalid query
+                throw new ArgumentException(SR.InvalidQuery);    // Invalid query
             
-            q = q.TrimStart(null);     // Remove the leading whitespace
+            q = q.TrimStart(null);    // Remove the leading whitespace
 
             // Next token should be "of"
             if (0 != string.Compare(q, 0, TokenOf, 0, TokenOf.Length, StringComparison.OrdinalIgnoreCase))
-                throw new ArgumentException(SR.InvalidQuery,"of");     // Invalid query
+                throw new ArgumentException(SR.InvalidQuery,"of");    // Invalid query
             
             // Strip off the clause and leading WS
             q = q.Remove(0, TokenOf.Length).TrimStart (null);
 
             // Next character should be "{"
             if (0 != q.IndexOf('{'))
-                throw new ArgumentException(SR.InvalidQuery);  // Invalid query
+                throw new ArgumentException(SR.InvalidQuery);    // Invalid query
 
             // Strip off the "{" and any leading WS
             q = q.Remove(0, 1).TrimStart(null);
 
             // Next item should be the source object
             if (-1 == (i = q.IndexOf('}')))
-                throw new ArgumentException(SR.InvalidQuery);  // Invalid query
+                throw new ArgumentException(SR.InvalidQuery);    // Invalid query
 
             tempSourceObject = q.Substring(0, i).TrimEnd(null);
             q = q.Remove(0, i+1).TrimStart(null);
@@ -1678,15 +1678,15 @@ namespace System.Management
             {
                 // Next should be the "where" clause
                 if (0 != string.Compare (q, 0, TokenWhere, 0, TokenWhere.Length, StringComparison.OrdinalIgnoreCase))
-                    throw new ArgumentException(SR.InvalidQuery,"where");      // Invalid query
+                    throw new ArgumentException(SR.InvalidQuery,"where");    // Invalid query
                 
                 q = q.Remove (0, TokenWhere.Length);
 
                 // Must be some white space next
                 if ((0 == q.Length) || !char.IsWhiteSpace (q[0]))
-                    throw new ArgumentException(SR.InvalidQuery);      // Invalid query
+                    throw new ArgumentException(SR.InvalidQuery);    // Invalid query
                 
-                q = q.TrimStart(null); // Remove the leading whitespace
+                q = q.TrimStart(null);    // Remove the leading whitespace
 
                 // Remaining tokens can appear in any order
                 bool bResultClassFound = false;
@@ -1724,9 +1724,9 @@ namespace System.Management
                         tempClassDefsOnly = true;
                     }
                     else if (0 == q.Length)
-                        break;         // done
+                        break;        // done
                     else 
-                        throw new ArgumentException(SR.InvalidQuery);          // Unrecognized token
+                        throw new ArgumentException(SR.InvalidQuery);        // Unrecognized token
                 }
 
                 //Can't have both classDefsOnly and schemaOnly
@@ -1771,7 +1771,7 @@ namespace System.Management
     }//RelatedObjectQuery
 
 
-    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//        
+    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//
     /// <summary>
     ///    <para> Represents a WQL REFERENCES OF data query.</para>
     /// </summary>
@@ -1881,7 +1881,7 @@ namespace System.Management
                 {
                     // Looks to be a query - do further checking.
                     //
-                    QueryString = queryOrSourceObject; // Parse/validate; may throw.
+                    QueryString = queryOrSourceObject;    // Parse/validate; may throw.
                 }
                 else
                 {
@@ -2156,34 +2156,34 @@ namespace System.Management
 
             //Find "references" clause
             if (0 != string.Compare(q, 0, TokenReferences, 0, TokenReferences.Length, StringComparison.OrdinalIgnoreCase))
-                throw new ArgumentException(SR.InvalidQuery,"references");     // Invalid query
+                throw new ArgumentException(SR.InvalidQuery,"references");    // Invalid query
             
             // Strip off the clause
             q = q.Remove(0, TokenReferences.Length);
 
             // Must be some white space next
             if ((0 == q.Length) || !char.IsWhiteSpace (q[0]))
-                throw new ArgumentException(SR.InvalidQuery);  // Invalid query
+                throw new ArgumentException(SR.InvalidQuery);    // Invalid query
             
-            q = q.TrimStart(null);     // Remove the leading whitespace
+            q = q.TrimStart(null);    // Remove the leading whitespace
 
             // Next token should be "of"
             if (0 != string.Compare(q, 0, TokenOf, 0, TokenOf.Length, StringComparison.OrdinalIgnoreCase))
-                throw new ArgumentException(SR.InvalidQuery,"of");     // Invalid query
+                throw new ArgumentException(SR.InvalidQuery,"of");    // Invalid query
             
             // Strip off the clause and leading WS
             q = q.Remove(0, TokenOf.Length).TrimStart (null);
 
             // Next character should be "{"
             if (0 != q.IndexOf('{'))
-                throw new ArgumentException(SR.InvalidQuery);  // Invalid query
+                throw new ArgumentException(SR.InvalidQuery);    // Invalid query
 
             // Strip off the "{" and any leading WS
             q = q.Remove(0, 1).TrimStart(null);
 
             // Next item should be the source object
             if (-1 == (i = q.IndexOf('}')))
-                throw new ArgumentException(SR.InvalidQuery);  // Invalid query
+                throw new ArgumentException(SR.InvalidQuery);    // Invalid query
 
             tempSourceObject = q.Substring(0, i).TrimEnd(null);
             q = q.Remove(0, i+1).TrimStart(null);
@@ -2193,15 +2193,15 @@ namespace System.Management
             {
                 // Next should be the "where" clause
                 if (0 != string.Compare (q, 0, TokenWhere, 0, TokenWhere.Length, StringComparison.OrdinalIgnoreCase))
-                    throw new ArgumentException(SR.InvalidQuery,"where");      // Invalid query
+                    throw new ArgumentException(SR.InvalidQuery,"where");    // Invalid query
                 
                 q = q.Remove (0, TokenWhere.Length);
 
                 // Must be some white space next
                 if ((0 == q.Length) || !char.IsWhiteSpace (q[0]))
-                    throw new ArgumentException(SR.InvalidQuery);      // Invalid query
+                    throw new ArgumentException(SR.InvalidQuery);    // Invalid query
                 
-                q = q.TrimStart(null); // Remove the leading whitespace
+                q = q.TrimStart(null);    // Remove the leading whitespace
 
                 // Remaining tokens can appear in any order
                 bool bResultClassFound = false;
@@ -2230,9 +2230,9 @@ namespace System.Management
                         tempSchemaOnly = true;
                     }
                     else if (0 == q.Length)
-                        break;         // done
+                        break;        // done
                     else 
-                        throw new ArgumentException(SR.InvalidQuery);          // Unrecognized token
+                        throw new ArgumentException(SR.InvalidQuery);        // Unrecognized token
                 }
 
                 //Can't have both classDefsOnly and schemaOnly
@@ -2272,7 +2272,7 @@ namespace System.Management
     }//RelationshipQuery
 
 
-    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//        
+    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//    
     /// <summary>
     ///    <para> Represents a WMI event query in WQL format.</para>
     /// </summary>
@@ -2470,7 +2470,7 @@ namespace System.Management
                 //
                 if (queryOrEventClassName.TrimStart().StartsWith(TokenSelectAll, StringComparison.OrdinalIgnoreCase))
                 {
-                    QueryString = queryOrEventClassName;       // Parse/validate; may throw.
+                    QueryString = queryOrEventClassName;    // Parse/validate; may throw.
                 }
                 else
                 {
@@ -2957,7 +2957,7 @@ namespace System.Management
             }
 
             //Select clause
-            string s = TokenSelectAll; //no property list allowed here...
+            string s = TokenSelectAll;    //no property list allowed here...
 
             //From clause
             s = s + "from " + eventClassName;
@@ -3024,7 +3024,7 @@ namespace System.Management
             string keyword = TokenSelect;
             if ((q.Length < keyword.Length) || (0 != string.Compare (q, 0, keyword, 0, keyword.Length, StringComparison.OrdinalIgnoreCase)))
                 throw new ArgumentException(SR.InvalidQuery);
-            q =        q.Remove(0, keyword.Length).TrimStart(null);
+            q =    q.Remove(0, keyword.Length).TrimStart(null);
 
             if (!q.StartsWith("*", StringComparison.Ordinal)) 
                     throw new ArgumentException(SR.InvalidQuery,"*");
@@ -3116,7 +3116,7 @@ namespace System.Management
             keyword = "where ";
             if ((w.Length >= keyword.Length) && (0 == string.Compare (w, 0, keyword, 0, keyword.Length, StringComparison.OrdinalIgnoreCase))) //where clause exists
             {
-                condition = w.Substring(keyword.Length);                               
+                condition = w.Substring(keyword.Length);                
             }
 
         }//ParseQuery()
@@ -3219,7 +3219,7 @@ namespace System.Management
                 {
                     return new InstanceDescriptor(ctor, new object[] {obj.QueryString});
                 }
-            }                  
+            }
         
             if (value is ObjectQuery && destinationType == typeof(InstanceDescriptor)) 
             {
index 9250d91..f549ff1 100644 (file)
@@ -30,7 +30,7 @@ namespace System.Management
         }
     }
 
-    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//        
+    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//
     /// <summary>
     ///    <para> Represents information about a WMI property.</para>
     /// </summary>
@@ -100,7 +100,7 @@ namespace System.Management
         //This private function is used to refresh the information from the Wmi object before returning the requested data
         private void RefreshPropertyInfo()
         {
-            propertyValue = null;      // Needed so we don't leak this in/out parameter...
+            propertyValue = null;    // Needed so we don't leak this in/out parameter...
 
             int status = parent.wbemObject.Get_(propertyName, 0, ref propertyValue, ref propertyType, ref propertyFlavor);
 
@@ -223,7 +223,7 @@ namespace System.Management
                 if (status < 0)
                 {
                     if (status == (int)tag_WBEMSTATUS.WBEM_E_INVALID_OBJECT)
-                        className = string.Empty;      // Interpret as an unspecified property - return ""
+                        className = string.Empty;    // Interpret as an unspecified property - return ""
                     else if ((status & 0xfffff000) == 0x80041000)
                         ManagementException.ThrowWithExtendedInfo((ManagementStatus)status);
                     else
@@ -439,7 +439,7 @@ namespace System.Management
                                 wmiValue = new int [length];
                                 for (int i = 0; i < length; i++)
                                     ((int[])(wmiValue))[i] = Convert.ToInt32(valArray.GetValue(i),(IFormatProvider)culInfo.GetFormat(typeof(int)));
-                            }                          
+                            }                
                             break;
 
                         case CimType.UInt32:
@@ -451,13 +451,13 @@ namespace System.Management
                         case CimType.SInt64:
                             wmiValue = new string [length];
                             for (int i = 0; i < length; i++)
-                                ((string[])(wmiValue))[i] = (Convert.ToInt64(valArray.GetValue(i),(IFormatProvider)culInfo.GetFormat(typeof(System.Int64)))).ToString((IFormatProvider)culInfo.GetFormat(typeof(long)));
+                                ((string[])(wmiValue))[i] = (Convert.ToInt64(valArray.GetValue(i),(IFormatProvider)culInfo.GetFormat(typeof(long)))).ToString((IFormatProvider)culInfo.GetFormat(typeof(long)));
                             break;
 
                         case CimType.UInt64:
                             wmiValue = new string [length];
                             for (int i = 0; i < length; i++)
-                                ((string[])(wmiValue))[i] = (Convert.ToUInt64(valArray.GetValue(i),(IFormatProvider)culInfo.GetFormat(typeof(System.UInt64)))).ToString((IFormatProvider)culInfo.GetFormat(typeof(ulong)));
+                                ((string[])(wmiValue))[i] = (Convert.ToUInt64(valArray.GetValue(i),(IFormatProvider)culInfo.GetFormat(typeof(ulong)))).ToString((IFormatProvider)culInfo.GetFormat(typeof(ulong)));
                             break;
 
                         case CimType.Real32:
@@ -468,7 +468,7 @@ namespace System.Management
                                 wmiValue = new float [length];
                                 for (int i = 0; i < length; i++)
                                     ((float[])(wmiValue))[i] = Convert.ToSingle(valArray.GetValue(i),(IFormatProvider)culInfo.GetFormat(typeof(float)));
-                            }                          
+                            }                
                             break;
 
                         case CimType.Real64:
@@ -479,7 +479,7 @@ namespace System.Management
                                 wmiValue = new double [length];
                                 for (int i = 0; i < length; i++)
                                     ((double[])(wmiValue))[i] = Convert.ToDouble(valArray.GetValue(i),(IFormatProvider)culInfo.GetFormat(typeof(double)));
-                            }                          
+                            }                
                             break;
 
                         case CimType.Char16: 
@@ -555,11 +555,11 @@ namespace System.Management
                             break;
 
                         case CimType.SInt64:
-                            wmiValue = (Convert.ToInt64(val,(IFormatProvider)culInfo.GetFormat(typeof(System.Int64)))).ToString((IFormatProvider)culInfo.GetFormat(typeof(long)));
+                            wmiValue = (Convert.ToInt64(val,(IFormatProvider)culInfo.GetFormat(typeof(long)))).ToString((IFormatProvider)culInfo.GetFormat(typeof(long)));
                             break;
 
                         case CimType.UInt64:
-                            wmiValue = (Convert.ToUInt64(val,(IFormatProvider)culInfo.GetFormat(typeof(System.UInt64)))).ToString((IFormatProvider)culInfo.GetFormat(typeof(ulong)));
+                            wmiValue = (Convert.ToUInt64(val,(IFormatProvider)culInfo.GetFormat(typeof(ulong)))).ToString((IFormatProvider)culInfo.GetFormat(typeof(ulong)));
                             break;
 
                         case CimType.Real32:
@@ -632,7 +632,7 @@ namespace System.Management
                             wmiValue = new short[length];
 
                             for (int i = 0; i < length; i++)
-                                ((short[])wmiValue) [i] = ((IConvertible)((System.Byte)(arrayValue[i]))).ToInt16(null);
+                                ((short[])wmiValue) [i] = ((IConvertible)((byte)(arrayValue[i]))).ToInt16(null);
                         }
                         else if (elementType == typeof(sbyte))
                         {
@@ -642,13 +642,13 @@ namespace System.Management
                             wmiValue = new short[length];
 
                             for (int i = 0; i < length; i++)
-                                ((short[])wmiValue) [i] = ((IConvertible)((System.SByte)(arrayValue[i]))).ToInt16(null);
+                                ((short[])wmiValue) [i] = ((IConvertible)((sbyte)(arrayValue[i]))).ToInt16(null);
                         }
                         else if (elementType == typeof(bool))
                         {
                             type = CimType.Boolean;
                             wmiValue = (bool[])val;
-                        }                                      
+                        }
                         else if (elementType == typeof(ushort))
                         {
                             ushort[] arrayValue = (ushort[])val;
@@ -657,7 +657,7 @@ namespace System.Management
                             wmiValue = new int[length];
 
                             for (int i = 0; i < length; i++)
-                                ((int[])wmiValue) [i] = ((IConvertible)((System.UInt16)(arrayValue[i]))).ToInt32(null);
+                                ((int[])wmiValue) [i] = ((IConvertible)((ushort)(arrayValue[i]))).ToInt32(null);
                         }
                         else if (elementType == typeof(short))
                         {
@@ -677,7 +677,7 @@ namespace System.Management
                             wmiValue = new string[length];
 
                             for (int i = 0; i < length; i++)
-                                ((string[])wmiValue) [i] = ((System.UInt32)(arrayValue[i])).ToString((IFormatProvider)culInfo.GetFormat(typeof(uint)));
+                                ((string[])wmiValue) [i] = ((uint)(arrayValue[i])).ToString((IFormatProvider)culInfo.GetFormat(typeof(uint)));
                         }
                         else if (elementType == typeof(ulong))
                         {
@@ -687,7 +687,7 @@ namespace System.Management
                             wmiValue = new string[length];
 
                             for (int i = 0; i < length; i++)
-                                ((string[])wmiValue) [i] = ((System.UInt64)(arrayValue[i])).ToString((IFormatProvider)culInfo.GetFormat(typeof(ulong)));
+                                ((string[])wmiValue) [i] = ((ulong)(arrayValue[i])).ToString((IFormatProvider)culInfo.GetFormat(typeof(ulong)));
                         }
                         else if (elementType == typeof(long))
                         {
@@ -717,7 +717,7 @@ namespace System.Management
                             wmiValue = new short[length];
 
                             for (int i = 0; i < length; i++)
-                                ((short[])wmiValue) [i] = ((IConvertible)((System.Char)(arrayValue[i]))).ToInt16(null);
+                                ((short[])wmiValue) [i] = ((IConvertible)((char)(arrayValue[i]))).ToInt16(null);
                         }
                     }
                     else
@@ -746,12 +746,12 @@ namespace System.Management
                         }
                     }
                 }
-                else   // Non-array values
+                else    // Non-array values
                 {
                     if (valueType == typeof(ushort))
                     {
                         type = CimType.UInt16;
-                        wmiValue = ((IConvertible)((System.UInt16)val)).ToInt32(null);
+                        wmiValue = ((IConvertible)((ushort)val)).ToInt32(null);
                     }
                     else if (valueType == typeof(uint))
                     {
@@ -764,12 +764,12 @@ namespace System.Management
                     else if (valueType == typeof(ulong))
                     {
                         type = CimType.UInt64;
-                        wmiValue = ((System.UInt64)val).ToString((IFormatProvider)culInfo.GetFormat(typeof(ulong)));
+                        wmiValue = ((ulong)val).ToString((IFormatProvider)culInfo.GetFormat(typeof(ulong)));
                     }
                     else if (valueType == typeof(sbyte))
                     {
                         type = CimType.SInt8;
-                        wmiValue = ((IConvertible)((System.SByte)val)).ToInt16(null);
+                        wmiValue = ((IConvertible)((sbyte)val)).ToInt16(null);
                     }
                     else if (valueType == typeof(byte))
                     {
@@ -809,7 +809,7 @@ namespace System.Management
                     else if (valueType == typeof(char))
                     {
                         type = CimType.Char16;
-                        wmiValue = ((IConvertible)((System.Char)val)).ToInt16(null);
+                        wmiValue = ((IConvertible)((char)val)).ToInt16(null);
                     }
                     else if (valueType == typeof(string))
                     {
index 6c60967..9d08f35 100644 (file)
@@ -7,7 +7,7 @@ using System.Runtime.InteropServices;
 
 namespace System.Management
 {
-    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//        
+    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//
     /// <summary>
     ///    <para> Represents the set of properties of a WMI object.</para>
     /// </summary>
@@ -172,7 +172,7 @@ namespace System.Management
         /// <param name=' index'>The index in the destination array from which to start copying.</param>
         public void CopyTo(PropertyData[] propertyArray, int index)
         {
-            CopyTo((Array)propertyArray, index);       
+            CopyTo((Array)propertyArray, index);
         }
         //
         // IEnumerable
index e57df37..f200040 100644 (file)
@@ -7,7 +7,7 @@ using System.Globalization;
 
 namespace System.Management
 {
-    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//        
+    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//
     /// <summary>
     ///    <para> Contains information about a WMI qualifier.</para>
     /// </summary>
@@ -55,7 +55,7 @@ namespace System.Management
         private int qualifierFlavor;
         private IWbemQualifierSetFreeThreaded qualifierSet;
 
-        internal QualifierData(ManagementBaseObject parent, string propName, string qualName, QualifierType type)              
+        internal QualifierData(ManagementBaseObject parent, string propName, string qualName, QualifierType type)
         {
             this.parent = parent;
             this.propertyOrMethodName = propName;
index e689d64..8814b4d 100644 (file)
@@ -7,7 +7,7 @@ using System.Runtime.InteropServices;
 
 namespace System.Management
 {
-    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//        
+    //CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC//
     /// <summary>
     /// <para> Represents a collection of <see cref='System.Management.QualifierData'/> objects.</para>
     /// </summary>
@@ -83,8 +83,8 @@ namespace System.Management
         /// </summary>
         private IWbemQualifierSetFreeThreaded GetTypeQualifierSet(QualifierType qualifierSetType)
         {
-            IWbemQualifierSetFreeThreaded qualifierSet = null;
-            int status                                         = (int)ManagementStatus.NoError;
+            IWbemQualifierSetFreeThreaded qualifierSet    = null;
+            int status                        = (int)ManagementStatus.NoError;
 
             switch (qualifierSetType) 
             {
@@ -98,7 +98,7 @@ namespace System.Management
                     status = parent.wbemObject.GetMethodQualifierSet_(propertyOrMethodName, out qualifierSet);
                     break;
                 default :
-                    throw new ManagementException(ManagementStatus.Unexpected, null, null);    // Is this the best fit error ??
+                    throw new ManagementException(ManagementStatus.Unexpected, null, null);    // Is this the best fit error ??
             }
 
             if (status < 0)
@@ -315,13 +315,13 @@ namespace System.Management
             internal QualifierDataEnumerator(ManagementBaseObject parent, string propertyOrMethodName, 
                                                         QualifierType qualifierType)
             {
-                this.parent                                            = parent;
-                this.propertyOrMethodName              = propertyOrMethodName;
-                this.qualifierType                             = qualifierType;
-                this.qualifierNames                            = null;
+                this.parent               = parent;
+                this.propertyOrMethodName = propertyOrMethodName;
+                this.qualifierType        = qualifierType;
+                this.qualifierNames       = null;
 
-                IWbemQualifierSetFreeThreaded qualifierSet     = null;
-                int status                                             = (int)ManagementStatus.NoError;
+                IWbemQualifierSetFreeThreaded qualifierSet = null;
+                int status = (int)ManagementStatus.NoError;
 
                 switch (qualifierType) 
                 {
@@ -335,13 +335,13 @@ namespace System.Management
                         status = parent.wbemObject.GetMethodQualifierSet_(propertyOrMethodName, out qualifierSet);
                         break;
                     default :
-                        throw new ManagementException(ManagementStatus.Unexpected, null, null);        // Is this the best fit error ??
+                        throw new ManagementException(ManagementStatus.Unexpected, null, null);    // Is this the best fit error ??
                 }
 
                 // If we got an error code back, assume there are NO qualifiers for this object/property/method
                 if(status < 0)
                 {
-                    qualifierNames = Array.Empty<String>();
+                    qualifierNames = Array.Empty<string>();
                 }
                 else
                 {
index a9cd0c5..2809064 100644 (file)
@@ -643,7 +643,7 @@ namespace System.Management
             PublicNamesUsed.Add("Boolean","System.Boolean");
             PublicNamesUsed.Add("ValueType", "System.ValueType");
             PublicNamesUsed.Add("Events1", "Events");
-            PublicNamesUsed.Add("Component1", "Component");            
+            PublicNamesUsed.Add("Component1", "Component");
 
             //Initialize the Private Members
             PrivateNamesUsed.Add("SystemPropertiesObject","PrivateSystemProperties");    
index 7dc5b84..53c6329 100644 (file)
@@ -56,9 +56,9 @@ namespace System.Buffers
         }
 
         /// <summary>
-        /// Reads an <see cref="Int16"/> as little endian.
+        /// Reads an <see cref="short"/> as little endian.
         /// </summary>
-        /// <returns>False if there wasn't enough data for an <see cref="Int16"/>.</returns>
+        /// <returns>False if there wasn't enough data for an <see cref="short"/>.</returns>
         public static bool TryReadLittleEndian(ref this SequenceReader<byte> reader, out short value)
         {
             if (BitConverter.IsLittleEndian)
@@ -70,9 +70,9 @@ namespace System.Buffers
         }
 
         /// <summary>
-        /// Reads an <see cref="Int16"/> as big endian.
+        /// Reads an <see cref="short"/> as big endian.
         /// </summary>
-        /// <returns>False if there wasn't enough data for an <see cref="Int16"/>.</returns>
+        /// <returns>False if there wasn't enough data for an <see cref="short"/>.</returns>
         public static bool TryReadBigEndian(ref this SequenceReader<byte> reader, out short value)
         {
             if (!BitConverter.IsLittleEndian)
@@ -95,9 +95,9 @@ namespace System.Buffers
         }
 
         /// <summary>
-        /// Reads an <see cref="Int32"/> as little endian.
+        /// Reads an <see cref="int"/> as little endian.
         /// </summary>
-        /// <returns>False if there wasn't enough data for an <see cref="Int32"/>.</returns>
+        /// <returns>False if there wasn't enough data for an <see cref="int"/>.</returns>
         public static bool TryReadLittleEndian(ref this SequenceReader<byte> reader, out int value)
         {
             if (BitConverter.IsLittleEndian)
@@ -109,9 +109,9 @@ namespace System.Buffers
         }
 
         /// <summary>
-        /// Reads an <see cref="Int32"/> as big endian.
+        /// Reads an <see cref="int"/> as big endian.
         /// </summary>
-        /// <returns>False if there wasn't enough data for an <see cref="Int32"/>.</returns>
+        /// <returns>False if there wasn't enough data for an <see cref="int"/>.</returns>
         public static bool TryReadBigEndian(ref this SequenceReader<byte> reader, out int value)
         {
             if (!BitConverter.IsLittleEndian)
@@ -134,9 +134,9 @@ namespace System.Buffers
         }
 
         /// <summary>
-        /// Reads an <see cref="Int64"/> as little endian.
+        /// Reads an <see cref="long"/> as little endian.
         /// </summary>
-        /// <returns>False if there wasn't enough data for an <see cref="Int64"/>.</returns>
+        /// <returns>False if there wasn't enough data for an <see cref="long"/>.</returns>
         public static bool TryReadLittleEndian(ref this SequenceReader<byte> reader, out long value)
         {
             if (BitConverter.IsLittleEndian)
@@ -148,9 +148,9 @@ namespace System.Buffers
         }
 
         /// <summary>
-        /// Reads an <see cref="Int64"/> as big endian.
+        /// Reads an <see cref="long"/> as big endian.
         /// </summary>
-        /// <returns>False if there wasn't enough data for an <see cref="Int64"/>.</returns>
+        /// <returns>False if there wasn't enough data for an <see cref="long"/>.</returns>
         public static bool TryReadBigEndian(ref this SequenceReader<byte> reader, out long value)
         {
             if (!BitConverter.IsLittleEndian)
index 581d6bc..062b11a 100644 (file)
@@ -203,7 +203,7 @@ namespace System.Memory.Tests
 
         public static TheoryData<Action<ReadOnlySequence<byte>>> OutOfRangeSliceCases => new TheoryData<Action<ReadOnlySequence<byte>>>
         {
-            // negative start  
+            // negative start
             b => b.Slice(-1), // no length
             b => b.Slice(-1, -1), // negative length
             b => b.Slice(-1, 0), // zero length
index 6df7e39..dd1b6e8 100644 (file)
@@ -206,7 +206,7 @@ namespace System.Memory.Tests
 
         public static TheoryData<Action<ReadOnlySequence<char>>> OutOfRangeSliceCases => new TheoryData<Action<ReadOnlySequence<char>>>
         {
-            // negative start  
+            // negative start
             b => b.Slice(-1), // no length
             b => b.Slice(-1, -1), // negative length
             b => b.Slice(-1, 0), // zero length
index 222a3f1..0e7bae4 100644 (file)
@@ -112,7 +112,7 @@ namespace System.SpanTests
         [Fact]
         [OuterLoop]
         [PlatformSpecific(TestPlatforms.Windows | TestPlatforms.OSX)]
-        public unsafe static void BinarySearch_MaxLength_NoOverflow()
+        public static unsafe void BinarySearch_MaxLength_NoOverflow()
         {
             if (sizeof(IntPtr) == sizeof(long))
             {
index 707cb6e..72796a9 100644 (file)
@@ -66,7 +66,7 @@ namespace System.SpanTests
         }
 
         [Fact]
-        public unsafe static void ClearByteUnalignedFixed()
+        public static unsafe void ClearByteUnalignedFixed()
         {
             const byte initial = 5;
             const int length = 32;
@@ -259,7 +259,7 @@ namespace System.SpanTests
         [Fact]
         [OuterLoop]
         [PlatformSpecific(TestPlatforms.Windows | TestPlatforms.OSX)]
-        unsafe static void ClearLongerThanUintMaxValueBytes()
+        static unsafe void ClearLongerThanUintMaxValueBytes()
         {
             if (sizeof(IntPtr) == sizeof(long))
             {
index 64e4931..077c631 100644 (file)
@@ -378,7 +378,7 @@ namespace System.Net.Http.Headers
             return null;
         }
 
-        internal unsafe static KnownHeader TryGetKnownHeader(ReadOnlySpan<byte> name)
+        internal static unsafe KnownHeader TryGetKnownHeader(ReadOnlySpan<byte> name)
         {
             fixed (byte* p = &MemoryMarshal.GetReference(name))
             {
index 0194b08..a8a42c5 100644 (file)
@@ -4,7 +4,7 @@
 // System.Net.ChunkStream
 //
 // Authors:
-//     Gonzalo Paniagua Javier (gonzalo@ximian.com)
+//  Gonzalo Paniagua Javier (gonzalo@ximian.com)
 //
 // (C) 2003 Ximian, Inc (http://www.ximian.com)
 //
index 2ef9f1f..9321fed 100644 (file)
@@ -4,7 +4,7 @@
 // System.Net.ChunkedInputStream
 //
 // Authors:
-//     Gonzalo Paniagua Javier (gonzalo@novell.com)
+//  Gonzalo Paniagua Javier (gonzalo@novell.com)
 //
 // Copyright (c) 2005 Novell, Inc (http://www.novell.com)
 //
index cfa5d52..ee6e267 100644 (file)
@@ -4,7 +4,7 @@
 // System.Net.HttpConnection
 //
 // Author:
-//     Gonzalo Paniagua Javier (gonzalo.mono@gmail.com)
+//  Gonzalo Paniagua Javier (gonzalo.mono@gmail.com)
 //
 // Copyright (c) 2005-2009 Novell, Inc. (http://www.novell.com)
 // Copyright (c) 2012 Xamarin, Inc. (http://xamarin.com)
index d0a372e..3691f63 100644 (file)
@@ -4,7 +4,7 @@
 // System.Net.HttpEndPointListener
 //
 // Author:
-//     Gonzalo Paniagua Javier (gonzalo.mono@gmail.com)
+//  Gonzalo Paniagua Javier (gonzalo.mono@gmail.com)
 //
 // Copyright (c) 2005 Novell, Inc. (http://www.novell.com)
 // Copyright (c) 2012 Xamarin, Inc. (http://xamarin.com)
index 95b0c31..25c32c8 100644 (file)
@@ -4,7 +4,7 @@
 // System.Net.HttpEndPointManager
 //
 // Author:
-//     Gonzalo Paniagua Javier (gonzalo@ximian.com)
+//  Gonzalo Paniagua Javier (gonzalo@ximian.com)
 //
 // Copyright (c) 2005 Novell, Inc. (http://www.novell.com)
 //
index b20af66..4b76363 100644 (file)
@@ -4,8 +4,8 @@
 // System.Net.HttpListenerRequest
 //
 // Authors:
-//     Gonzalo Paniagua Javier (gonzalo.mono@gmail.com)
-//     Marek Safar (marek.safar@gmail.com)
+//  Gonzalo Paniagua Javier (gonzalo.mono@gmail.com)
+//  Marek Safar (marek.safar@gmail.com)
 //
 // Copyright (c) 2005 Novell, Inc. (http://www.novell.com)
 // Copyright (c) 2011-2012 Xamarin, Inc. (http://xamarin.com)
index 4e7063d..fa3950d 100644 (file)
@@ -4,7 +4,7 @@
 // System.Net.HttpListenerResponse
 //
 // Author:
-//     Gonzalo Paniagua Javier (gonzalo@novell.com)
+//  Gonzalo Paniagua Javier (gonzalo@novell.com)
 //
 // Copyright (c) 2005 Novell, Inc. (http://www.novell.com)
 //
@@ -217,13 +217,13 @@ namespace System.Net
                 }
 
                 /* Apache forces closing the connection for these status codes:
-                 *     HttpStatusCode.BadRequest                       400
-                 *     HttpStatusCode.RequestTimeout               408
-                 *     HttpStatusCode.LengthRequired               411
-                 *     HttpStatusCode.RequestEntityTooLarge    413
-                 *     HttpStatusCode.RequestUriTooLong            414
-                 *     HttpStatusCode.InternalServerError      500
-                 *     HttpStatusCode.ServiceUnavailable           503
+                 *    HttpStatusCode.BadRequest                 400
+                 *    HttpStatusCode.RequestTimeout             408
+                 *    HttpStatusCode.LengthRequired             411
+                 *    HttpStatusCode.RequestEntityTooLarge     413
+                 *    HttpStatusCode.RequestUriTooLong         414
+                 *    HttpStatusCode.InternalServerError      500
+                 *    HttpStatusCode.ServiceUnavailable         503
                  */
                 bool conn_close = (_statusCode == (int)HttpStatusCode.BadRequest || _statusCode == (int)HttpStatusCode.RequestTimeout
                         || _statusCode == (int)HttpStatusCode.LengthRequired || _statusCode == (int)HttpStatusCode.RequestEntityTooLarge
index be0740e..edaaea6 100644 (file)
@@ -4,7 +4,7 @@
 // System.Net.RequestStream
 //
 // Author:
-//     Gonzalo Paniagua Javier (gonzalo@novell.com)
+//  Gonzalo Paniagua Javier (gonzalo@novell.com)
 //
 // Copyright (c) 2005 Novell, Inc. (http://www.novell.com)
 //
index b4251d9..ccede74 100644 (file)
@@ -4,7 +4,7 @@
 // System.Net.ResponseStream
 //
 // Author:
-//     Gonzalo Paniagua Javier (gonzalo@novell.com)
+//  Gonzalo Paniagua Javier (gonzalo@novell.com)
 //
 // Copyright (c) 2005 Novell, Inc. (http://www.novell.com)
 //
index a91f67e..79ede15 100644 (file)
@@ -4,7 +4,7 @@
 // System.Net.HttpStreamAsyncResult
 //
 // Authors:
-//     Gonzalo Paniagua Javier (gonzalo@novell.com)
+//  Gonzalo Paniagua Javier (gonzalo@novell.com)
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
index c01f58c..dba017a 100644 (file)
@@ -4,7 +4,7 @@
 // System.Net.ListenerAsyncResult
 //
 // Authors:
-//     Gonzalo Paniagua Javier (gonzalo@ximian.com)
+//  Gonzalo Paniagua Javier (gonzalo@ximian.com)
 //
 // Copyright (c) 2005 Ximian, Inc (http://www.ximian.com)
 //
index 779a280..a6f82bf 100644 (file)
@@ -4,8 +4,8 @@
 // System.Net.ListenerPrefix
 //
 // Author:
-//     Gonzalo Paniagua Javier (gonzalo@novell.com)
-//     Oleg Mihailik (mihailik gmail co_m)
+//  Gonzalo Paniagua Javier (gonzalo@novell.com)
+//  Oleg Mihailik (mihailik gmail co_m)
 //
 // Copyright (c) 2005 Novell, Inc. (http://www.novell.com)
 //
index 7eb26dc..e9cb374 100644 (file)
@@ -292,7 +292,7 @@ namespace System.Net
                 // or the query fails for some reason, don't add an SPN.
                 try
                 {
-                    string machineName = Dns.GetHostEntry(String.Empty).HostName;
+                    string machineName = Dns.GetHostEntry(string.Empty).HostName;
                     return new string[] { "HTTP/" + machineName };
                 }
                 catch (System.Net.Sockets.SocketException)
index d54f0d3..2846746 100644 (file)
@@ -4,7 +4,7 @@
 // SmtpExceptionTest.cs - NUnit Test Cases for System.Net.Mail.SmtpException
 //
 // Authors:
-//     Gert Driesen (drieseng@users.sourceforge.net)
+//  Gert Driesen (drieseng@users.sourceforge.net)
 //
 // (C) 2008 Gert Driesen
 //
index 079a5d1..87aaf93 100644 (file)
@@ -8,10 +8,10 @@ namespace System
 {
     internal static class IPv6AddressHelper
     {
-        internal unsafe static (int longestSequenceStart, int longestSequenceLength) FindCompressionRange(
+        internal static unsafe (int longestSequenceStart, int longestSequenceLength) FindCompressionRange(
             ReadOnlySpan<ushort> numbers) => (-1, -1);
-        internal unsafe static bool ShouldHaveIpv4Embedded(ReadOnlySpan<ushort> numbers) => false;
-        internal unsafe static bool IsValidStrict(char* name, int start, ref int end) => false;
+        internal static unsafe bool ShouldHaveIpv4Embedded(ReadOnlySpan<ushort> numbers) => false;
+        internal static unsafe bool IsValidStrict(char* name, int start, ref int end) => false;
         internal static unsafe bool Parse(ReadOnlySpan<char> ipSpan, Span<ushort> numbers, int start, ref string scopeId) => false;
     }
 }
index b1540f1..63eb8b4 100644 (file)
@@ -13,8 +13,8 @@ namespace System.Net.Security
         private const int ProtocolVersionSize = 2;
         private const int UInt24Size = 3;
         private const int RandomSize = 32;
-        private readonly static IdnMapping s_idnMapping = CreateIdnMapping();
-        private readonly static Encoding s_encoding = CreateEncoding();
+        private static readonly IdnMapping s_idnMapping = CreateIdnMapping();
+        private static readonly Encoding s_encoding = CreateEncoding();
 
         public static string GetServerName(byte[] clientHello)
         {
index 1995696..c4c9bfc 100644 (file)
@@ -31,15 +31,15 @@ namespace System.Net.Sockets
             _buffer = null;
             _numBytes = 0;
 
-                       if (errorCode == SocketError.Success)
-                       {
-                               Internals.SocketAddress remoteSocketAddress = IPEndPointExtensions.Serialize(_listenSocket._rightEndPoint);
-                               System.Buffer.BlockCopy(socketAddress, 0, remoteSocketAddress.Buffer, 0, socketAddressLen);
-
-                               _acceptedSocket = _listenSocket.CreateAcceptSocket(
-                                       SafeSocketHandle.CreateSocket(acceptedFileDescriptor),
-                                       _listenSocket._rightEndPoint.Create(remoteSocketAddress));
-                       }
+            if (errorCode == SocketError.Success)
+            {
+                Internals.SocketAddress remoteSocketAddress = IPEndPointExtensions.Serialize(_listenSocket._rightEndPoint);
+                System.Buffer.BlockCopy(socketAddress, 0, remoteSocketAddress.Buffer, 0, socketAddressLen);
+
+                _acceptedSocket = _listenSocket.CreateAcceptSocket(
+                    SafeSocketHandle.CreateSocket(acceptedFileDescriptor),
+                    _listenSocket._rightEndPoint.Create(remoteSocketAddress));
+            }
 
             base.CompletionCallback(0, errorCode);
         }
index b94f514..7a98ac3 100644 (file)
@@ -9,6 +9,6 @@ namespace System.Net.Sockets.Tests
     public partial class SocketOptionNameTest
     {
         [DllImport("libc", SetLastError = true)]
-        private unsafe static extern int setsockopt(int socket, int level, int option_name, void* option_value, uint option_len);
+        private static extern unsafe int setsockopt(int socket, int level, int option_name, void* option_value, uint option_len);
     }
 }
index 8c6aa93..b9d658a 100644 (file)
@@ -6,7 +6,7 @@ namespace System.Net.Sockets.Tests
 {
     public partial class SocketOptionNameTest
     {
-        private unsafe static int setsockopt(int socket, int level, int option_name, void* option_value, uint option_len)
+        private static unsafe int setsockopt(int socket, int level, int option_name, void* option_value, uint option_len)
         {
             throw new PlatformNotSupportedException();
         }
index 6908c6a..6f55894 100644 (file)
@@ -245,5 +245,5 @@ namespace System.PrivateUri.Tests
             Uri.HexUnescape("%75", ref index);
             Assert.Throws<ArgumentOutOfRangeException>(() => Uri.HexUnescape("%75", ref index));
         }
-       }
+    }
 }
index 77688ff..6dd3f6d 100644 (file)
@@ -46,7 +46,7 @@ namespace System.Xml.Linq
         /// <param name="obj">The node to hash.</param>
         /// <returns>A value-based hash code for the node.</returns>
         /// <remarks>
-        /// The <see cref="XNode"/> class's implementation of <see cref="Object.GetHashCode"/>
+        /// The <see cref="XNode"/> class's implementation of <see cref="object.GetHashCode"/>
         /// is based on the referential identity of the node. This method computes a
         /// hash code based on the value of the node.
         /// </remarks>
@@ -89,7 +89,7 @@ namespace System.Xml.Linq
         /// <param name="obj">The node to hash.</param>
         /// <returns>A value-based hash code for the node.</returns>
         /// <remarks>
-        /// The <see cref="XNode"/> class's implementation of <see cref="Object.GetHashCode"/>
+        /// The <see cref="XNode"/> class's implementation of <see cref="object.GetHashCode"/>
         /// is based on the referential identity of the node. This method computes a
         /// hash code based on the value of the node.
         /// </remarks>
index a17e8e6..6ea1214 100644 (file)
@@ -216,7 +216,7 @@ namespace XLinqTests
             attr.Verify();
         }
 
-        // 21. The empty string cannot be used as a namespace name (exception is default ns redef.)  
+        // 21.    The empty string cannot be used as a namespace name (exception is default ns redef.)  
         //[Variation(Priority = 1, Desc = "XAttribute - default namespace decl & empty value", Params = new object[] { false, "xmlns" })]
         public void CreateXAttribute6()
         {
@@ -235,7 +235,7 @@ namespace XLinqTests
             }
         }
 
-        // 21. The empty string cannot be used as a namespace name (exception is default ns redef.)  
+        // 21.    The empty string cannot be used as a namespace name (exception is default ns redef.)  
         //[Variation(Priority = 1, Desc = "XAttribute - prefixed namespace decl & empty value", Params = new object[] { true, "p" })]
         public void CreateXAttribute7()
         {
@@ -254,14 +254,14 @@ namespace XLinqTests
             }
         }
 
-        // 22. Xml prefix:  Enforce
-        //    ï¿½      http://www.w3.org/XML/1998/namespace 
-        //    ï¿½      Must not be bound to any other namespace name.
-        //    ï¿½      No other prefix may be bound to this namespace name.
-        // 23. Xmlns prefix:  Enforce, but some concern about performance
-        //    ï¿½      http://www.w3.org/2000/xmlns/ 
-        //    ï¿½      It must not be declared
-        //    ï¿½      No other prefix may be bound to this namespace name. 
+        // 22. Xml prefix:  Enforce
+        //    ï¿½ http://www.w3.org/XML/1998/namespace 
+        //    ï¿½ Must not be bound to any other namespace name.
+        //    ï¿½ No other prefix may be bound to this namespace name.
+        // 23. Xmlns prefix:  Enforce, but some concern about performance
+        //    ï¿½ http://www.w3.org/2000/xmlns/ 
+        //    ï¿½ It must not be declared
+        //    ï¿½ No other prefix may be bound to this namespace name. 
         //[Variation(Priority = 1, Desc = "XAttribute - xml namespace - prefix redef", Params = new object[] { "xml", "another", true })]
         //[Variation(Priority = 1, Desc = "XAttribute - xml namespace - bound to diff. prefix", Params = new object[] { "p", "http://www.w3.org/XML/1998/namespace", true })]
         //[Variation(Priority = 1, Desc = "XAttribute - xml namespace - redeclared (positive).", Params = new object[] { "xml", "http://www.w3.org/XML/1998/namespace", false })]
index 4a2f38f..4bb4485 100644 (file)
@@ -934,14 +934,14 @@ public class CXmlCache
             }
             else
             {
-                rNewNode.peFlags |= NodeFlags.Indent;          // Turn on Indent for current Node
+                rNewNode.peFlags |= NodeFlags.Indent;        // Turn on Indent for current Node
             }
 
             // Set all Depth 0 nodes to No Mixed Content and Indent True
             if (prXmlReader.Depth == 0)
             {
-                rNewNode.peFlags |= NodeFlags.Indent;                  // Turn on Indent
-                rNewNode.peFlags &= ~NodeFlags.MixedContent;   // Turn off MixedContent
+                rNewNode.peFlags |= NodeFlags.Indent;        // Turn on Indent
+                rNewNode.peFlags &= ~NodeFlags.MixedContent; // Turn off MixedContent
             }
 
             rParentNode.InsertNode(rNewNode);
@@ -1021,17 +1021,17 @@ public class CXmlCache
                     {
                         rNewNode.peFlags = _eDefaultFlags | NodeFlags.AttributeTextNode;
                     }
-                    rNewNode.peFlags |= NodeFlags.MixedContent;                // turn on Mixed Content for current node
-                    rNewNode.peFlags &= ~NodeFlags.Indent;                     // turn off Indent for current node
-                    rParentNode.peFlags |= NodeFlags.MixedContent;     // turn on Mixed Content for Parent Node
+                    rNewNode.peFlags |= NodeFlags.MixedContent;    // turn on Mixed Content for current node
+                    rNewNode.peFlags &= ~NodeFlags.Indent;         // turn off Indent for current node
+                    rParentNode.peFlags |= NodeFlags.MixedContent; // turn on Mixed Content for Parent Node
                     break;
 
                 case XmlNodeType.Whitespace:
                 case XmlNodeType.SignificantWhitespace:
                 case XmlNodeType.CDATA:
-                    rNewNode.peFlags |= NodeFlags.MixedContent;                // turn on Mixed Content for current node
-                    rNewNode.peFlags &= ~NodeFlags.Indent;                     // turn off Indent for current node
-                    rParentNode.peFlags |= NodeFlags.MixedContent;     // turn on Mixed Content for Parent Node
+                    rNewNode.peFlags |= NodeFlags.MixedContent;    // turn on Mixed Content for current node
+                    rNewNode.peFlags &= ~NodeFlags.Indent;         // turn off Indent for current node
+                    rParentNode.peFlags |= NodeFlags.MixedContent; // turn on Mixed Content for Parent Node
                     break;
 
                 case XmlNodeType.Comment:
index 9a6f35f..68fe6ae 100644 (file)
@@ -25,10 +25,10 @@ namespace CoreXml.Test.XLinq
         private const string COMMENT = "COMMENT_";
 
         private long _eCount = 0;    //element indexer
-        private long _aCount = 0;      //attribute indexer
+        private long _aCount = 0;    //attribute indexer
         private long _cCount = 0;    //Cdata indexer
-        private long _tCount = 0;      //Text indexer 
-        private long _pCount = 0;      //PI Indexer
+        private long _tCount = 0;    //Text indexer 
+        private long _pCount = 0;    //PI Indexer
         private long _mCount = 0;    //Comment Indexer
 
         private StreamWriter _textWriter = null;
@@ -183,7 +183,7 @@ namespace CoreXml.Test.XLinq
 
         /// Writing text.
         /// Note : This is basically equivalent to WriteRaw and the string may contain any number of embedded tags.
-        ///                    No checking is performed on them either.
+        ///        No checking is performed on them either.
         public void PutText(string myStr)
         {
             _nodeQueue.Append(myStr);
@@ -248,23 +248,23 @@ namespace CoreXml.Test.XLinq
 
         /// <summary>
         /// This method is a convenience method and a shortcut to create an XML string. Each character in the pattern
-        ///    maps to a particular Put/Open function and calls it for you. For e.g. XEAA/ will call PutDecl, OpenElement, 
-        ///    PutAttribute, PutAttribute and CloseElement for you.
-        ///    The following is the list of all allowed characters and their function mappings :
+        /// maps to a particular Put/Open function and calls it for you. For e.g. XEAA/ will call PutDecl, OpenElement, 
+        /// PutAttribute, PutAttribute and CloseElement for you.
+        /// The following is the list of all allowed characters and their function mappings :
         ///
-        ///'X' :       PutDecl()
-        ///'E' :       OpenElement()
-        ///'M' :       CloseEmptyElement()
-        ///'/' :       CloseElement()
-        ///'e' :       PutEndElement()
-        ///'A' :       PutAttribute()
-        ///'P' :       PutPI()
-        ///'T' :       PutText()
-        ///'C' :       PutComment()
-        ///'R' :       PutRoot()
-        ///'r' :       PutEndRoot()
-        ///'B' :       PutEndRoot()
-        ///'W' :       PutWhiteSpace()
+        ///'X' :    PutDecl()
+        ///'E' :    OpenElement()
+        ///'M' :    CloseEmptyElement()
+        ///'/' :    CloseElement()
+        ///'e' :    PutEndElement()
+        ///'A' :    PutAttribute()
+        ///'P' :    PutPI()
+        ///'T' :    PutText()
+        ///'C' :    PutComment()
+        ///'R' :    PutRoot()
+        ///'r' :    PutEndRoot()
+        ///'B' :    PutEndRoot()
+        ///'W' :    PutWhiteSpace()
         ///
         /// </summary>
         /// <param name="pattern">String containing the pattern which you want to use to create
index 6fd64a6..2605b83 100644 (file)
@@ -113,7 +113,7 @@ namespace Microsoft.Test.ModuleCore
         ITestItems Children { get; }
 
         // Execution
-        //             Control Flow:   Init->Execute->(recurse into children)->Terminate
+        //        Control Flow:    Init->Execute->(recurse into children)->Terminate
         TestResult Init();
         TestResult Execute();
         TestResult Terminate();
index 11798ee..8c590fc 100644 (file)
@@ -50,7 +50,7 @@ namespace Microsoft.Test.ModuleCore
             base.DetermineChildren();
 
             //Sort
-            //Default sort is based upon IComparable of each item      
+            //Default sort is based upon IComparable of each item
             Children.Sort();
         }
 
index e3de423..603fff4 100644 (file)
@@ -292,14 +292,14 @@ namespace Microsoft.Test.ModuleCore
             if (Internal != null)
             {
                 Internal.Error(result,
-                            TestLogFlags.Text,                 //flags        
-                            StringEx.Format(actual),           //actual
-                            StringEx.Format(expected),         //expected
-                            source,                                                    //source
-                            message,                                           //message
-                            stack,                                             //stack
-                            filename,                          //filename
-                            lineno                             //line
+                            TestLogFlags.Text,         //flags        
+                            StringEx.Format(actual),   //actual
+                            StringEx.Format(expected), //expected
+                            source,                    //source
+                            message,                   //message
+                            stack,                     //stack
+                            filename,                  //filename
+                            lineno                     //line
                         );
             }
             else
index 840308a..5ab3857 100644 (file)
@@ -3,8 +3,8 @@
 // See the LICENSE file in the project root for more information.
 
 using System;
-using System.Collections;                      //IEnumerator
-using System.Collections.Generic;   //List<T>
+using System.Collections;
+using System.Collections.Generic;
 
 namespace Microsoft.Test.ModuleCore
 {
index 9a33eeb..4755b00 100644 (file)
@@ -182,7 +182,7 @@ namespace Microsoft.Test.ModuleCore
             //plus this allows both teams to have a identical (similar as possible) queries/filters.
 
             //Xml Spec Format:
-            // Example:
+            //    Example:
             /*
                 <TestModule Name="Functional" Created="10 October 2001" Modified="10 October 2001" Version="1">
                 <-- Owner type is an enum, "test", "dev" or "pm" -->
index ed098e6..4c87f86 100644 (file)
@@ -14,7 +14,7 @@ namespace MS.Internal.Xml.Cache
     /// information about that node's page.  The other fields in the 0th node are undefined and should never
     /// be used.
     /// </summary>
-    sealed internal class XPathNodePageInfo
+    internal sealed class XPathNodePageInfo
     {
         private int _pageNum;
         private int _nodeCount;
@@ -76,7 +76,7 @@ namespace MS.Internal.Xml.Cache
     /// string.Intern() operation.  If a node's name, type, or parent/sibling pages are modified, then a new
     /// InfoAtom needs to be obtained, since other nodes may still be referencing the old InfoAtom.
     /// </summary>
-    sealed internal class XPathNodeInfoAtom : IEquatable<XPathNodeInfoAtom>
+    internal sealed class XPathNodeInfoAtom : IEquatable<XPathNodeInfoAtom>
     {
         private string _localName;
         private string _namespaceUri;
@@ -375,7 +375,7 @@ namespace MS.Internal.Xml.Cache
     /// <summary>
     /// An atomization table for XPathNodeInfoAtom.
     /// </summary>
-    sealed internal class XPathNodeInfoTable
+    internal sealed class XPathNodeInfoTable
     {
         private XPathNodeInfoAtom[] _hashTable;
         private int _sizeTable;
index 9472a36..eb38768 100644 (file)
@@ -11,13 +11,13 @@ namespace System.Xml
     //
     // Following table shows what will happen with new line characters in detail:
     //
-    //                                                                         |      In text node value       |    In attribute value               |
-    // input to XmlWriter.WriteString()                | \r\n          \n              \r              \t      |       \r\n            \n              \r              \t    |
-    // ------------------------------------------------------------------------------------------------------------
-    // NewLineHandling.Replace (default)       | \r\n          \r\n    \r\n    \t      |       &#D;&#A;        &#A;    &#D;    &#9;  |
-    // NewLineHandling.Entitize                            | &#D;              \n              &#D;    \t      |       &#D;&#A;        &#A;    &#D;    &#9;  |
-    // NewLineHandling.None                                | \r\n              \n              \r              \t      |       \r\n            \n              \r              \t    |
-    // ------------------------------------------------------------------------------------------------------------
+    //                                      |      In text node value   |    In attribute value          |
+    // input to XmlWriter.WriteString()     | \r\n    \n    \r    \t    |  \r\n      \n     \r     \t    |
+    // ---------------------------------------------------------------------------------------------------
+    // NewLineHandling.Replace (default)    | \r\n    \r\n  \r\n  \t    |  &#D;&#A;  &#A;   &#D;   &#9;  |
+    // NewLineHandling.Entitize             | &#D;    \n    &#D;  \t    |  &#D;&#A;  &#A;   &#D;   &#9;  |
+    // NewLineHandling.None                 | \r\n    \n    \r    \t    |  \r\n      \n     \r     \t    |
+    // ---------------------------------------------------------------------------------------------------
 
     // Specifies how end of line is handled in XmlWriter.
     public enum NewLineHandling
index 52fa8fd..ffcc564 100644 (file)
@@ -36,11 +36,11 @@ namespace System.Xml.Resolvers
 
             if (ofObjectToReturn == null || ofObjectToReturn == typeof(Stream) || ofObjectToReturn == typeof(object))
             {
-                return Task.FromResult<Object>(data.AsStream());
+                return Task.FromResult<object>(data.AsStream());
             }
             else if (ofObjectToReturn == typeof(TextReader))
             {
-                return Task.FromResult<Object>(data.AsTextReader());
+                return Task.FromResult<object>(data.AsTextReader());
             }
             else
             {
index 98662c7..f172a27 100644 (file)
@@ -172,7 +172,7 @@ namespace System.Xml.Schema
             { //attribute group is the redefinition of existingObject
                 if (existingAttGroup.AttributeUses.Count == 0)
                 { //If the existing one is not already compiled, then replace.
-                    table.Insert(attGroup.QualifiedName, attGroup); //Update with redefined entry                      
+                    table.Insert(attGroup.QualifiedName, attGroup); //Update with redefined entry
                     return true;
                 }
             }
@@ -191,7 +191,7 @@ namespace System.Xml.Schema
             { //group is the redefinition of existingObject
                 if (existingGroup.CanonicalParticle == null)
                 { //If the existing one is not already compiled, then replace.
-                    table.Insert(group.QualifiedName, group); //Update with redefined entry                    
+                    table.Insert(group.QualifiedName, group); //Update with redefined entry
                     return true;
                 }
             }
@@ -210,7 +210,7 @@ namespace System.Xml.Schema
             { //schemaType is the redefinition of existingObject
                 if (existingType.ElementDecl == null)
                 { //If the existing one is not already compiled, then replace.
-                    table.Insert(schemaType.QualifiedName, schemaType); //Update with redefined entry                  
+                    table.Insert(schemaType.QualifiedName, schemaType); //Update with redefined entry
                     return true;
                 }
             }
index 4df6c45..7c1e63d 100644 (file)
@@ -162,7 +162,7 @@ namespace System.Xml.Schema
             return Add(schema, _xmlResolver);
         }
 
-           public XmlSchema Add(XmlSchema schema, XmlResolver resolver)
+        public XmlSchema Add(XmlSchema schema, XmlResolver resolver)
         {
             if (schema == null)
                 throw new ArgumentNullException(nameof(schema));
index 7b2dde1..2f952ee 100644 (file)
@@ -64,7 +64,7 @@ namespace System.Xml.Schema
                 if (_internalSyncObject == null)
                 {
                     object o = new object();
-                    Interlocked.CompareExchange<Object>(ref _internalSyncObject, o, null);
+                    Interlocked.CompareExchange<object>(ref _internalSyncObject, o, null);
                 }
                 return _internalSyncObject;
             }
index 3366d37..bb8172d 100644 (file)
@@ -189,8 +189,8 @@ namespace System.Xml.Schema
                 Type itemTypeDst = destinationType.GetElementType();
 
                 // Different StringSplitOption needs to be used because of following bugs:
-                // 566053: Behavior change between SL2 and Dev10 in the way string arrays are deserialized by the XmlReader.ReadContentsAs method      
-                // 643697: Deserialization of typed arrays by the XmlReader.ReadContentsAs method fails        
+                // 566053: Behavior change between SL2 and Dev10 in the way string arrays are deserialized by the XmlReader.ReadContentsAs method
+                // 643697: Deserialization of typed arrays by the XmlReader.ReadContentsAs method fails
                 //
                 // In Silverligt 2 the XmlConvert.SplitString was not using the StringSplitOptions, which is the same as using StringSplitOptions.None.
                 // What it meant is that whenever there is a double space between two values in the input string it turned into 
index daa4099..92b68ba 100644 (file)
@@ -815,7 +815,7 @@ namespace System.Xml.Serialization
                         Ldstr((string)o);
                         break;
                     case TypeCode.Decimal:
-                        ConstructorInfo Decimal_ctor = typeof(Decimal).GetConstructor(
+                        ConstructorInfo Decimal_ctor = typeof(decimal).GetConstructor(
                              CodeGenerator.InstanceBindingFlags,
                              new Type[] { typeof(int), typeof(int), typeof(int), typeof(bool), typeof(byte) }
                              );
index 4b106c3..17033b9 100644 (file)
@@ -104,7 +104,7 @@ namespace System.Xml.Serialization
             // the given char is already a valid name character
 #if DEBUG
             // use exception in the place of Debug.Assert to avoid throwing asserts from a server process such as aspnet_ewp.exe
-            if (!IsValid(c)) throw new ArgumentException(SR.Format(SR.XmlInternalErrorDetails, "Invalid identifier character " + ((Int16)c).ToString(CultureInfo.InvariantCulture)), nameof(c));
+            if (!IsValid(c)) throw new ArgumentException(SR.Format(SR.XmlInternalErrorDetails, "Invalid identifier character " + ((short)c).ToString(CultureInfo.InvariantCulture)), nameof(c));
 #endif
 
             // First char cannot be a number
index 94dfbde..4a8af77 100644 (file)
@@ -811,7 +811,7 @@ namespace System.Xml.Serialization
                             "CollapseWhitespace",
                             CodeGenerator.InstanceBindingFlags,
                             null,
-                            new Type[] { typeof(String) },
+                            new Type[] { typeof(string) },
                             null
                             );
                         ilg.Call(XmlSerializationReader_CollapseWhitespace);
@@ -1928,7 +1928,7 @@ namespace System.Xml.Serialization
                     CodeGenerator.InstanceBindingFlags,
                     new Type[] { typeof(string), typeof(string) }
                     );
-                MethodInfo String_get_Length = typeof(String).GetMethod(
+                MethodInfo String_get_Length = typeof(string).GetMethod(
                     "get_Length",
                     CodeGenerator.InstanceBindingFlags,
                     Array.Empty<Type>()
@@ -2087,7 +2087,7 @@ namespace System.Xml.Serialization
                 {
                     LocalBuilder locListValues = ilg.DeclareOrGetLocal(typeof(string), "listValues");
                     LocalBuilder locVals = ilg.DeclareOrGetLocal(typeof(string[]), "vals");
-                    MethodInfo String_Split = typeof(String).GetMethod(
+                    MethodInfo String_Split = typeof(string).GetMethod(
                         "Split",
                         CodeGenerator.InstanceBindingFlags,
                         new Type[] { typeof(char[]) }
@@ -3093,7 +3093,7 @@ namespace System.Xml.Serialization
                     ConstructorInfo TimeSpan_ctor = typeof(TimeSpan).GetConstructor(
                         CodeGenerator.InstanceBindingFlags,
                         null,
-                        new Type[] { typeof(Int64) },
+                        new Type[] { typeof(long) },
                         null
                         );
                     ilg.Ldc(default(TimeSpan).Ticks);
index 9b12ae9..0767c28 100644 (file)
@@ -4211,7 +4211,7 @@ namespace System.Xml.Serialization
                     Writer.Write('\'');
                 }
                 else if (type == typeof(int))
-                    Writer.Write(((Int32)value).ToString(null, NumberFormatInfo.InvariantInfo));
+                    Writer.Write(((int)value).ToString(null, NumberFormatInfo.InvariantInfo));
                 else if (type == typeof(double))
                 {
                     if (double.IsNaN((double)value))
@@ -4228,7 +4228,7 @@ namespace System.Xml.Serialization
                     }
                     else
                     {
-                        Writer.Write(((Double)value).ToString("R", NumberFormatInfo.InvariantInfo));
+                        Writer.Write(((double)value).ToString("R", NumberFormatInfo.InvariantInfo));
                     }
                 }
                 else if (type == typeof(bool))
@@ -4258,13 +4258,13 @@ namespace System.Xml.Serialization
                     }
                     else
                     {
-                        Writer.Write(((Single)value).ToString("R", NumberFormatInfo.InvariantInfo));
+                        Writer.Write(((float)value).ToString("R", NumberFormatInfo.InvariantInfo));
                         Writer.Write("f");
                     }
                 }
                 else if (type == typeof(decimal))
                 {
-                    Writer.Write(((Decimal)value).ToString(null, NumberFormatInfo.InvariantInfo));
+                    Writer.Write(((decimal)value).ToString(null, NumberFormatInfo.InvariantInfo));
                     Writer.Write("m");
                 }
                 else if (type == typeof(DateTime))
index 0bf8e88..10e75fc 100644 (file)
@@ -701,7 +701,7 @@ namespace System.Xml.Serialization
                         CodeGenerator.StaticBindingFlags,
                         Array.Empty<Type>()
                         );
-                    MethodInfo Int64_ToString = typeof(Int64).GetMethod(
+                    MethodInfo Int64_ToString = typeof(long).GetMethod(
                         "ToString",
                         CodeGenerator.InstanceBindingFlags,
                         new Type[] { typeof(IFormatProvider) }
@@ -1320,7 +1320,7 @@ namespace System.Xml.Serialization
                             ilg.Ldstr(GetCSharpString(ns));
                             argTypes.Add(typeof(string));
                         }
-                        MethodInfo Object_ToString = typeof(Object).GetMethod(
+                        MethodInfo Object_ToString = typeof(object).GetMethod(
                             "ToString",
                             CodeGenerator.InstanceBindingFlags,
                             Array.Empty<Type>()
index 41a4340..9b2c914 100644 (file)
@@ -235,7 +235,7 @@ namespace System.Xml
                     }
                     else
                     {
-                        bufBld.Append(((Int32)name[0]).ToString("X4", CultureInfo.InvariantCulture));
+                        bufBld.Append(((int)name[0]).ToString("X4", CultureInfo.InvariantCulture));
                         copyPosition = 1;
                     }
 
@@ -280,7 +280,7 @@ namespace System.Xml
                     }
                     else
                     {
-                        bufBld.Append(((Int32)name[position]).ToString("X4", CultureInfo.InvariantCulture));
+                        bufBld.Append(((int)name[position]).ToString("X4", CultureInfo.InvariantCulture));
                         copyPosition = position + 1;
                     }
                     bufBld.Append('_');
index 56dc311..dd70021 100644 (file)
@@ -269,7 +269,7 @@ namespace System.Xml.Xsl.Qil
         /// <summary>
         /// A bit vector holding a set of rewrites.
         /// </summary>
-        sealed internal class QilPatterns
+        internal sealed class QilPatterns
         {
             private readonly BitArray _bits;
 
index 8996bd5..7a95342 100644 (file)
@@ -13,7 +13,7 @@ namespace System.Xml.Xsl.Runtime
     /// <summary>
     /// This internal class implements the XmlRawWriter interface by passing all calls to a wrapped XmlWriter implementation.
     /// </summary>
-    sealed internal class XmlRawWriterWrapper : XmlRawWriter
+    internal sealed class XmlRawWriterWrapper : XmlRawWriter
     {
         private XmlWriter _wrapped;
 
index 83781fe..2e7d37f 100644 (file)
@@ -41,11 +41,11 @@ namespace System.Xml.Xsl
         {
             long bits;
 
-            if (Double.IsNaN(x))
+            if (double.IsNaN(x))
             {
                 return x;
             }
-            if (Double.IsNaN(y))
+            if (double.IsNaN(y))
             {
                 return y;
             }
@@ -78,12 +78,12 @@ namespace System.Xml.Xsl
 
         public static double Succ(double x)
         {
-            return NextAfter(x, Double.PositiveInfinity);
+            return NextAfter(x, double.PositiveInfinity);
         }
 
         public static double Pred(double x)
         {
-            return NextAfter(x, Double.NegativeInfinity);
+            return NextAfter(x, double.NegativeInfinity);
         }
 #endif
 
@@ -2526,7 +2526,7 @@ namespace System.Xml.Xsl
                 }
                 else
                 {
-                    dblLowPrec = Double.NaN;
+                    dblLowPrec = double.NaN;
                 }
 #else
                     goto LDone;
@@ -2576,7 +2576,7 @@ namespace System.Xml.Xsl
 #if DEBUG
                     Debug.Assert(dbl == (double)num);
                     dblLo = dec.AdjustDbl(dbl);
-                    Debug.Assert(dbl == dblLo || Double.IsNaN(dblLo));
+                    Debug.Assert(dbl == dblLo || double.IsNaN(dblLo));
 #endif
                     goto LDone;
                 }
index 1178bcb..2a3e31b 100644 (file)
@@ -164,7 +164,7 @@ namespace System.Xml.Tests
     }
 
     ////////////////////////////////////////////////////////////////
-    // TestCase TCRecord       NameTable.Get
+    // TestCase TCRecord    NameTable.Get
     //
     ////////////////////////////////////////////////////////////////
     //[TestCase(Name="NameTable(Get) VerifyWGetChar", Desc="VerifyWGetChar")]
@@ -627,7 +627,7 @@ namespace System.Xml.Tests
     }
 
     ////////////////////////////////////////////////////////////////
-    // TestCase TCRecord       NameTable.Add
+    // TestCase TCRecord    NameTable.Add
     //
     ////////////////////////////////////////////////////////////////
     //[TestCase(Name="NameTable(Add) VerifyWGetString", Desc="VerifyWGetString")]
index dad064c..149bd2f 100644 (file)
@@ -101,10 +101,10 @@ namespace System.Xml.Tests
             Initial, //At Start.
             PreTest, //After PreTest is called and finished successfully.
             CreateSuccess, //After Create method is called.
-            Consume,   //Before starting to use the object.
+            Consume,    //Before starting to use the object.
             Skip, //The case is skipped.
-            Error,             // In case of an error. Should throw CTestFailedException anyways.
-            Pass,      // Test() is successful.
+            Error,        // In case of an error. Should throw CTestFailedException anyways.
+            Pass,    // Test() is successful.
             Complete //After Successful PostTest.
         };
 
index f2ae2af..c51ac3a 100644 (file)
@@ -309,11 +309,11 @@ namespace System.Xml.Tests
         ///    <ReaderType>Dtd</ReaderType>
         ///    <NameTable>new</NameTable>
         ///    <LineNumberOffset>1</LineNumberOffset>
-        ///             <LinePositionOffset>0</LinePositionOffset>
+        ///      <LinePositionOffset>0</LinePositionOffset>
         ///    <IgnoreInlineSchema>false</IgnoreInlineSchema>
         ///    <IgnoreSchemaLocation>true</IgnoreSchemaLocation>
         ///    <IgnoreIdentityConstraints>false</IgnoreIdentityConstraints>
-        ///             <IgnoreValidationWarnings>true</IgnoreValidationWarnings>
+        ///      <IgnoreValidationWarnings>true</IgnoreValidationWarnings>
         ///    <Schemas>2</Schemas>
         ///    <ValidationEventHandler>0</ValidationEventHandler>
         ///    <ProhibitDtd>true</ProhibitDtd>
index 54d0400..f76eec3 100644 (file)
@@ -254,7 +254,7 @@ namespace System.Xml.Tests
         [XmlWriterInlineData(WriterType.AllButCustom & ~WriterType.CharCheckingWriter, "EntityRef", true)]
         [XmlWriterInlineData(WriterType.AllButCustom & ~WriterType.CharCheckingWriter, "Name", true)]
         [XmlWriterInlineData(WriterType.AllButCustom & ~WriterType.CharCheckingWriter, "NmToken", true)]
-        [XmlWriterInlineData(WriterType.AllButCustom & ~WriterType.CharCheckingWriter, "QName", true)]         
+        [XmlWriterInlineData(WriterType.AllButCustom & ~WriterType.CharCheckingWriter, "QName", true)]
         public void checkChars_4(XmlWriterUtils utils, string tokenType, bool checkCharacters)
         {
             XmlWriterSettings wSettings = new XmlWriterSettings();
index c2e7e67..86c63a9 100644 (file)
@@ -85,7 +85,7 @@ namespace System.Xml.Tests
         }
 
         /*
-         *     Attribute Wildcards
+         *  Attribute Wildcards
          */
 
         [Theory]
@@ -134,7 +134,7 @@ namespace System.Xml.Tests
         //[Variation(Desc = "v8.1.1- Attributes Wildcards(1), allowXmlAttribute=false", Priority = 1, id = 59, Params = new object[] { "v9-1.xml", "v9-1.xsd", false, 0, 0, 2 })]
         [InlineData("v9-1.xml", "v9-1.xsd", false, 0, 0, 2)]
         /*
-         *     Required and Prohibited Attributes
+         *  Required and Prohibited Attributes
          */
         //[Variation(Desc = "v7.1.8- Required and Prohibited Attributes(4), allowXmlAttribute=true", Priority = 1, id = 58, Params = new object[] { "v8-4.xml", "v8-3.xsd", true, 0, 1, 2 })]
         [InlineData("v8-4.xml", "v8-3.xsd", true, 0, 1, 2)]
index 297180a..4d1de7b 100644 (file)
@@ -183,7 +183,7 @@ namespace System.Xml.Tests
             CError.Compare(sc.IsCompiled, true, "CompileIsCompiled");
 
             XmlSchema sch_B = sc.Add(null, Path.Combine(TestData._Root, "import_v9_b.xsd")); // should be already present in the set
-            sc.Add(null, Path.Combine(TestData._Root, "import_v9_c.xsd"));                                // should be already present in the set
+            sc.Add(null, Path.Combine(TestData._Root, "import_v9_c.xsd"));                   // should be already present in the set
 
             CError.Compare(sc.Count, 3, "Count");
             CError.Compare(sc.IsCompiled, true, "IsCompiled");
@@ -219,7 +219,7 @@ namespace System.Xml.Tests
             CError.Compare(sc.IsCompiled, true, "CompileIsCompiled");
 
             XmlSchema sch_B = sc.Add(null, Path.Combine(TestData._Root, "import_v10_b.xsd")); // should be already present in the set
-            sc.Add(null, Path.Combine(TestData._Root, "import_v10_c.xsd"));                               // should be already present in the set
+            sc.Add(null, Path.Combine(TestData._Root, "import_v10_c.xsd"));                   // should be already present in the set
 
             CError.Compare(sc.Count, 3, "Count");
             CError.Compare(sc.IsCompiled, true, "IsCompiled");
@@ -775,7 +775,7 @@ namespace System.Xml.Tests
             CError.Compare(sc.IsCompiled, true, "CompileIsCompiled");
 
             XmlSchema sch_B = sc.Add(null, Path.Combine(TestData._Root, "import_v9_b.xsd")); // should be already present in the set
-            sc.Add(null, Path.Combine(TestData._Root, "import_v9_c.xsd"));                                // should be already present in the set
+            sc.Add(null, Path.Combine(TestData._Root, "import_v9_c.xsd"));                   // should be already present in the set
             CError.Compare(sc.Count, 3, "Count");
             CError.Compare(sc.IsCompiled, true, "IsCompiled");
 
@@ -821,7 +821,7 @@ namespace System.Xml.Tests
             CError.Compare(sc.IsCompiled, true, "CompileIsCompiled");
 
             XmlSchema sch_B = sc.Add(null, Path.Combine(TestData._Root, "import_v10_b.xsd")); // should be already present in the set
-            sc.Add(null, Path.Combine(TestData._Root, "import_v10_c.xsd"));                               // should be already present in the set
+            sc.Add(null, Path.Combine(TestData._Root, "import_v10_c.xsd"));                   // should be already present in the set
             CError.Compare(sc.Count, 3, "Count");
             CError.Compare(sc.IsCompiled, true, "IsCompiled");
 
@@ -1474,7 +1474,7 @@ namespace System.Xml.Tests
             CError.Compare(sc.Count, 3, "ReprocessCount");
 
             XmlSchema sch_B = sc.Add(null, Path.Combine(TestData._Root, "import_v9_b.xsd")); // should be already present in the set
-            sc.Add(null, Path.Combine(TestData._Root, "import_v9_c.xsd"));                                // should be already present in the set
+            sc.Add(null, Path.Combine(TestData._Root, "import_v9_c.xsd"));                   // should be already present in the set
             CError.Compare(sc.Count, 3, "Count");
             CError.Compare(sc.IsCompiled, false, "IsCompiled");
 
@@ -1521,7 +1521,7 @@ namespace System.Xml.Tests
             CError.Compare(sc.Count, 3, "ReprocessCount");
 
             XmlSchema sch_B = sc.Add(null, Path.Combine(TestData._Root, "import_v10_b.xsd")); // should be already present in the set
-            sc.Add(null, Path.Combine(TestData._Root, "import_v10_c.xsd"));                               // should be already present in the set
+            sc.Add(null, Path.Combine(TestData._Root, "import_v10_c.xsd"));                   // should be already present in the set
             CError.Compare(sc.Count, 3, "Count");
             CError.Compare(sc.IsCompiled, false, "IsCompiled");
 
index cd4ae7f..c0dea14 100644 (file)
@@ -19,11 +19,11 @@ namespace System.Xml.Tests
         }
     }
 
-       public static class FilePathUtil
-       {
-               public static XmlTestSettings TestSettings = new XmlTestSettings();
+    public static class FilePathUtil
+    {
+        public static XmlTestSettings TestSettings = new XmlTestSettings();
 
-           public static string GetDataPath()
+        public static string GetDataPath()
         {
             return TestSettings.DataPath;
         }
@@ -36,5 +36,5 @@ namespace System.Xml.Tests
         {
             return Path.Combine(GetDataPath(), "TestFiles", "StandardTests");
         }
-       }
+    }
 }
index ca1da62..1d5b932 100644 (file)
@@ -302,7 +302,7 @@ namespace System.Xml.Tests
             XmlWriter xw = XmlWriter.Create(stm2, os);
 
             //Transform to XmlWriter
-            _output.WriteLine("Transforming to XmlWriter over Stream2 with XSLT        OutputSettings - 'out2.xml'");
+            _output.WriteLine("Transforming to XmlWriter over Stream2 with XSLT    OutputSettings - 'out2.xml'");
             _xsl.Transform(_xmlFile, null, xw);
 
             //Close the streams
index 082193e..8ab3f17 100644 (file)
@@ -14,10 +14,10 @@ namespace System.Xml.Tests
     public class SameInstanceXslTransformTestCase : XsltApiTestCaseBase2
     {
         // Variables from init string
-        protected string _strPath;                                     // Path of the data files
+        protected string _strPath;                    // Path of the data files
 
         // Other global variables
-        public XslCompiledTransform xsltSameInstance;                          // Used for same instance testing of XsltArgumentList
+        public XslCompiledTransform xsltSameInstance; // Used for same instance testing of XsltArgumentList
 
         private ITestOutputHelper _output;
         public SameInstanceXslTransformTestCase(ITestOutputHelper output) : base(output)
@@ -37,7 +37,7 @@ namespace System.Xml.Tests
     //[TestCase(Name = "Same instance testing: Transform() - READER")]
     public class SameInstanceXslTransformReader : SameInstanceXslTransformTestCase
     {
-        private XPathDocument _xd;                     // Loads XML file
+        private XPathDocument _xd;           // Loads XML file
         private XmlReader _xrData;           // Loads XML File
 
         private ITestOutputHelper _output;
@@ -321,8 +321,8 @@ namespace System.Xml.Tests
     //[TestCase(Name = "Same instance testing: Transform() - TEXTWRITER")]
     public class SameInstanceXslTransformWriter : SameInstanceXslTransformTestCase
     {
-        private XPathDocument _xd;             // Loads XML file
-        private XmlReader _xrData;         // Loads XML file
+        private XPathDocument _xd; // Loads XML file
+        private XmlReader _xrData; // Loads XML file
 
         private ITestOutputHelper _output;
         public SameInstanceXslTransformWriter(ITestOutputHelper output) : base(output)
index cedce71..d7663d9 100644 (file)
@@ -14,10 +14,10 @@ namespace System.Xml.Tests
     public class CSameInstanceXsltArgTestCase2 : XsltApiTestCaseBase2
     {
         // Variables from init string
-        protected string _strPath;                             // Path of the data files
+        protected string _strPath;                // Path of the data files
 
         // Other global variables
-        public XsltArgumentList xsltArg1;                                      // Shared XsltArgumentList for same instance testing
+        public XsltArgumentList xsltArg1;                    // Shared XsltArgumentList for same instance testing
 
         private ITestOutputHelper _output;
         public CSameInstanceXsltArgTestCase2(ITestOutputHelper output) : base(output)
index 0be36ee..86dbc3e 100644 (file)
@@ -1047,14 +1047,14 @@ public class CXmlCache
             }
             else
             {
-                rNewNode._eFlags |= NodeFlags.Indent;          // Turn on Indent for current Node
+                rNewNode._eFlags |= NodeFlags.Indent;        // Turn on Indent for current Node
             }
 
             // Set all Depth 0 nodes to No Mixed Content and Indent True
             if (_rXmlReader.Depth == 0)
             {
-                rNewNode._eFlags |= NodeFlags.Indent;                  // Turn on Indent
-                rNewNode._eFlags &= ~NodeFlags.MixedContent;   // Turn off MixedContent
+                rNewNode._eFlags |= NodeFlags.Indent;        // Turn on Indent
+                rNewNode._eFlags &= ~NodeFlags.MixedContent; // Turn off MixedContent
             }
 
             rParentNode.InsertNode(rNewNode);
@@ -1123,10 +1123,10 @@ public class CXmlCache
                         {
                             int nEnd;
 
-                            nPos = strValue.IndexOf("=", nPos);                        //Find the = sign
-                            nEnd = strValue.IndexOf("\"", nPos) + 1;   //Find the next " character
-                            nPos = strValue.IndexOf("'", nPos) + 1;            //Find the next ' character
-                            if (nEnd == 0 || (nPos < nEnd && nPos > 0))        //Pick the one that's closer to the = sign
+                            nPos = strValue.IndexOf("=", nPos);         //Find the = sign
+                            nEnd = strValue.IndexOf("\"", nPos) + 1;    //Find the next " character
+                            nPos = strValue.IndexOf("'", nPos) + 1;     //Find the next ' character
+                            if (nEnd == 0 || (nPos < nEnd && nPos > 0)) //Pick the one that's closer to the = sign
                             {
                                 nEnd = strValue.IndexOf("'", nPos);
                             }
@@ -1154,17 +1154,17 @@ public class CXmlCache
                     {
                         rNewNode._eFlags = _eDefaultFlags | NodeFlags.AttributeTextNode;
                     }
-                    rNewNode._eFlags |= NodeFlags.MixedContent;                // turn on Mixed Content for current node
-                    rNewNode._eFlags &= ~NodeFlags.Indent;                     // turn off Indent for current node
-                    rParentNode._eFlags |= NodeFlags.MixedContent;     // turn on Mixed Content for Parent Node
+                    rNewNode._eFlags |= NodeFlags.MixedContent;       // turn on Mixed Content for current node
+                    rNewNode._eFlags &= ~NodeFlags.Indent;            // turn off Indent for current node
+                    rParentNode._eFlags |= NodeFlags.MixedContent;    // turn on Mixed Content for Parent Node
                     break;
 
                 case XmlNodeType.Whitespace:
                 case XmlNodeType.SignificantWhitespace:
                 case XmlNodeType.CDATA:
-                    rNewNode._eFlags |= NodeFlags.MixedContent;                // turn on Mixed Content for current node
-                    rNewNode._eFlags &= ~NodeFlags.Indent;                     // turn off Indent for current node
-                    rParentNode._eFlags |= NodeFlags.MixedContent;     // turn on Mixed Content for Parent Node
+                    rNewNode._eFlags |= NodeFlags.MixedContent;       // turn on Mixed Content for current node
+                    rNewNode._eFlags &= ~NodeFlags.Indent;            // turn off Indent for current node
+                    rParentNode._eFlags |= NodeFlags.MixedContent;    // turn on Mixed Content for Parent Node
                     break;
 
                 case XmlNodeType.Comment:
@@ -1202,7 +1202,7 @@ public class CXmlCache
     private void ValidationCallback(object sender, ValidationEventArgs args)
     {
         //  commented by ROCHOA -- don't know where ValidationEventArgs comes from
-        //     _hr = Convert.ToInt16(args.ErrorCode);
+        //  _hr = Convert.ToInt16(args.ErrorCode);
         throw (new Exception("[" + Convert.ToString(_hr) + "] " + args.Message));
     }
 }
index a7c9b25..56ac808 100644 (file)
@@ -14,11 +14,11 @@ namespace System.Xml.Tests
     public class CSameInstanceXslTransformTestCase : XsltApiTestCaseBase
     {
         // Variables from init string
-        protected string _strPath;                                     // Path of the data files
+        protected string _strPath;                    // Path of the data files
 
         // Other global variables
 #pragma warning disable 0618
-        public XslTransform xsltSameInstance;                          // Used for same instance testing of XsltArgumentList
+        public XslTransform xsltSameInstance;         // Used for same instance testing of XsltArgumentList
 #pragma warning restore 0618
 
         protected int threadCount = 5;
@@ -100,7 +100,7 @@ namespace System.Xml.Tests
     //[TestCase(Name = "Same instance testing: Transform() - READER")]
     public class SameInstanceXslTransformReader : CSameInstanceXslTransformTestCase
     {
-        private XPathDocument _xd;                     // Loads XML file
+        private XPathDocument _xd;            // Loads XML file
 
         private ITestOutputHelper _output;
         public SameInstanceXslTransformReader(ITestOutputHelper output) : base(output)
@@ -140,7 +140,7 @@ namespace System.Xml.Tests
     //[TestCase(Name = "Same instance testing: Transform() - TEXTWRITER")]
     public class SameInstanceXslTransformWriter : CSameInstanceXslTransformTestCase
     {
-        private XPathDocument _xd;             // Loads XML file
+        private XPathDocument _xd;        // Loads XML file
 
         private ITestOutputHelper _output;
         public SameInstanceXslTransformWriter(ITestOutputHelper output) : base(output)
@@ -177,4 +177,4 @@ namespace System.Xml.Tests
             return 1;
         }
     }
-}
\ No newline at end of file
+}
index b57271d..83fc079 100644 (file)
@@ -16,10 +16,10 @@ namespace System.Xml.Tests
     public class CSameInstanceXsltArgTestCase : XsltApiTestCaseBase
     {
         // Variables from init string
-        protected string _strPath;                             // Path of the data files
+        protected string _strPath;                // Path of the data files
 
         // Other global variables
-        public XsltArgumentList xsltArg1;                                      // Shared XsltArgumentList for same instance testing
+        public XsltArgumentList xsltArg1;         // Shared XsltArgumentList for same instance testing
 
         private ITestOutputHelper _output;
         public CSameInstanceXsltArgTestCase(ITestOutputHelper output) : base(output)
index 2c953fc..6077092 100644 (file)
@@ -92,10 +92,10 @@ namespace System.Xml.Tests
         {
             //Note: We have a "wrapper" thread function thats always called.
             //This allows us much greater control than the normal System.Thread class.
-            // 1.  It allows us to call the function repeatedly (iterations)
+            //  1.  It allows us to call the function repeatedly (iterations)
             //  2.  It allows parameters to be passed into the thread function
-            // 3.  It allows a return code from the thread function
-            // 4.  etc...
+            //  3.  It allows a return code from the thread function
+            //  4.  etc...
 
             //Iterate the specified number of times
             for (int i = 0; i < Iterations; i++)
@@ -182,4 +182,4 @@ namespace System.Xml.Tests
             return eResult;
         }
     }
-}
\ No newline at end of file
+}
index 14b4dd7..97cb816 100644 (file)
@@ -52,5 +52,5 @@ namespace System.Reflection.Context.Virtual
                 Position.GetHashCode() ^
                 ParameterType.GetHashCode();
         }
-       }
+    }
 }
index e591b0d..a4a7757 100644 (file)
@@ -835,9 +835,9 @@ namespace System.Reflection.Emit.Tests
         [SkipOnTargetFramework(TargetFrameworkMonikers.NetFramework, "Coreclr fixed an issue where IntPtr/UIntPtr in fieldValues causes a corrupt created binary.")]
         public static void NotSupportedPrimitiveInFieldValues_ThrowsArgumentException(object value)
         {
-               // Used to assert in CustomAttributeBuilder.EmitType(), not writing any CustomAttributeEncoding.
-               // This created a blob that (probably) generates a CustomAttributeFormatException. In theory, this
-               // could have been something more uncontrolled, so was fixed. See issue #11703.
+            // Used to assert in CustomAttributeBuilder.EmitType(), not writing any CustomAttributeEncoding.
+            // This created a blob that (probably) generates a CustomAttributeFormatException. In theory, this
+            // could have been something more uncontrolled, so was fixed. See issue #11703.
             ConstructorInfo con = typeof(TestAttribute).GetConstructor(new Type[0]);
             FieldInfo[] namedFields = Helpers.GetFields(typeof(TestAttribute), nameof(TestAttribute.ObjectField));
             object[] fieldValues = new object[] { value };
index 267bd39..2cb3549 100644 (file)
@@ -25,11 +25,11 @@ namespace System.Reflection.Emit.Tests
         
             // Invalid unicode
             yield return new object[] { "\uDC00", (PropertyAttributes)0x8000, typeof(EmptyGenericStruct<string>), new Type[] { typeof(EmptyGenericClass<string>) }, "\uFFFD", PropertyAttributes.None };
-                       yield return new object[] { "\uD800", PropertyAttributes.None, typeof(int).MakeByRefType(), new Type[] { typeof(int).MakeByRefType() }, "\uFFFD", PropertyAttributes.None };
-                       yield return new object[] { "1A\0\t\v\r\n\n\uDC81\uDC91", PropertyAttributes.None, typeof(int).MakePointerType(), new Type[] { typeof(int).MakePointerType() }, "1A", PropertyAttributes.None };
-               }
+            yield return new object[] { "\uD800", PropertyAttributes.None, typeof(int).MakeByRefType(), new Type[] { typeof(int).MakeByRefType() }, "\uFFFD", PropertyAttributes.None };
+            yield return new object[] { "1A\0\t\v\r\n\n\uDC81\uDC91", PropertyAttributes.None, typeof(int).MakePointerType(), new Type[] { typeof(int).MakePointerType() }, "1A", PropertyAttributes.None };
+        }
 
-               [Theory]
+        [Theory]
         [MemberData(nameof(TestData))]
         public void DefineProperty(string name, PropertyAttributes attributes, Type returnType, Type[] parameterTypes, string expectedName, PropertyAttributes expectedPropertyAttributes)
         {
index 2074a6d..39e808d 100644 (file)
@@ -21,16 +21,16 @@ namespace System.Reflection.Tests
         public static string[] InheritedButHiddenEvents = new string[] { };
         public static string[] PublicEvents = new string[] { "EventPublic", "EventPublicStatic" };
 
-        public event EventHandler EventPublic;                                 // inherited
-        public static event EventHandler EventPublicStatic;            // static members are not inherited
+        public event EventHandler EventPublic;                    // inherited
+        public static event EventHandler EventPublicStatic;       // static members are not inherited
 
-        internal event EventHandler EventInternal;                             // not inherited
-        internal static event EventHandler EventInternalStatic;        // not inherited
+        internal event EventHandler EventInternal;                // not inherited
+        internal static event EventHandler EventInternalStatic;   // not inherited
 
-        private event EventHandler EventPrivate;                                       // not inherited
+        private event EventHandler EventPrivate;                  // not inherited
 
-        protected event EventHandler EventProtected;                           // inherited
-        protected static event EventHandler EventProtectedStatic;      // not inherited
+        protected event EventHandler EventProtected;              // inherited
+        protected static event EventHandler EventProtectedStatic; // not inherited
     }
 
     public class EventTestSubClass : EventTestBaseClass
@@ -53,7 +53,7 @@ namespace System.Reflection.Tests
         new public static string[] InheritedButHiddenEvents = new string[] { "EventProtected" };
         new public static string[] PublicEvents = new string[] { "EventPublic", "EventPublicNew" };
 
-        new protected event EventHandler EventProtected;               // overrides the ProEvent from EventFieldTest parent            
+        new protected event EventHandler EventProtected;        // overrides the ProEvent from EventFieldTest parent        
         public event EventHandler EventPublicNew;
     }
 
@@ -67,7 +67,7 @@ namespace System.Reflection.Tests
         new public static string[] InheritedButHiddenEvents = new string[] { "EventProtected" };
         new public static string[] PublicEvents = new string[] { "eVentPublicNew", "EventPublic", "EventPublicNew" };
 
-        protected event EventHandler eVentProtected;           // overrides the ProEvent from EventFieldTest parent            
+        protected event EventHandler eVentProtected;        // overrides the ProEvent from EventFieldTest parent        
         public event EventHandler eVentPublicNew;
         internal static event EventHandler eVENTInternal;
         private event EventHandler eVentPriVate;
index 4bbd980..33bc12a 100644 (file)
@@ -1727,10 +1727,10 @@ namespace System.Reflection.Metadata
     {
         internal MetadataReaderProvider() { }
         public void Dispose() { }
-        public unsafe static System.Reflection.Metadata.MetadataReaderProvider FromMetadataImage(byte* start, int size) { throw null; }
+        public static unsafe System.Reflection.Metadata.MetadataReaderProvider FromMetadataImage(byte* start, int size) { throw null; }
         public static System.Reflection.Metadata.MetadataReaderProvider FromMetadataImage(System.Collections.Immutable.ImmutableArray<byte> image) { throw null; }
         public static System.Reflection.Metadata.MetadataReaderProvider FromMetadataStream(System.IO.Stream stream, System.Reflection.Metadata.MetadataStreamOptions options = System.Reflection.Metadata.MetadataStreamOptions.Default, int size = 0) { throw null; }
-        public unsafe static System.Reflection.Metadata.MetadataReaderProvider FromPortablePdbImage(byte* start, int size) { throw null; }
+        public static unsafe System.Reflection.Metadata.MetadataReaderProvider FromPortablePdbImage(byte* start, int size) { throw null; }
         public static System.Reflection.Metadata.MetadataReaderProvider FromPortablePdbImage(System.Collections.Immutable.ImmutableArray<byte> image) { throw null; }
         public static System.Reflection.Metadata.MetadataReaderProvider FromPortablePdbStream(System.IO.Stream stream, System.Reflection.Metadata.MetadataStreamOptions options = System.Reflection.Metadata.MetadataStreamOptions.Default, int size = 0) { throw null; }
         public System.Reflection.Metadata.MetadataReader GetMetadataReader(System.Reflection.Metadata.MetadataReaderOptions options = System.Reflection.Metadata.MetadataReaderOptions.Default, System.Reflection.Metadata.MetadataStringDecoder utf8Decoder = null) { throw null; }
index b2f9c32..f462f05 100644 (file)
@@ -209,7 +209,7 @@ namespace System.Reflection.Internal
             //       However, on .NET < 4.6, there isn't no-op fast path for zero-initialization case so we'd slow down.
             //       Plus, mutating a System.String is no better than the reflection here.
 
-            IEnumerable<MethodInfo> createStringInfos = typeof(String).GetTypeInfo().GetDeclaredMethods("CreateStringFromEncoding");
+            IEnumerable<MethodInfo> createStringInfos = typeof(string).GetTypeInfo().GetDeclaredMethods("CreateStringFromEncoding");
             foreach (var methodInfo in createStringInfos)
             {
                 var parameters = methodInfo.GetParameters();
index 872b356..35b998f 100644 (file)
@@ -81,7 +81,7 @@ namespace System.Reflection.Internal
 
         [DllImport(@"kernel32.dll", EntryPoint = "ReadFile", ExactSpelling = true, SetLastError = true)]
         [return: MarshalAs(UnmanagedType.Bool)]
-        internal static unsafe extern bool ReadFile(
+        internal static extern unsafe bool ReadFile(
              SafeHandle fileHandle,
              byte* buffer,
              int byteCount,
index 637b154..8e61343 100644 (file)
@@ -128,7 +128,7 @@ namespace System.Reflection.Internal
 
         [DllImport(@"kernel32.dll", EntryPoint = "ReadFile", ExactSpelling = true, SetLastError = true)]
         [return: MarshalAs(UnmanagedType.Bool)]
-        internal static unsafe extern bool ReadFile(
+        internal static extern unsafe bool ReadFile(
              SafeHandle fileHandle,
              byte* buffer,
              int byteCount,
index e8a8369..cbeff7c 100644 (file)
@@ -66,7 +66,7 @@ namespace System.Reflection.Metadata
                 {
                     // header (skip local signature rid):
                     _reader.ReadCompressedInteger();
-                                       
+
                     if (document.IsNil)
                     {
                         document = ReadDocumentHandle();
index d39f908..5a45b5d 100644 (file)
@@ -22,67 +22,67 @@ namespace System.Reflection.Metadata
         Void = CorElementType.ELEMENT_TYPE_VOID,
 
         /// <summary>
-        /// Represents <see cref="System.Boolean"/> in signatures.
+        /// Represents <see cref="bool"/> in signatures.
         /// </summary>
         Boolean = CorElementType.ELEMENT_TYPE_BOOLEAN,
 
         /// <summary>
-        /// Represents <see cref="System.Char"/> in signatures.
+        /// Represents <see cref="char"/> in signatures.
         /// </summary>
         Char = CorElementType.ELEMENT_TYPE_CHAR,
 
         /// <summary>
-        /// Represents <see cref="System.SByte"/> in signatures.
+        /// Represents <see cref="sbyte"/> in signatures.
         /// </summary>
         SByte = CorElementType.ELEMENT_TYPE_I1,
 
         /// <summary>
-        /// Represents <see cref="System.Byte"/> in signatures.
+        /// Represents <see cref="byte"/> in signatures.
         /// </summary>
         Byte = CorElementType.ELEMENT_TYPE_U1,
 
         /// <summary>
-        /// Represents <see cref="System.Int16"/> in signatures.
+        /// Represents <see cref="short"/> in signatures.
         /// </summary>
         Int16 = CorElementType.ELEMENT_TYPE_I2,
 
         /// <summary>
-        /// Represents <see cref="System.UInt16"/> in signatures.
+        /// Represents <see cref="ushort"/> in signatures.
         /// </summary>
         UInt16 = CorElementType.ELEMENT_TYPE_U2,
 
         /// <summary>
-        /// Represents <see cref="System.Int32"/> in signatures.
+        /// Represents <see cref="int"/> in signatures.
         /// </summary>
         Int32 = CorElementType.ELEMENT_TYPE_I4,
 
         /// <summary>
-        /// Represents <see cref="System.UInt32"/> in signatures.
+        /// Represents <see cref="uint"/> in signatures.
         /// </summary>
         UInt32 = CorElementType.ELEMENT_TYPE_U4,
 
         /// <summary>
-        /// Represents <see cref="System.Int64"/> in signatures.
+        /// Represents <see cref="long"/> in signatures.
         /// </summary>
         Int64 = CorElementType.ELEMENT_TYPE_I8,
 
         /// <summary>
-        /// Represents <see cref="System.UInt64"/> in signatures.
+        /// Represents <see cref="ulong"/> in signatures.
         /// </summary>
         UInt64 = CorElementType.ELEMENT_TYPE_U8,
 
         /// <summary>
-        /// Represents <see cref="System.Single"/> in signatures.
+        /// Represents <see cref="float"/> in signatures.
         /// </summary>
         Single = CorElementType.ELEMENT_TYPE_R4,
 
         /// <summary>
-        /// Represents <see cref="System.Double"/> in signatures.
+        /// Represents <see cref="double"/> in signatures.
         /// </summary>
         Double = CorElementType.ELEMENT_TYPE_R8,
 
         /// <summary>
-        /// Represents <see cref="System.String"/> in signatures.
+        /// Represents <see cref="string"/> in signatures.
         /// </summary>
         String = CorElementType.ELEMENT_TYPE_STRING,
 
@@ -138,7 +138,7 @@ namespace System.Reflection.Metadata
         FunctionPointer = CorElementType.ELEMENT_TYPE_FNPTR,           // FNPTR <complete sig for the function including calling convention>
 
         /// <summary>
-        /// Represents <see cref="System.Object"/>
+        /// Represents <see cref="object"/>
         /// </summary>
         Object = CorElementType.ELEMENT_TYPE_OBJECT,
 
index b642c48..88354bc 100644 (file)
@@ -6,31 +6,31 @@
 
 public class C
 {
-       public void MC1() { }
-       public void MC2() { }
-       
-       event System.Action EC1;
-       event System.Action EC2;
-       event System.Action EC3;
+    public void MC1() { }
+    public void MC2() { }
+    
+    event System.Action EC1;
+    event System.Action EC2;
+    event System.Action EC3;
 }
 
 public class D
 {
-       public void MD1() { }
-       public int FD1;
+    public void MD1() { }
+    public int FD1;
 
-       public int PE1 { get { return 1; } set { } }
-       
-       event System.Action ED1;
+    public int PE1 { get { return 1; } set { } }
+    
+    event System.Action ED1;
 }
 
 public class E
 {
-       public int FE1;
-       public int FE2;
-       public int FE3;
-       public int FE4;
-       
-       public int PE1 { get { return 1; } set { } }
-       public int PE2 { get { return 1; } set { } }
+    public int FE1;
+    public int FE2;
+    public int FE3;
+    public int FE4;
+    
+    public int PE1 { get { return 1; } set { } }
+    public int PE2 { get { return 1; } set { } }
 }
index 9480ee9..0609092 100644 (file)
@@ -190,32 +190,32 @@ namespace System.Reflection.Runtime.BindingFlagSupport
             if (t.Equals(typeof(FieldInfo)))
             {
                 MemberTypeIndex = BindingFlagSupport.MemberTypeIndex.Field;
-                Default = (MemberPolicies<M>)(Object)(new FieldPolicies());
+                Default = (MemberPolicies<M>)(object)(new FieldPolicies());
             }
             else if (t.Equals(typeof(MethodInfo)))
             {
                 MemberTypeIndex = BindingFlagSupport.MemberTypeIndex.Method;
-                Default = (MemberPolicies<M>)(Object)(new MethodPolicies());
+                Default = (MemberPolicies<M>)(object)(new MethodPolicies());
             }
             else if (t.Equals(typeof(ConstructorInfo)))
             {
                 MemberTypeIndex = BindingFlagSupport.MemberTypeIndex.Constructor;
-                Default = (MemberPolicies<M>)(Object)(new ConstructorPolicies());
+                Default = (MemberPolicies<M>)(object)(new ConstructorPolicies());
             }
             else if (t.Equals(typeof(PropertyInfo)))
             {
                 MemberTypeIndex = BindingFlagSupport.MemberTypeIndex.Property; ;
-                Default = (MemberPolicies<M>)(Object)(new PropertyPolicies());
+                Default = (MemberPolicies<M>)(object)(new PropertyPolicies());
             }
             else if (t.Equals(typeof(EventInfo)))
             {
                 MemberTypeIndex = BindingFlagSupport.MemberTypeIndex.Event;
-                Default = (MemberPolicies<M>)(Object)(new EventPolicies());
+                Default = (MemberPolicies<M>)(object)(new EventPolicies());
             }
             else if (t.Equals(typeof(Type)))
             {
                 MemberTypeIndex = BindingFlagSupport.MemberTypeIndex.NestedType;
-                Default = (MemberPolicies<M>)(Object)(new NestedTypePolicies());
+                Default = (MemberPolicies<M>)(object)(new NestedTypePolicies());
             }
             else
             {
index 0ff55af..9b65776 100644 (file)
@@ -52,7 +52,7 @@ namespace System.Reflection.Runtime.General
             return _items;
         }
 
-        public void CopyTo(Object[] array, int index)
+        public void CopyTo(object[] array, int index)
         {
             if (_count == 0)
                 return;
index 3b958f8..50971d2 100644 (file)
@@ -38,7 +38,7 @@ namespace System.Reflection.TypeLoading.Ecma
                             result.PointerToResource = blobReader.CurrentPointer;
 
                             // Length check the size of the resource to ensure it fits in the PE file section, note, this is only safe as its in a checked region
-                            if (length + sizeof(Int32) > blobReader.Length)
+                            if (length + sizeof(int) > blobReader.Length)
                                 throw new BadImageFormatException();
                             result.SizeOfResource = length;
                         }
index 73d2521..dbaa46f 100644 (file)
@@ -10,7 +10,7 @@ namespace System.Reflection.Tests
     public static partial class ConstructorTests
     {
         [Fact]
-        public unsafe static void TestConstructors1()
+        public static unsafe void TestConstructors1()
         {
             TestConstructors1Worker(typeof(ClassWithConstructor1<>).Project());
             TestConstructors1Worker(typeof(ClassWithConstructor1<int>).Project());
index ffa1ded..d6f45bc 100644 (file)
@@ -12,7 +12,7 @@ namespace System.Reflection.Tests
     public static partial class FieldTests
     {
         [Fact]
-        public unsafe static void TestFields1()
+        public static unsafe void TestFields1()
         {
             TestField1Worker(typeof(ClassWithFields1<>).Project());
             TestField1Worker(typeof(ClassWithFields1<int>).Project());
@@ -111,7 +111,7 @@ namespace System.Reflection.Tests
         }
 
         [Fact]
-        public unsafe static void TestLiteralFields1()
+        public static unsafe void TestLiteralFields1()
         {
             Type t = typeof(ClassWithLiteralFields).Project();
             FieldInfo[] fields = t.GetFields(BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Static | BindingFlags.DeclaredOnly);
@@ -385,7 +385,7 @@ namespace System.Reflection.Tests
         }
 
         [Fact]
-        public unsafe static void TestCustomModifiers1()
+        public static unsafe void TestCustomModifiers1()
         {
             using (MetadataLoadContext lc = new MetadataLoadContext(
                 new FuncMetadataAssemblyResolver(
@@ -419,7 +419,7 @@ namespace System.Reflection.Tests
         }
 
         [Fact]
-        public unsafe static void TestCustomModifiers2()
+        public static unsafe void TestCustomModifiers2()
         {
             using (MetadataLoadContext lc = new MetadataLoadContext(new CoreMetadataAssemblyResolver(), "mscorlib"))
             {
index 8ce8f83..52d995d 100644 (file)
@@ -12,7 +12,7 @@ namespace System.Reflection.Tests
     public static partial class MethodTests
     {
         [Fact]
-        public unsafe static void TestMethods1()
+        public static unsafe void TestMethods1()
         {
             TestMethods1Worker(typeof(ClassWithMethods1<>).Project());
             TestMethods1Worker(typeof(ClassWithMethods1<int>).Project());
@@ -67,7 +67,7 @@ namespace System.Reflection.Tests
         }
 
         [Fact]
-        public unsafe static void TestAllCoreTypes()
+        public static unsafe void TestAllCoreTypes()
         {
             const BindingFlags bf = BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Instance | BindingFlags.Static | BindingFlags.DeclaredOnly;
             MethodInfo m = typeof(ClassWithMethods1<>).Project().GetMethod("TestPrimitives1", bf);
@@ -245,7 +245,7 @@ namespace System.Reflection.Tests
         }
 
         [Fact]
-        public unsafe static void TestCustomModifiers1()
+        public static unsafe void TestCustomModifiers1()
         {
             using (MetadataLoadContext lc = new MetadataLoadContext(new CoreMetadataAssemblyResolver(), "mscorlib"))
             {
index ad0d076..f68bd36 100644 (file)
@@ -216,7 +216,7 @@ namespace System.Reflection.Tests
         }
 
         [Fact]
-        public unsafe static void TestCustomModifiers1()
+        public static unsafe void TestCustomModifiers1()
         {
             using (MetadataLoadContext lc = new MetadataLoadContext(new CoreMetadataAssemblyResolver(), "mscorlib"))
             {
index da7ec79..f96ea41 100644 (file)
@@ -364,25 +364,25 @@ namespace System.Reflection.Tests
         [Fact]
         public static void TestIsPrimitive()
         {
-            Assert.True(typeof(Boolean).Project().IsPrimitive);
-            Assert.True(typeof(Char).Project().IsPrimitive);
-            Assert.True(typeof(SByte).Project().IsPrimitive);
-            Assert.True(typeof(Byte).Project().IsPrimitive);
-            Assert.True(typeof(Int16).Project().IsPrimitive);
-            Assert.True(typeof(UInt16).Project().IsPrimitive);
-            Assert.True(typeof(Int32).Project().IsPrimitive);
-            Assert.True(typeof(UInt32).Project().IsPrimitive);
-            Assert.True(typeof(Int64).Project().IsPrimitive);
-            Assert.True(typeof(UInt64).Project().IsPrimitive);
-            Assert.True(typeof(Single).Project().IsPrimitive);
-            Assert.True(typeof(Double).Project().IsPrimitive);
+            Assert.True(typeof(bool).Project().IsPrimitive);
+            Assert.True(typeof(char).Project().IsPrimitive);
+            Assert.True(typeof(sbyte).Project().IsPrimitive);
+            Assert.True(typeof(byte).Project().IsPrimitive);
+            Assert.True(typeof(short).Project().IsPrimitive);
+            Assert.True(typeof(ushort).Project().IsPrimitive);
+            Assert.True(typeof(int).Project().IsPrimitive);
+            Assert.True(typeof(uint).Project().IsPrimitive);
+            Assert.True(typeof(long).Project().IsPrimitive);
+            Assert.True(typeof(ulong).Project().IsPrimitive);
+            Assert.True(typeof(float).Project().IsPrimitive);
+            Assert.True(typeof(double).Project().IsPrimitive);
             Assert.True(typeof(IntPtr).Project().IsPrimitive);
             Assert.True(typeof(UIntPtr).Project().IsPrimitive);
 
             Assert.False(typeof(void).Project().IsPrimitive);
-            Assert.False(typeof(Decimal).Project().IsPrimitive);
+            Assert.False(typeof(decimal).Project().IsPrimitive);
             Assert.False(typeof(BindingFlags).Project().IsPrimitive);
-            Assert.False(typeof(Int32[]).Project().IsPrimitive);
+            Assert.False(typeof(int[]).Project().IsPrimitive);
 
             return;
         }
@@ -391,11 +391,11 @@ namespace System.Reflection.Tests
         [Fact]
         public static void TestIsValueType()
         {
-            Assert.True(typeof(Boolean).Project().IsValueType);
-            Assert.False(typeof(Boolean).Project().MakeArrayType().IsValueType);
-            Assert.False(typeof(Boolean).Project().MakeArrayType(1).IsValueType);
-            Assert.False(typeof(Boolean).Project().MakeByRefType().IsValueType);
-            Assert.False(typeof(Boolean).Project().MakePointerType().IsValueType);
+            Assert.True(typeof(bool).Project().IsValueType);
+            Assert.False(typeof(bool).Project().MakeArrayType().IsValueType);
+            Assert.False(typeof(bool).Project().MakeArrayType(1).IsValueType);
+            Assert.False(typeof(bool).Project().MakeByRefType().IsValueType);
+            Assert.False(typeof(bool).Project().MakePointerType().IsValueType);
             Assert.True(typeof(KeyValuePair<,>).Project().IsValueType);
             Assert.True(typeof(KeyValuePair<object, object>).Project().IsValueType);
             Assert.False(typeof(object).Project().IsValueType);
index b41d8d6..946ce72 100644 (file)
@@ -82,13 +82,13 @@ namespace System.Reflection.Tests
     //Metadata for Reflection
     public class TypeInfoEventBaseClass
     {
-        public event EventHandler EventPublic;                                 // inherited
+        public event EventHandler EventPublic;     // inherited
         public static event EventHandler EventPublicStatic;
     }
 
     public class TypeInfoEventSubClass : TypeInfoEventBaseClass
     {
-        public new event EventHandler EventPublic;     //overrides event                               
+        public new event EventHandler EventPublic; //overrides event                
         public event EventHandler EventPublicNew;  // new event
     }
 }
index 033ccb4..54d7943 100644 (file)
@@ -130,10 +130,10 @@ namespace System.Reflection.Tests
 
         public class NestPublic { }
         public class NestPublic2 { }
-        private class NestPrivate { }          // private, so not inherited
-        internal class NestInternal { }                // internal members are not inherited
+        private class NestPrivate { }          // private, so not inherited
+        internal class NestInternal { }        // internal members are not inherited
         protected class NestProtected { }
-        private class NestAssemblyPrivate { }          // same as private, so not inherited
+        private class NestAssemblyPrivate { }  // same as private, so not inherited
     }
 
     public class TestNestDerived : TestNest
index 5d40565..b98f0d0 100644 (file)
@@ -83,7 +83,7 @@ namespace System.Reflection.Tests
             }
 
             if (!found)
-                Assert.False(true, String.Format("Property {0} not found in Type {1}", name, t.Name));
+                Assert.False(true, string.Format("Property {0} not found in Type {1}", name, t.Name));
         }
     } //end class
 
index 2a9d2dc..4374bf6 100644 (file)
@@ -99,7 +99,7 @@ namespace System.Reflection.Tests
         [Fact]
         public static void TestGenericArguments13()
         {
-            VerifyGenericTypeArguments(typeof(Test_SIG<Int32>).Project(), new string[] { "Int32" }, new string[] { "Int32" });
+            VerifyGenericTypeArguments(typeof(Test_SIG<int>).Project(), new string[] { "Int32" }, new string[] { "Int32" });
         }
 
         // Verify Generic Arguments 
@@ -113,7 +113,7 @@ namespace System.Reflection.Tests
         [Fact]
         public static void TestGenericArguments15()
         {
-            VerifyGenericTypeArguments(typeof(Test_SIG2<Int32, string>).Project(), new string[] { "Int32", "String" }, new string[] { "Int32", "String" });
+            VerifyGenericTypeArguments(typeof(Test_SIG2<int, string>).Project(), new string[] { "Int32", "String" }, new string[] { "Int32", "String" });
         }
 
         // Verify Generic Arguments 
index 4ac8c16..db436a9 100644 (file)
@@ -79,7 +79,7 @@ namespace System.Reflection.Tests
         private static void VerifyInterfaces(Type type, params Type[] expected)
         {
             //Fix to initialize Reflection
-            string str = typeof(Object).Project().Name;
+            string str = typeof(object).Project().Name;
 
             TypeInfo typeInfo = type.GetTypeInfo();
             List<Type> list = new List<Type>();
index 7393df8..b6a8f65 100644 (file)
@@ -248,11 +248,11 @@ namespace System.Reflection.Tests
 
         }
         //private helper methods
-        private static void VerifyIsAssignableFrom(string TestName, TypeInfo left, TypeInfo right, Boolean expected)
+        private static void VerifyIsAssignableFrom(string TestName, TypeInfo left, TypeInfo right, bool expected)
         {
             {
                 //Fix to initialize Reflection
-                string str = typeof(Object).Project().Name;
+                string str = typeof(object).Project().Name;
 
                 bool actual = left.IsAssignableFrom(right);
                 Assert.Equal(expected, actual);
index 2466905..596e4d0 100644 (file)
@@ -438,7 +438,7 @@ namespace System.Reflection.Tests
         [Fact]
         public static void TestMakeArrayType2()
         {
-            TypeInfo ti = typeof(Int32).Project().GetTypeInfo();
+            TypeInfo ti = typeof(int).Project().GetTypeInfo();
             Type arraytype = ti.MakeArrayType();
 
             int[] intArray = { 1, 2, 3 };
index 9960b99..533cdd6 100644 (file)
@@ -1610,7 +1610,7 @@ namespace System.Reflection.Tests
         public TI_SubClass(string s) { }
         public TI_SubClass(short i2) { }
 
-        public new event EventHandler EventPublic; // Overrides event                          
+        public new event EventHandler EventPublic; // Overrides event
         public event EventHandler EventPublicNew; // New event
 
         public new static string[] s_arrayField = new string[10];
index 1d5def3..dacdcb8 100644 (file)
@@ -84,7 +84,7 @@ namespace System.Runtime.Caching
         private const int CHANGED = 0x02; // dependency changed
         private const int INVOKED = 0x04; // OnChangedCallback has been invoked
         private const int DISPOSED = 0x08; // Dispose(true) called, or about to be called
-        private readonly static object s_NOT_SET = new object();
+        private static readonly object s_NOT_SET = new object();
 
         private SafeBitVector32 _flags;
         private OnChangedCallback _onChangedCallback;
index 2444fb6..cc3cfee 100644 (file)
@@ -17,7 +17,7 @@ namespace System.Runtime.Caching.Configuration
              <add name="Foo" physicalMemoryPercentage="0" pollingInterval="00:02:00"/>
              <add name="Bar" physicalMemoryPercentage="0" pollingInterval="00:02:00"/>
            </namedCaches>
-            </memoryCaches>
+         </memoryCaches>
        </system.caching>
     */
 
index becad64..7f98cc4 100644 (file)
@@ -318,13 +318,13 @@ namespace MonoTests.System.Runtime.Caching
             // The actual unique id is constructed from key names followed by the hex value of ticks of their last modifed time
             Assert.False(string.IsNullOrEmpty(monitor.UniqueId));
 
-                       monitor = mc.CreateCacheEntryChangeMonitor (new string [] { "key1", "doesnotexist" });
-                       Assert.NotNull (monitor);
-                       Assert.Equal ("System.Runtime.Caching.MemoryCacheEntryChangeMonitor", monitor.GetType ().ToString ());
-                       Assert.Equal (2, monitor.CacheKeys.Count);
-                       Assert.Equal ("key1", monitor.CacheKeys [0]);
-                       Assert.Null (monitor.RegionName);
-                       Assert.True (monitor.HasChanged);
+            monitor = mc.CreateCacheEntryChangeMonitor (new string [] { "key1", "doesnotexist" });
+            Assert.NotNull (monitor);
+            Assert.Equal ("System.Runtime.Caching.MemoryCacheEntryChangeMonitor", monitor.GetType ().ToString ());
+            Assert.Equal (2, monitor.CacheKeys.Count);
+            Assert.Equal ("key1", monitor.CacheKeys [0]);
+            Assert.Null (monitor.RegionName);
+            Assert.True (monitor.HasChanged);
         }
 
         [Fact]
@@ -1372,7 +1372,7 @@ namespace MonoTests.System.Runtime.Caching
 
                 Assert.Equal(HEAP_RESIZE_SHORT_ENTRIES, mc.GetCount());
 
-                // add some long duration entries                              
+                // add some long duration entries                
                 for (int i = 0; i < HEAP_RESIZE_LONG_ENTRIES; i++)
                 {
                     var expireAt = DateTimeOffset.Now.AddSeconds(42);
index b97d9e2..b52a7d2 100644 (file)
@@ -10,39 +10,39 @@ namespace System.Runtime.CompilerServices
     public static partial class Unsafe
     {
         public static ref T AddByteOffset<T>(ref T source, System.IntPtr byteOffset) { throw null; }
-        public unsafe static void* Add<T>(void* source, int elementOffset) { throw null; }
+        public static unsafe void* Add<T>(void* source, int elementOffset) { throw null; }
         public static ref T Add<T>(ref T source, int elementOffset) { throw null; }
         public static ref T Add<T>(ref T source, System.IntPtr elementOffset) { throw null; }
         public static bool AreSame<T>(ref T left, ref T right) { throw null; }
-        public unsafe static void* AsPointer<T>(ref T value) { throw null; }
-        public unsafe static ref T AsRef<T>(void* source) { throw null; }
+        public static unsafe void* AsPointer<T>(ref T value) { throw null; }
+        public static unsafe ref T AsRef<T>(void* source) { throw null; }
         public static ref T AsRef<T>(in T source) { throw null; }
         public static T As<T>(object o) where T : class { throw null; }
         public static ref TTo As<TFrom, TTo>(ref TFrom source) { throw null; }
         public static System.IntPtr ByteOffset<T>(ref T origin, ref T target) { throw null; }
         public static void CopyBlock(ref byte destination, ref byte source, uint byteCount) { }
-        public unsafe static void CopyBlock(void* destination, void* source, uint byteCount) { }
+        public static unsafe void CopyBlock(void* destination, void* source, uint byteCount) { }
         public static void CopyBlockUnaligned(ref byte destination, ref byte source, uint byteCount) { }
-        public unsafe static void CopyBlockUnaligned(void* destination, void* source, uint byteCount) { }
-        public unsafe static void Copy<T>(void* destination, ref T source) { }
-        public unsafe static void Copy<T>(ref T destination, void* source) { }
+        public static unsafe void CopyBlockUnaligned(void* destination, void* source, uint byteCount) { }
+        public static unsafe void Copy<T>(void* destination, ref T source) { }
+        public static unsafe void Copy<T>(ref T destination, void* source) { }
         public static void InitBlock(ref byte startAddress, byte value, uint byteCount) { }
-        public unsafe static void InitBlock(void* startAddress, byte value, uint byteCount) { }
+        public static unsafe void InitBlock(void* startAddress, byte value, uint byteCount) { }
         public static void InitBlockUnaligned(ref byte startAddress, byte value, uint byteCount) { }
-        public unsafe static void InitBlockUnaligned(void* startAddress, byte value, uint byteCount) { }
+        public static unsafe void InitBlockUnaligned(void* startAddress, byte value, uint byteCount) { }
         public static bool IsAddressGreaterThan<T>(ref T left, ref T right) { throw null; }
         public static bool IsAddressLessThan<T>(ref T left, ref T right) { throw null; }
         public static T ReadUnaligned<T>(ref byte source) { throw null; }
-        public unsafe static T ReadUnaligned<T>(void* source) { throw null; }
-        public unsafe static T Read<T>(void* source) { throw null; }
+        public static unsafe T ReadUnaligned<T>(void* source) { throw null; }
+        public static unsafe T Read<T>(void* source) { throw null; }
         public static int SizeOf<T>() { throw null; }
         public static ref T SubtractByteOffset<T>(ref T source, System.IntPtr byteOffset) { throw null; }
-        public unsafe static void* Subtract<T>(void* source, int elementOffset) { throw null; }
+        public static unsafe void* Subtract<T>(void* source, int elementOffset) { throw null; }
         public static ref T Subtract<T>(ref T source, int elementOffset) { throw null; }
         public static ref T Subtract<T>(ref T source, System.IntPtr elementOffset) { throw null; }
         public static ref T Unbox<T>(object box) where T : struct { throw null; }
         public static void WriteUnaligned<T>(ref byte destination, T value) { }
-        public unsafe static void WriteUnaligned<T>(void* destination, T value) { }
-        public unsafe static void Write<T>(void* destination, T value) { }
+        public static unsafe void WriteUnaligned<T>(void* destination, T value) { }
+        public static unsafe void Write<T>(void* destination, T value) { }
     }
 }
index 855c80f..b69c654 100644 (file)
@@ -266,22 +266,22 @@ namespace System.Tests
             }
         }
 
-        private unsafe static bool IsNegativeZero(double value)
+        private static unsafe bool IsNegativeZero(double value)
         {
             return (*(ulong*)(&value)) == 0x8000000000000000;
         }
 
-        private unsafe static bool IsNegativeZero(float value)
+        private static unsafe bool IsNegativeZero(float value)
         {
             return (*(uint*)(&value)) == 0x80000000;
         }
 
-        private unsafe static bool IsPositiveZero(double value)
+        private static unsafe bool IsPositiveZero(double value)
         {
             return (*(ulong*)(&value)) == 0x0000000000000000;
         }
 
-        private unsafe static bool IsPositiveZero(float value)
+        private static unsafe bool IsPositiveZero(float value)
         {
             return (*(uint*)(&value)) == 0x00000000;
         }
index a3c0a83..3f69f49 100644 (file)
@@ -139,12 +139,12 @@ namespace System.Tests
             }
         }
 
-        private unsafe static bool IsNegativeZero(float value)
+        private static unsafe bool IsNegativeZero(float value)
         {
             return (*(uint*)(&value)) == 0x80000000;
         }
 
-        private unsafe static bool IsPositiveZero(float value)
+        private static unsafe bool IsPositiveZero(float value)
         {
             return (*(uint*)(&value)) == 0x00000000;
         }
index bc39065..b79a713 100644 (file)
@@ -328,11 +328,11 @@ namespace System.Runtime.Intrinsics.X86
         public static System.Runtime.Intrinsics.Vector256<float> Blend(System.Runtime.Intrinsics.Vector256<float> left, System.Runtime.Intrinsics.Vector256<float> right, byte control) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<double> BlendVariable(System.Runtime.Intrinsics.Vector256<double> left, System.Runtime.Intrinsics.Vector256<double> right, System.Runtime.Intrinsics.Vector256<double> mask) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<float> BlendVariable(System.Runtime.Intrinsics.Vector256<float> left, System.Runtime.Intrinsics.Vector256<float> right, System.Runtime.Intrinsics.Vector256<float> mask) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<float> BroadcastScalarToVector128(float* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<double> BroadcastScalarToVector256(double* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<float> BroadcastScalarToVector256(float* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<double> BroadcastVector128ToVector256(double* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<float> BroadcastVector128ToVector256(float* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<float> BroadcastScalarToVector128(float* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<double> BroadcastScalarToVector256(double* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<float> BroadcastScalarToVector256(float* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<double> BroadcastVector128ToVector256(double* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<float> BroadcastVector128ToVector256(float* address) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<double> Ceiling(System.Runtime.Intrinsics.Vector256<double> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<float> Ceiling(System.Runtime.Intrinsics.Vector256<float> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<double> Compare(System.Runtime.Intrinsics.Vector128<double> left, System.Runtime.Intrinsics.Vector128<double> right, System.Runtime.Intrinsics.X86.FloatComparisonMode mode) { throw null; }
@@ -381,42 +381,42 @@ namespace System.Runtime.Intrinsics.X86
         public static System.Runtime.Intrinsics.Vector256<ushort> InsertVector128(System.Runtime.Intrinsics.Vector256<ushort> value, System.Runtime.Intrinsics.Vector128<ushort> data, byte index) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<uint> InsertVector128(System.Runtime.Intrinsics.Vector256<uint> value, System.Runtime.Intrinsics.Vector128<uint> data, byte index) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<ulong> InsertVector128(System.Runtime.Intrinsics.Vector256<ulong> value, System.Runtime.Intrinsics.Vector128<ulong> data, byte index) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<byte> LoadAlignedVector256(byte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<double> LoadAlignedVector256(double* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<short> LoadAlignedVector256(short* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<int> LoadAlignedVector256(int* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> LoadAlignedVector256(long* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<sbyte> LoadAlignedVector256(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<float> LoadAlignedVector256(float* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ushort> LoadAlignedVector256(ushort* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<uint> LoadAlignedVector256(uint* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ulong> LoadAlignedVector256(ulong* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<byte> LoadDquVector256(byte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<short> LoadDquVector256(short* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<int> LoadDquVector256(int* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> LoadDquVector256(long* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<sbyte> LoadDquVector256(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ushort> LoadDquVector256(ushort* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<uint> LoadDquVector256(uint* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ulong> LoadDquVector256(ulong* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<byte> LoadVector256(byte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<double> LoadVector256(double* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<short> LoadVector256(short* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<int> LoadVector256(int* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> LoadVector256(long* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<sbyte> LoadVector256(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<float> LoadVector256(float* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ushort> LoadVector256(ushort* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<uint> LoadVector256(uint* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ulong> LoadVector256(ulong* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<double> MaskLoad(double* address, System.Runtime.Intrinsics.Vector128<double> mask) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<double> MaskLoad(double* address, System.Runtime.Intrinsics.Vector256<double> mask) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<float> MaskLoad(float* address, System.Runtime.Intrinsics.Vector128<float> mask) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<float> MaskLoad(float* address, System.Runtime.Intrinsics.Vector256<float> mask) { throw null; }
-        public unsafe static void MaskStore(double* address, System.Runtime.Intrinsics.Vector128<double> mask, System.Runtime.Intrinsics.Vector128<double> source) { }
-        public unsafe static void MaskStore(double* address, System.Runtime.Intrinsics.Vector256<double> mask, System.Runtime.Intrinsics.Vector256<double> source) { }
-        public unsafe static void MaskStore(float* address, System.Runtime.Intrinsics.Vector128<float> mask, System.Runtime.Intrinsics.Vector128<float> source) { }
-        public unsafe static void MaskStore(float* address, System.Runtime.Intrinsics.Vector256<float> mask, System.Runtime.Intrinsics.Vector256<float> source) { }
+        public static unsafe System.Runtime.Intrinsics.Vector256<byte> LoadAlignedVector256(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<double> LoadAlignedVector256(double* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<short> LoadAlignedVector256(short* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<int> LoadAlignedVector256(int* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> LoadAlignedVector256(long* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<sbyte> LoadAlignedVector256(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<float> LoadAlignedVector256(float* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ushort> LoadAlignedVector256(ushort* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<uint> LoadAlignedVector256(uint* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ulong> LoadAlignedVector256(ulong* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<byte> LoadDquVector256(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<short> LoadDquVector256(short* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<int> LoadDquVector256(int* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> LoadDquVector256(long* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<sbyte> LoadDquVector256(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ushort> LoadDquVector256(ushort* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<uint> LoadDquVector256(uint* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ulong> LoadDquVector256(ulong* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<byte> LoadVector256(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<double> LoadVector256(double* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<short> LoadVector256(short* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<int> LoadVector256(int* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> LoadVector256(long* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<sbyte> LoadVector256(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<float> LoadVector256(float* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ushort> LoadVector256(ushort* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<uint> LoadVector256(uint* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ulong> LoadVector256(ulong* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<double> MaskLoad(double* address, System.Runtime.Intrinsics.Vector128<double> mask) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<double> MaskLoad(double* address, System.Runtime.Intrinsics.Vector256<double> mask) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<float> MaskLoad(float* address, System.Runtime.Intrinsics.Vector128<float> mask) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<float> MaskLoad(float* address, System.Runtime.Intrinsics.Vector256<float> mask) { throw null; }
+        public static unsafe void MaskStore(double* address, System.Runtime.Intrinsics.Vector128<double> mask, System.Runtime.Intrinsics.Vector128<double> source) { }
+        public static unsafe void MaskStore(double* address, System.Runtime.Intrinsics.Vector256<double> mask, System.Runtime.Intrinsics.Vector256<double> source) { }
+        public static unsafe void MaskStore(float* address, System.Runtime.Intrinsics.Vector128<float> mask, System.Runtime.Intrinsics.Vector128<float> source) { }
+        public static unsafe void MaskStore(float* address, System.Runtime.Intrinsics.Vector256<float> mask, System.Runtime.Intrinsics.Vector256<float> source) { }
         public static System.Runtime.Intrinsics.Vector256<double> Max(System.Runtime.Intrinsics.Vector256<double> left, System.Runtime.Intrinsics.Vector256<double> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<float> Max(System.Runtime.Intrinsics.Vector256<float> left, System.Runtime.Intrinsics.Vector256<float> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<double> Min(System.Runtime.Intrinsics.Vector256<double> left, System.Runtime.Intrinsics.Vector256<double> right) { throw null; }
@@ -461,36 +461,36 @@ namespace System.Runtime.Intrinsics.X86
         public static System.Runtime.Intrinsics.Vector256<float> Shuffle(System.Runtime.Intrinsics.Vector256<float> value, System.Runtime.Intrinsics.Vector256<float> right, byte control) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<double> Sqrt(System.Runtime.Intrinsics.Vector256<double> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<float> Sqrt(System.Runtime.Intrinsics.Vector256<float> value) { throw null; }
-        public unsafe static void Store(byte* address, System.Runtime.Intrinsics.Vector256<byte> source) { }
-        public unsafe static void Store(double* address, System.Runtime.Intrinsics.Vector256<double> source) { }
-        public unsafe static void Store(short* address, System.Runtime.Intrinsics.Vector256<short> source) { }
-        public unsafe static void Store(int* address, System.Runtime.Intrinsics.Vector256<int> source) { }
-        public unsafe static void Store(long* address, System.Runtime.Intrinsics.Vector256<long> source) { }
-        public unsafe static void Store(sbyte* address, System.Runtime.Intrinsics.Vector256<sbyte> source) { }
-        public unsafe static void Store(float* address, System.Runtime.Intrinsics.Vector256<float> source) { }
-        public unsafe static void Store(ushort* address, System.Runtime.Intrinsics.Vector256<ushort> source) { }
-        public unsafe static void Store(uint* address, System.Runtime.Intrinsics.Vector256<uint> source) { }
-        public unsafe static void Store(ulong* address, System.Runtime.Intrinsics.Vector256<ulong> source) { }
-        public unsafe static void StoreAligned(byte* address, System.Runtime.Intrinsics.Vector256<byte> source) { }
-        public unsafe static void StoreAligned(double* address, System.Runtime.Intrinsics.Vector256<double> source) { }
-        public unsafe static void StoreAligned(short* address, System.Runtime.Intrinsics.Vector256<short> source) { }
-        public unsafe static void StoreAligned(int* address, System.Runtime.Intrinsics.Vector256<int> source) { }
-        public unsafe static void StoreAligned(long* address, System.Runtime.Intrinsics.Vector256<long> source) { }
-        public unsafe static void StoreAligned(sbyte* address, System.Runtime.Intrinsics.Vector256<sbyte> source) { }
-        public unsafe static void StoreAligned(float* address, System.Runtime.Intrinsics.Vector256<float> source) { }
-        public unsafe static void StoreAligned(ushort* address, System.Runtime.Intrinsics.Vector256<ushort> source) { }
-        public unsafe static void StoreAligned(uint* address, System.Runtime.Intrinsics.Vector256<uint> source) { }
-        public unsafe static void StoreAligned(ulong* address, System.Runtime.Intrinsics.Vector256<ulong> source) { }
-        public unsafe static void StoreAlignedNonTemporal(byte* address, System.Runtime.Intrinsics.Vector256<byte> source) { }
-        public unsafe static void StoreAlignedNonTemporal(double* address, System.Runtime.Intrinsics.Vector256<double> source) { }
-        public unsafe static void StoreAlignedNonTemporal(short* address, System.Runtime.Intrinsics.Vector256<short> source) { }
-        public unsafe static void StoreAlignedNonTemporal(int* address, System.Runtime.Intrinsics.Vector256<int> source) { }
-        public unsafe static void StoreAlignedNonTemporal(long* address, System.Runtime.Intrinsics.Vector256<long> source) { }
-        public unsafe static void StoreAlignedNonTemporal(sbyte* address, System.Runtime.Intrinsics.Vector256<sbyte> source) { }
-        public unsafe static void StoreAlignedNonTemporal(float* address, System.Runtime.Intrinsics.Vector256<float> source) { }
-        public unsafe static void StoreAlignedNonTemporal(ushort* address, System.Runtime.Intrinsics.Vector256<ushort> source) { }
-        public unsafe static void StoreAlignedNonTemporal(uint* address, System.Runtime.Intrinsics.Vector256<uint> source) { }
-        public unsafe static void StoreAlignedNonTemporal(ulong* address, System.Runtime.Intrinsics.Vector256<ulong> source) { }
+        public static unsafe void Store(byte* address, System.Runtime.Intrinsics.Vector256<byte> source) { }
+        public static unsafe void Store(double* address, System.Runtime.Intrinsics.Vector256<double> source) { }
+        public static unsafe void Store(short* address, System.Runtime.Intrinsics.Vector256<short> source) { }
+        public static unsafe void Store(int* address, System.Runtime.Intrinsics.Vector256<int> source) { }
+        public static unsafe void Store(long* address, System.Runtime.Intrinsics.Vector256<long> source) { }
+        public static unsafe void Store(sbyte* address, System.Runtime.Intrinsics.Vector256<sbyte> source) { }
+        public static unsafe void Store(float* address, System.Runtime.Intrinsics.Vector256<float> source) { }
+        public static unsafe void Store(ushort* address, System.Runtime.Intrinsics.Vector256<ushort> source) { }
+        public static unsafe void Store(uint* address, System.Runtime.Intrinsics.Vector256<uint> source) { }
+        public static unsafe void Store(ulong* address, System.Runtime.Intrinsics.Vector256<ulong> source) { }
+        public static unsafe void StoreAligned(byte* address, System.Runtime.Intrinsics.Vector256<byte> source) { }
+        public static unsafe void StoreAligned(double* address, System.Runtime.Intrinsics.Vector256<double> source) { }
+        public static unsafe void StoreAligned(short* address, System.Runtime.Intrinsics.Vector256<short> source) { }
+        public static unsafe void StoreAligned(int* address, System.Runtime.Intrinsics.Vector256<int> source) { }
+        public static unsafe void StoreAligned(long* address, System.Runtime.Intrinsics.Vector256<long> source) { }
+        public static unsafe void StoreAligned(sbyte* address, System.Runtime.Intrinsics.Vector256<sbyte> source) { }
+        public static unsafe void StoreAligned(float* address, System.Runtime.Intrinsics.Vector256<float> source) { }
+        public static unsafe void StoreAligned(ushort* address, System.Runtime.Intrinsics.Vector256<ushort> source) { }
+        public static unsafe void StoreAligned(uint* address, System.Runtime.Intrinsics.Vector256<uint> source) { }
+        public static unsafe void StoreAligned(ulong* address, System.Runtime.Intrinsics.Vector256<ulong> source) { }
+        public static unsafe void StoreAlignedNonTemporal(byte* address, System.Runtime.Intrinsics.Vector256<byte> source) { }
+        public static unsafe void StoreAlignedNonTemporal(double* address, System.Runtime.Intrinsics.Vector256<double> source) { }
+        public static unsafe void StoreAlignedNonTemporal(short* address, System.Runtime.Intrinsics.Vector256<short> source) { }
+        public static unsafe void StoreAlignedNonTemporal(int* address, System.Runtime.Intrinsics.Vector256<int> source) { }
+        public static unsafe void StoreAlignedNonTemporal(long* address, System.Runtime.Intrinsics.Vector256<long> source) { }
+        public static unsafe void StoreAlignedNonTemporal(sbyte* address, System.Runtime.Intrinsics.Vector256<sbyte> source) { }
+        public static unsafe void StoreAlignedNonTemporal(float* address, System.Runtime.Intrinsics.Vector256<float> source) { }
+        public static unsafe void StoreAlignedNonTemporal(ushort* address, System.Runtime.Intrinsics.Vector256<ushort> source) { }
+        public static unsafe void StoreAlignedNonTemporal(uint* address, System.Runtime.Intrinsics.Vector256<uint> source) { }
+        public static unsafe void StoreAlignedNonTemporal(ulong* address, System.Runtime.Intrinsics.Vector256<ulong> source) { }
         public static System.Runtime.Intrinsics.Vector256<double> Subtract(System.Runtime.Intrinsics.Vector256<double> left, System.Runtime.Intrinsics.Vector256<double> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<float> Subtract(System.Runtime.Intrinsics.Vector256<float> left, System.Runtime.Intrinsics.Vector256<float> right) { throw null; }
         public static bool TestC(System.Runtime.Intrinsics.Vector128<double> left, System.Runtime.Intrinsics.Vector128<double> right) { throw null; }
@@ -596,10 +596,10 @@ namespace System.Runtime.Intrinsics.X86
         public static System.Runtime.Intrinsics.Vector256<ushort> BlendVariable(System.Runtime.Intrinsics.Vector256<ushort> left, System.Runtime.Intrinsics.Vector256<ushort> right, System.Runtime.Intrinsics.Vector256<ushort> mask) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<uint> BlendVariable(System.Runtime.Intrinsics.Vector256<uint> left, System.Runtime.Intrinsics.Vector256<uint> right, System.Runtime.Intrinsics.Vector256<uint> mask) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<ulong> BlendVariable(System.Runtime.Intrinsics.Vector256<ulong> left, System.Runtime.Intrinsics.Vector256<ulong> right, System.Runtime.Intrinsics.Vector256<ulong> mask) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<byte> BroadcastScalarToVector128(byte* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<short> BroadcastScalarToVector128(short* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> BroadcastScalarToVector128(int* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> BroadcastScalarToVector128(long* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<byte> BroadcastScalarToVector128(byte* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<short> BroadcastScalarToVector128(short* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> BroadcastScalarToVector128(int* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> BroadcastScalarToVector128(long* source) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<byte> BroadcastScalarToVector128(System.Runtime.Intrinsics.Vector128<byte> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<double> BroadcastScalarToVector128(System.Runtime.Intrinsics.Vector128<double> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<short> BroadcastScalarToVector128(System.Runtime.Intrinsics.Vector128<short> value) { throw null; }
@@ -610,14 +610,14 @@ namespace System.Runtime.Intrinsics.X86
         public static System.Runtime.Intrinsics.Vector128<ushort> BroadcastScalarToVector128(System.Runtime.Intrinsics.Vector128<ushort> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<uint> BroadcastScalarToVector128(System.Runtime.Intrinsics.Vector128<uint> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<ulong> BroadcastScalarToVector128(System.Runtime.Intrinsics.Vector128<ulong> value) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<sbyte> BroadcastScalarToVector128(sbyte* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ushort> BroadcastScalarToVector128(ushort* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<uint> BroadcastScalarToVector128(uint* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ulong> BroadcastScalarToVector128(ulong* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<byte> BroadcastScalarToVector256(byte* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<short> BroadcastScalarToVector256(short* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<int> BroadcastScalarToVector256(int* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> BroadcastScalarToVector256(long* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<sbyte> BroadcastScalarToVector128(sbyte* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ushort> BroadcastScalarToVector128(ushort* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<uint> BroadcastScalarToVector128(uint* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ulong> BroadcastScalarToVector128(ulong* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<byte> BroadcastScalarToVector256(byte* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<short> BroadcastScalarToVector256(short* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<int> BroadcastScalarToVector256(int* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> BroadcastScalarToVector256(long* source) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<byte> BroadcastScalarToVector256(System.Runtime.Intrinsics.Vector128<byte> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<double> BroadcastScalarToVector256(System.Runtime.Intrinsics.Vector128<double> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<short> BroadcastScalarToVector256(System.Runtime.Intrinsics.Vector128<short> value) { throw null; }
@@ -628,18 +628,18 @@ namespace System.Runtime.Intrinsics.X86
         public static System.Runtime.Intrinsics.Vector256<ushort> BroadcastScalarToVector256(System.Runtime.Intrinsics.Vector128<ushort> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<uint> BroadcastScalarToVector256(System.Runtime.Intrinsics.Vector128<uint> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<ulong> BroadcastScalarToVector256(System.Runtime.Intrinsics.Vector128<ulong> value) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<sbyte> BroadcastScalarToVector256(sbyte* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ushort> BroadcastScalarToVector256(ushort* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<uint> BroadcastScalarToVector256(uint* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ulong> BroadcastScalarToVector256(ulong* source) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<byte> BroadcastVector128ToVector256(byte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<short> BroadcastVector128ToVector256(short* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<int> BroadcastVector128ToVector256(int* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> BroadcastVector128ToVector256(long* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<sbyte> BroadcastVector128ToVector256(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ushort> BroadcastVector128ToVector256(ushort* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<uint> BroadcastVector128ToVector256(uint* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ulong> BroadcastVector128ToVector256(ulong* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<sbyte> BroadcastScalarToVector256(sbyte* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ushort> BroadcastScalarToVector256(ushort* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<uint> BroadcastScalarToVector256(uint* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ulong> BroadcastScalarToVector256(ulong* source) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<byte> BroadcastVector128ToVector256(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<short> BroadcastVector128ToVector256(short* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<int> BroadcastVector128ToVector256(int* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> BroadcastVector128ToVector256(long* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<sbyte> BroadcastVector128ToVector256(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ushort> BroadcastVector128ToVector256(ushort* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<uint> BroadcastVector128ToVector256(uint* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ulong> BroadcastVector128ToVector256(ulong* address) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<byte> CompareEqual(System.Runtime.Intrinsics.Vector256<byte> left, System.Runtime.Intrinsics.Vector256<byte> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<short> CompareEqual(System.Runtime.Intrinsics.Vector256<short> left, System.Runtime.Intrinsics.Vector256<short> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<int> CompareEqual(System.Runtime.Intrinsics.Vector256<int> left, System.Runtime.Intrinsics.Vector256<int> right) { throw null; }
@@ -654,30 +654,30 @@ namespace System.Runtime.Intrinsics.X86
         public static System.Runtime.Intrinsics.Vector256<sbyte> CompareGreaterThan(System.Runtime.Intrinsics.Vector256<sbyte> left, System.Runtime.Intrinsics.Vector256<sbyte> right) { throw null; }
         public static int ConvertToInt32(System.Runtime.Intrinsics.Vector256<int> value) { throw null; }
         public static uint ConvertToUInt32(System.Runtime.Intrinsics.Vector256<uint> value) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<short> ConvertToVector256Int16(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<short> ConvertToVector256Int16(byte* address) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<short> ConvertToVector256Int16(System.Runtime.Intrinsics.Vector128<byte> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<short> ConvertToVector256Int16(System.Runtime.Intrinsics.Vector128<sbyte> value) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<short> ConvertToVector256Int16(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<int> ConvertToVector256Int32(byte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<int> ConvertToVector256Int32(short* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<short> ConvertToVector256Int16(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<int> ConvertToVector256Int32(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<int> ConvertToVector256Int32(short* address) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<int> ConvertToVector256Int32(System.Runtime.Intrinsics.Vector128<byte> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<int> ConvertToVector256Int32(System.Runtime.Intrinsics.Vector128<short> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<int> ConvertToVector256Int32(System.Runtime.Intrinsics.Vector128<sbyte> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<int> ConvertToVector256Int32(System.Runtime.Intrinsics.Vector128<ushort> value) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<int> ConvertToVector256Int32(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<int> ConvertToVector256Int32(ushort* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(byte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(short* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(int* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<int> ConvertToVector256Int32(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<int> ConvertToVector256Int32(ushort* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(short* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(int* address) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(System.Runtime.Intrinsics.Vector128<byte> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(System.Runtime.Intrinsics.Vector128<short> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(System.Runtime.Intrinsics.Vector128<int> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(System.Runtime.Intrinsics.Vector128<sbyte> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(System.Runtime.Intrinsics.Vector128<ushort> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(System.Runtime.Intrinsics.Vector128<uint> value) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(ushort* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(uint* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(ushort* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> ConvertToVector256Int64(uint* address) { throw null; }
         public static new System.Runtime.Intrinsics.Vector128<byte> ExtractVector128(System.Runtime.Intrinsics.Vector256<byte> value, byte index) { throw null; }
         public static new System.Runtime.Intrinsics.Vector128<short> ExtractVector128(System.Runtime.Intrinsics.Vector256<short> value, byte index) { throw null; }
         public static new System.Runtime.Intrinsics.Vector128<int> ExtractVector128(System.Runtime.Intrinsics.Vector256<int> value, byte index) { throw null; }
@@ -686,54 +686,54 @@ namespace System.Runtime.Intrinsics.X86
         public static new System.Runtime.Intrinsics.Vector128<ushort> ExtractVector128(System.Runtime.Intrinsics.Vector256<ushort> value, byte index) { throw null; }
         public static new System.Runtime.Intrinsics.Vector128<uint> ExtractVector128(System.Runtime.Intrinsics.Vector256<uint> value, byte index) { throw null; }
         public static new System.Runtime.Intrinsics.Vector128<ulong> ExtractVector128(System.Runtime.Intrinsics.Vector256<ulong> value, byte index) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<double> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<double> source, double* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector128<double> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<double> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<double> source, double* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, System.Runtime.Intrinsics.Vector128<double> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<int> source, int* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector128<int> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<int> source, int* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, System.Runtime.Intrinsics.Vector128<int> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<int> source, int* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, System.Runtime.Intrinsics.Vector128<int> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<long> source, long* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector128<long> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<long> source, long* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, System.Runtime.Intrinsics.Vector128<long> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<float> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<float> source, float* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector128<float> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<float> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<float> source, float* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, System.Runtime.Intrinsics.Vector128<float> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<float> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<float> source, float* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, System.Runtime.Intrinsics.Vector128<float> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<uint> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<uint> source, uint* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector128<uint> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<uint> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<uint> source, uint* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, System.Runtime.Intrinsics.Vector128<uint> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<uint> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<uint> source, uint* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, System.Runtime.Intrinsics.Vector128<uint> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ulong> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<ulong> source, ulong* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector128<ulong> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ulong> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<ulong> source, ulong* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, System.Runtime.Intrinsics.Vector128<ulong> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<double> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<double> source, double* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector256<double> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<double> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<double> source, double* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, System.Runtime.Intrinsics.Vector256<double> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<int> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<int> source, int* baseAddress, System.Runtime.Intrinsics.Vector256<int> index, System.Runtime.Intrinsics.Vector256<int> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<long> source, long* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector256<long> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<long> source, long* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, System.Runtime.Intrinsics.Vector256<long> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<float> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<float> source, float* baseAddress, System.Runtime.Intrinsics.Vector256<int> index, System.Runtime.Intrinsics.Vector256<float> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<uint> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<uint> source, uint* baseAddress, System.Runtime.Intrinsics.Vector256<int> index, System.Runtime.Intrinsics.Vector256<uint> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ulong> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<ulong> source, ulong* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector256<ulong> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ulong> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<ulong> source, ulong* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, System.Runtime.Intrinsics.Vector256<ulong> mask, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<double> GatherVector128(double* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<double> GatherVector128(double* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> GatherVector128(int* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> GatherVector128(int* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> GatherVector128(int* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> GatherVector128(long* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> GatherVector128(long* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<float> GatherVector128(float* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<float> GatherVector128(float* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<float> GatherVector128(float* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<uint> GatherVector128(uint* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<uint> GatherVector128(uint* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<uint> GatherVector128(uint* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ulong> GatherVector128(ulong* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ulong> GatherVector128(ulong* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<double> GatherVector256(double* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<double> GatherVector256(double* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<int> GatherVector256(int* baseAddress, System.Runtime.Intrinsics.Vector256<int> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> GatherVector256(long* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> GatherVector256(long* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<float> GatherVector256(float* baseAddress, System.Runtime.Intrinsics.Vector256<int> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<uint> GatherVector256(uint* baseAddress, System.Runtime.Intrinsics.Vector256<int> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ulong> GatherVector256(ulong* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ulong> GatherVector256(ulong* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<double> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<double> source, double* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector128<double> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<double> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<double> source, double* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, System.Runtime.Intrinsics.Vector128<double> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<int> source, int* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector128<int> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<int> source, int* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, System.Runtime.Intrinsics.Vector128<int> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<int> source, int* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, System.Runtime.Intrinsics.Vector128<int> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<long> source, long* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector128<long> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<long> source, long* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, System.Runtime.Intrinsics.Vector128<long> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<float> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<float> source, float* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector128<float> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<float> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<float> source, float* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, System.Runtime.Intrinsics.Vector128<float> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<float> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<float> source, float* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, System.Runtime.Intrinsics.Vector128<float> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<uint> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<uint> source, uint* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector128<uint> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<uint> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<uint> source, uint* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, System.Runtime.Intrinsics.Vector128<uint> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<uint> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<uint> source, uint* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, System.Runtime.Intrinsics.Vector128<uint> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ulong> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<ulong> source, ulong* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector128<ulong> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ulong> GatherMaskVector128(System.Runtime.Intrinsics.Vector128<ulong> source, ulong* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, System.Runtime.Intrinsics.Vector128<ulong> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<double> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<double> source, double* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector256<double> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<double> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<double> source, double* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, System.Runtime.Intrinsics.Vector256<double> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<int> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<int> source, int* baseAddress, System.Runtime.Intrinsics.Vector256<int> index, System.Runtime.Intrinsics.Vector256<int> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<long> source, long* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector256<long> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<long> source, long* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, System.Runtime.Intrinsics.Vector256<long> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<float> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<float> source, float* baseAddress, System.Runtime.Intrinsics.Vector256<int> index, System.Runtime.Intrinsics.Vector256<float> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<uint> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<uint> source, uint* baseAddress, System.Runtime.Intrinsics.Vector256<int> index, System.Runtime.Intrinsics.Vector256<uint> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ulong> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<ulong> source, ulong* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, System.Runtime.Intrinsics.Vector256<ulong> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ulong> GatherMaskVector256(System.Runtime.Intrinsics.Vector256<ulong> source, ulong* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, System.Runtime.Intrinsics.Vector256<ulong> mask, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<double> GatherVector128(double* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<double> GatherVector128(double* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> GatherVector128(int* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> GatherVector128(int* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> GatherVector128(int* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> GatherVector128(long* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> GatherVector128(long* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<float> GatherVector128(float* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<float> GatherVector128(float* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<float> GatherVector128(float* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<uint> GatherVector128(uint* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<uint> GatherVector128(uint* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<uint> GatherVector128(uint* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ulong> GatherVector128(ulong* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ulong> GatherVector128(ulong* baseAddress, System.Runtime.Intrinsics.Vector128<long> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<double> GatherVector256(double* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<double> GatherVector256(double* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<int> GatherVector256(int* baseAddress, System.Runtime.Intrinsics.Vector256<int> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> GatherVector256(long* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> GatherVector256(long* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<float> GatherVector256(float* baseAddress, System.Runtime.Intrinsics.Vector256<int> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<uint> GatherVector256(uint* baseAddress, System.Runtime.Intrinsics.Vector256<int> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ulong> GatherVector256(ulong* baseAddress, System.Runtime.Intrinsics.Vector128<int> index, byte scale) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ulong> GatherVector256(ulong* baseAddress, System.Runtime.Intrinsics.Vector256<long> index, byte scale) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<short> HorizontalAdd(System.Runtime.Intrinsics.Vector256<short> left, System.Runtime.Intrinsics.Vector256<short> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<int> HorizontalAdd(System.Runtime.Intrinsics.Vector256<int> left, System.Runtime.Intrinsics.Vector256<int> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<short> HorizontalAddSaturate(System.Runtime.Intrinsics.Vector256<short> left, System.Runtime.Intrinsics.Vector256<short> right) { throw null; }
@@ -748,30 +748,30 @@ namespace System.Runtime.Intrinsics.X86
         public static new System.Runtime.Intrinsics.Vector256<ushort> InsertVector128(System.Runtime.Intrinsics.Vector256<ushort> value, System.Runtime.Intrinsics.Vector128<ushort> data, byte index) { throw null; }
         public static new System.Runtime.Intrinsics.Vector256<uint> InsertVector128(System.Runtime.Intrinsics.Vector256<uint> value, System.Runtime.Intrinsics.Vector128<uint> data, byte index) { throw null; }
         public static new System.Runtime.Intrinsics.Vector256<ulong> InsertVector128(System.Runtime.Intrinsics.Vector256<ulong> value, System.Runtime.Intrinsics.Vector128<ulong> data, byte index) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<byte> LoadAlignedVector256NonTemporal(byte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<short> LoadAlignedVector256NonTemporal(short* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<int> LoadAlignedVector256NonTemporal(int* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> LoadAlignedVector256NonTemporal(long* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<sbyte> LoadAlignedVector256NonTemporal(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ushort> LoadAlignedVector256NonTemporal(ushort* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<uint> LoadAlignedVector256NonTemporal(uint* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ulong> LoadAlignedVector256NonTemporal(ulong* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> MaskLoad(int* address, System.Runtime.Intrinsics.Vector128<int> mask) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<int> MaskLoad(int* address, System.Runtime.Intrinsics.Vector256<int> mask) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> MaskLoad(long* address, System.Runtime.Intrinsics.Vector128<long> mask) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<long> MaskLoad(long* address, System.Runtime.Intrinsics.Vector256<long> mask) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<uint> MaskLoad(uint* address, System.Runtime.Intrinsics.Vector128<uint> mask) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<uint> MaskLoad(uint* address, System.Runtime.Intrinsics.Vector256<uint> mask) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ulong> MaskLoad(ulong* address, System.Runtime.Intrinsics.Vector128<ulong> mask) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector256<ulong> MaskLoad(ulong* address, System.Runtime.Intrinsics.Vector256<ulong> mask) { throw null; }
-        public unsafe static void MaskStore(int* address, System.Runtime.Intrinsics.Vector128<int> mask, System.Runtime.Intrinsics.Vector128<int> source) { }
-        public unsafe static void MaskStore(int* address, System.Runtime.Intrinsics.Vector256<int> mask, System.Runtime.Intrinsics.Vector256<int> source) { }
-        public unsafe static void MaskStore(long* address, System.Runtime.Intrinsics.Vector128<long> mask, System.Runtime.Intrinsics.Vector128<long> source) { }
-        public unsafe static void MaskStore(long* address, System.Runtime.Intrinsics.Vector256<long> mask, System.Runtime.Intrinsics.Vector256<long> source) { }
-        public unsafe static void MaskStore(uint* address, System.Runtime.Intrinsics.Vector128<uint> mask, System.Runtime.Intrinsics.Vector128<uint> source) { }
-        public unsafe static void MaskStore(uint* address, System.Runtime.Intrinsics.Vector256<uint> mask, System.Runtime.Intrinsics.Vector256<uint> source) { }
-        public unsafe static void MaskStore(ulong* address, System.Runtime.Intrinsics.Vector128<ulong> mask, System.Runtime.Intrinsics.Vector128<ulong> source) { }
-        public unsafe static void MaskStore(ulong* address, System.Runtime.Intrinsics.Vector256<ulong> mask, System.Runtime.Intrinsics.Vector256<ulong> source) { }
+        public static unsafe System.Runtime.Intrinsics.Vector256<byte> LoadAlignedVector256NonTemporal(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<short> LoadAlignedVector256NonTemporal(short* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<int> LoadAlignedVector256NonTemporal(int* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> LoadAlignedVector256NonTemporal(long* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<sbyte> LoadAlignedVector256NonTemporal(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ushort> LoadAlignedVector256NonTemporal(ushort* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<uint> LoadAlignedVector256NonTemporal(uint* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ulong> LoadAlignedVector256NonTemporal(ulong* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> MaskLoad(int* address, System.Runtime.Intrinsics.Vector128<int> mask) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<int> MaskLoad(int* address, System.Runtime.Intrinsics.Vector256<int> mask) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> MaskLoad(long* address, System.Runtime.Intrinsics.Vector128<long> mask) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<long> MaskLoad(long* address, System.Runtime.Intrinsics.Vector256<long> mask) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<uint> MaskLoad(uint* address, System.Runtime.Intrinsics.Vector128<uint> mask) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<uint> MaskLoad(uint* address, System.Runtime.Intrinsics.Vector256<uint> mask) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ulong> MaskLoad(ulong* address, System.Runtime.Intrinsics.Vector128<ulong> mask) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector256<ulong> MaskLoad(ulong* address, System.Runtime.Intrinsics.Vector256<ulong> mask) { throw null; }
+        public static unsafe void MaskStore(int* address, System.Runtime.Intrinsics.Vector128<int> mask, System.Runtime.Intrinsics.Vector128<int> source) { }
+        public static unsafe void MaskStore(int* address, System.Runtime.Intrinsics.Vector256<int> mask, System.Runtime.Intrinsics.Vector256<int> source) { }
+        public static unsafe void MaskStore(long* address, System.Runtime.Intrinsics.Vector128<long> mask, System.Runtime.Intrinsics.Vector128<long> source) { }
+        public static unsafe void MaskStore(long* address, System.Runtime.Intrinsics.Vector256<long> mask, System.Runtime.Intrinsics.Vector256<long> source) { }
+        public static unsafe void MaskStore(uint* address, System.Runtime.Intrinsics.Vector128<uint> mask, System.Runtime.Intrinsics.Vector128<uint> source) { }
+        public static unsafe void MaskStore(uint* address, System.Runtime.Intrinsics.Vector256<uint> mask, System.Runtime.Intrinsics.Vector256<uint> source) { }
+        public static unsafe void MaskStore(ulong* address, System.Runtime.Intrinsics.Vector128<ulong> mask, System.Runtime.Intrinsics.Vector128<ulong> source) { }
+        public static unsafe void MaskStore(ulong* address, System.Runtime.Intrinsics.Vector256<ulong> mask, System.Runtime.Intrinsics.Vector256<ulong> source) { }
         public static System.Runtime.Intrinsics.Vector256<byte> Max(System.Runtime.Intrinsics.Vector256<byte> left, System.Runtime.Intrinsics.Vector256<byte> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<short> Max(System.Runtime.Intrinsics.Vector256<short> left, System.Runtime.Intrinsics.Vector256<short> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector256<int> Max(System.Runtime.Intrinsics.Vector256<int> left, System.Runtime.Intrinsics.Vector256<int> right) { throw null; }
@@ -966,7 +966,7 @@ namespace System.Runtime.Intrinsics.X86
         internal Bmi2() { }
         public static bool IsSupported { get { throw null; } }
         public static uint MultiplyNoFlags(uint left, uint right) { throw null; }
-        public unsafe static uint MultiplyNoFlags(uint left, uint right, uint* low) { throw null; }
+        public static unsafe uint MultiplyNoFlags(uint left, uint right, uint* low) { throw null; }
         public static uint ParallelBitDeposit(uint value, uint mask) { throw null; }
         public static uint ParallelBitExtract(uint value, uint mask) { throw null; }
         public static uint ZeroHighBits(uint value, uint index) { throw null; }
@@ -975,7 +975,7 @@ namespace System.Runtime.Intrinsics.X86
             internal X64() { }
             public static bool IsSupported { get { throw null; } }
             public static ulong MultiplyNoFlags(ulong left, ulong right) { throw null; }
-            public unsafe static ulong MultiplyNoFlags(ulong left, ulong right, ulong* low) { throw null; }
+            public static unsafe ulong MultiplyNoFlags(ulong left, ulong right, ulong* low) { throw null; }
             public static ulong ParallelBitDeposit(ulong value, ulong mask) { throw null; }
             public static ulong ParallelBitExtract(ulong value, ulong mask) { throw null; }
             public static ulong ZeroHighBits(ulong value, ulong index) { throw null; }
@@ -1138,11 +1138,11 @@ namespace System.Runtime.Intrinsics.X86
         public static int ConvertToInt32WithTruncation(System.Runtime.Intrinsics.Vector128<float> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> Divide(System.Runtime.Intrinsics.Vector128<float> left, System.Runtime.Intrinsics.Vector128<float> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> DivideScalar(System.Runtime.Intrinsics.Vector128<float> left, System.Runtime.Intrinsics.Vector128<float> right) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<float> LoadAlignedVector128(float* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<float> LoadHigh(System.Runtime.Intrinsics.Vector128<float> lower, float* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<float> LoadLow(System.Runtime.Intrinsics.Vector128<float> upper, float* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<float> LoadScalarVector128(float* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<float> LoadVector128(float* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<float> LoadAlignedVector128(float* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<float> LoadHigh(System.Runtime.Intrinsics.Vector128<float> lower, float* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<float> LoadLow(System.Runtime.Intrinsics.Vector128<float> upper, float* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<float> LoadScalarVector128(float* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<float> LoadVector128(float* address) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> Max(System.Runtime.Intrinsics.Vector128<float> left, System.Runtime.Intrinsics.Vector128<float> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> MaxScalar(System.Runtime.Intrinsics.Vector128<float> left, System.Runtime.Intrinsics.Vector128<float> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> Min(System.Runtime.Intrinsics.Vector128<float> left, System.Runtime.Intrinsics.Vector128<float> right) { throw null; }
@@ -1154,10 +1154,10 @@ namespace System.Runtime.Intrinsics.X86
         public static System.Runtime.Intrinsics.Vector128<float> Multiply(System.Runtime.Intrinsics.Vector128<float> left, System.Runtime.Intrinsics.Vector128<float> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> MultiplyScalar(System.Runtime.Intrinsics.Vector128<float> left, System.Runtime.Intrinsics.Vector128<float> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> Or(System.Runtime.Intrinsics.Vector128<float> left, System.Runtime.Intrinsics.Vector128<float> right) { throw null; }
-        public unsafe static void Prefetch0(void* address) { }
-        public unsafe static void Prefetch1(void* address) { }
-        public unsafe static void Prefetch2(void* address) { }
-        public unsafe static void PrefetchNonTemporal(void* address) { }
+        public static unsafe void Prefetch0(void* address) { }
+        public static unsafe void Prefetch1(void* address) { }
+        public static unsafe void Prefetch2(void* address) { }
+        public static unsafe void PrefetchNonTemporal(void* address) { }
         public static System.Runtime.Intrinsics.Vector128<float> Reciprocal(System.Runtime.Intrinsics.Vector128<float> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> ReciprocalScalar(System.Runtime.Intrinsics.Vector128<float> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> ReciprocalScalar(System.Runtime.Intrinsics.Vector128<float> upper, System.Runtime.Intrinsics.Vector128<float> value) { throw null; }
@@ -1168,13 +1168,13 @@ namespace System.Runtime.Intrinsics.X86
         public static System.Runtime.Intrinsics.Vector128<float> Sqrt(System.Runtime.Intrinsics.Vector128<float> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> SqrtScalar(System.Runtime.Intrinsics.Vector128<float> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> SqrtScalar(System.Runtime.Intrinsics.Vector128<float> upper, System.Runtime.Intrinsics.Vector128<float> value) { throw null; }
-        public unsafe static void Store(float* address, System.Runtime.Intrinsics.Vector128<float> source) { }
-        public unsafe static void StoreAligned(float* address, System.Runtime.Intrinsics.Vector128<float> source) { }
-        public unsafe static void StoreAlignedNonTemporal(float* address, System.Runtime.Intrinsics.Vector128<float> source) { }
+        public static unsafe void Store(float* address, System.Runtime.Intrinsics.Vector128<float> source) { }
+        public static unsafe void StoreAligned(float* address, System.Runtime.Intrinsics.Vector128<float> source) { }
+        public static unsafe void StoreAlignedNonTemporal(float* address, System.Runtime.Intrinsics.Vector128<float> source) { }
         public static void StoreFence() { }
-        public unsafe static void StoreHigh(float* address, System.Runtime.Intrinsics.Vector128<float> source) { }
-        public unsafe static void StoreLow(float* address, System.Runtime.Intrinsics.Vector128<float> source) { }
-        public unsafe static void StoreScalar(float* address, System.Runtime.Intrinsics.Vector128<float> source) { }
+        public static unsafe void StoreHigh(float* address, System.Runtime.Intrinsics.Vector128<float> source) { }
+        public static unsafe void StoreLow(float* address, System.Runtime.Intrinsics.Vector128<float> source) { }
+        public static unsafe void StoreScalar(float* address, System.Runtime.Intrinsics.Vector128<float> source) { }
         public static System.Runtime.Intrinsics.Vector128<float> Subtract(System.Runtime.Intrinsics.Vector128<float> left, System.Runtime.Intrinsics.Vector128<float> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> SubtractScalar(System.Runtime.Intrinsics.Vector128<float> left, System.Runtime.Intrinsics.Vector128<float> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> UnpackHigh(System.Runtime.Intrinsics.Vector128<float> left, System.Runtime.Intrinsics.Vector128<float> right) { throw null; }
@@ -1298,34 +1298,34 @@ namespace System.Runtime.Intrinsics.X86
         public static ushort Extract(System.Runtime.Intrinsics.Vector128<ushort> value, byte index) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<short> Insert(System.Runtime.Intrinsics.Vector128<short> value, short data, byte index) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<ushort> Insert(System.Runtime.Intrinsics.Vector128<ushort> value, ushort data, byte index) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<byte> LoadAlignedVector128(byte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<double> LoadAlignedVector128(double* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<short> LoadAlignedVector128(short* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> LoadAlignedVector128(int* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> LoadAlignedVector128(long* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<sbyte> LoadAlignedVector128(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ushort> LoadAlignedVector128(ushort* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<uint> LoadAlignedVector128(uint* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ulong> LoadAlignedVector128(ulong* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<byte> LoadAlignedVector128(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<double> LoadAlignedVector128(double* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<short> LoadAlignedVector128(short* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> LoadAlignedVector128(int* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> LoadAlignedVector128(long* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<sbyte> LoadAlignedVector128(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ushort> LoadAlignedVector128(ushort* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<uint> LoadAlignedVector128(uint* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ulong> LoadAlignedVector128(ulong* address) { throw null; }
         public static void LoadFence() { }
-        public unsafe static System.Runtime.Intrinsics.Vector128<double> LoadHigh(System.Runtime.Intrinsics.Vector128<double> lower, double* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<double> LoadLow(System.Runtime.Intrinsics.Vector128<double> upper, double* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<double> LoadScalarVector128(double* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> LoadScalarVector128(int* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> LoadScalarVector128(long* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<uint> LoadScalarVector128(uint* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ulong> LoadScalarVector128(ulong* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<byte> LoadVector128(byte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<double> LoadVector128(double* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<short> LoadVector128(short* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> LoadVector128(int* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> LoadVector128(long* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<sbyte> LoadVector128(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ushort> LoadVector128(ushort* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<uint> LoadVector128(uint* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ulong> LoadVector128(ulong* address) { throw null; }
-        public unsafe static void MaskMove(System.Runtime.Intrinsics.Vector128<byte> source, System.Runtime.Intrinsics.Vector128<byte> mask, byte* address) { }
-        public unsafe static void MaskMove(System.Runtime.Intrinsics.Vector128<sbyte> source, System.Runtime.Intrinsics.Vector128<sbyte> mask, sbyte* address) { }
+        public static unsafe System.Runtime.Intrinsics.Vector128<double> LoadHigh(System.Runtime.Intrinsics.Vector128<double> lower, double* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<double> LoadLow(System.Runtime.Intrinsics.Vector128<double> upper, double* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<double> LoadScalarVector128(double* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> LoadScalarVector128(int* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> LoadScalarVector128(long* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<uint> LoadScalarVector128(uint* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ulong> LoadScalarVector128(ulong* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<byte> LoadVector128(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<double> LoadVector128(double* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<short> LoadVector128(short* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> LoadVector128(int* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> LoadVector128(long* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<sbyte> LoadVector128(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ushort> LoadVector128(ushort* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<uint> LoadVector128(uint* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ulong> LoadVector128(ulong* address) { throw null; }
+        public static unsafe void MaskMove(System.Runtime.Intrinsics.Vector128<byte> source, System.Runtime.Intrinsics.Vector128<byte> mask, byte* address) { }
+        public static unsafe void MaskMove(System.Runtime.Intrinsics.Vector128<sbyte> source, System.Runtime.Intrinsics.Vector128<sbyte> mask, sbyte* address) { }
         public static System.Runtime.Intrinsics.Vector128<byte> Max(System.Runtime.Intrinsics.Vector128<byte> left, System.Runtime.Intrinsics.Vector128<byte> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<double> Max(System.Runtime.Intrinsics.Vector128<double> left, System.Runtime.Intrinsics.Vector128<double> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<short> Max(System.Runtime.Intrinsics.Vector128<short> left, System.Runtime.Intrinsics.Vector128<short> right) { throw null; }
@@ -1415,40 +1415,40 @@ namespace System.Runtime.Intrinsics.X86
         public static System.Runtime.Intrinsics.Vector128<double> Sqrt(System.Runtime.Intrinsics.Vector128<double> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<double> SqrtScalar(System.Runtime.Intrinsics.Vector128<double> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<double> SqrtScalar(System.Runtime.Intrinsics.Vector128<double> upper, System.Runtime.Intrinsics.Vector128<double> value) { throw null; }
-        public unsafe static void Store(byte* address, System.Runtime.Intrinsics.Vector128<byte> source) { }
-        public unsafe static void Store(double* address, System.Runtime.Intrinsics.Vector128<double> source) { }
-        public unsafe static void Store(short* address, System.Runtime.Intrinsics.Vector128<short> source) { }
-        public unsafe static void Store(int* address, System.Runtime.Intrinsics.Vector128<int> source) { }
-        public unsafe static void Store(long* address, System.Runtime.Intrinsics.Vector128<long> source) { }
-        public unsafe static void Store(sbyte* address, System.Runtime.Intrinsics.Vector128<sbyte> source) { }
-        public unsafe static void Store(ushort* address, System.Runtime.Intrinsics.Vector128<ushort> source) { }
-        public unsafe static void Store(uint* address, System.Runtime.Intrinsics.Vector128<uint> source) { }
-        public unsafe static void Store(ulong* address, System.Runtime.Intrinsics.Vector128<ulong> source) { }
-        public unsafe static void StoreAligned(byte* address, System.Runtime.Intrinsics.Vector128<byte> source) { }
-        public unsafe static void StoreAligned(double* address, System.Runtime.Intrinsics.Vector128<double> source) { }
-        public unsafe static void StoreAligned(short* address, System.Runtime.Intrinsics.Vector128<short> source) { }
-        public unsafe static void StoreAligned(int* address, System.Runtime.Intrinsics.Vector128<int> source) { }
-        public unsafe static void StoreAligned(long* address, System.Runtime.Intrinsics.Vector128<long> source) { }
-        public unsafe static void StoreAligned(sbyte* address, System.Runtime.Intrinsics.Vector128<sbyte> source) { }
-        public unsafe static void StoreAligned(ushort* address, System.Runtime.Intrinsics.Vector128<ushort> source) { }
-        public unsafe static void StoreAligned(uint* address, System.Runtime.Intrinsics.Vector128<uint> source) { }
-        public unsafe static void StoreAligned(ulong* address, System.Runtime.Intrinsics.Vector128<ulong> source) { }
-        public unsafe static void StoreAlignedNonTemporal(byte* address, System.Runtime.Intrinsics.Vector128<byte> source) { }
-        public unsafe static void StoreAlignedNonTemporal(double* address, System.Runtime.Intrinsics.Vector128<double> source) { }
-        public unsafe static void StoreAlignedNonTemporal(short* address, System.Runtime.Intrinsics.Vector128<short> source) { }
-        public unsafe static void StoreAlignedNonTemporal(int* address, System.Runtime.Intrinsics.Vector128<int> source) { }
-        public unsafe static void StoreAlignedNonTemporal(long* address, System.Runtime.Intrinsics.Vector128<long> source) { }
-        public unsafe static void StoreAlignedNonTemporal(sbyte* address, System.Runtime.Intrinsics.Vector128<sbyte> source) { }
-        public unsafe static void StoreAlignedNonTemporal(ushort* address, System.Runtime.Intrinsics.Vector128<ushort> source) { }
-        public unsafe static void StoreAlignedNonTemporal(uint* address, System.Runtime.Intrinsics.Vector128<uint> source) { }
-        public unsafe static void StoreAlignedNonTemporal(ulong* address, System.Runtime.Intrinsics.Vector128<ulong> source) { }
-        public unsafe static void StoreHigh(double* address, System.Runtime.Intrinsics.Vector128<double> source) { }
-        public unsafe static void StoreLow(double* address, System.Runtime.Intrinsics.Vector128<double> source) { }
-        public unsafe static void StoreNonTemporal(int* address, int value) { }
-        public unsafe static void StoreNonTemporal(uint* address, uint value) { }
-        public unsafe static void StoreScalar(double* address, System.Runtime.Intrinsics.Vector128<double> source) { }
-        public unsafe static void StoreScalar(long* address, System.Runtime.Intrinsics.Vector128<long> source) { }
-        public unsafe static void StoreScalar(ulong* address, System.Runtime.Intrinsics.Vector128<ulong> source) { }
+        public static unsafe void Store(byte* address, System.Runtime.Intrinsics.Vector128<byte> source) { }
+        public static unsafe void Store(double* address, System.Runtime.Intrinsics.Vector128<double> source) { }
+        public static unsafe void Store(short* address, System.Runtime.Intrinsics.Vector128<short> source) { }
+        public static unsafe void Store(int* address, System.Runtime.Intrinsics.Vector128<int> source) { }
+        public static unsafe void Store(long* address, System.Runtime.Intrinsics.Vector128<long> source) { }
+        public static unsafe void Store(sbyte* address, System.Runtime.Intrinsics.Vector128<sbyte> source) { }
+        public static unsafe void Store(ushort* address, System.Runtime.Intrinsics.Vector128<ushort> source) { }
+        public static unsafe void Store(uint* address, System.Runtime.Intrinsics.Vector128<uint> source) { }
+        public static unsafe void Store(ulong* address, System.Runtime.Intrinsics.Vector128<ulong> source) { }
+        public static unsafe void StoreAligned(byte* address, System.Runtime.Intrinsics.Vector128<byte> source) { }
+        public static unsafe void StoreAligned(double* address, System.Runtime.Intrinsics.Vector128<double> source) { }
+        public static unsafe void StoreAligned(short* address, System.Runtime.Intrinsics.Vector128<short> source) { }
+        public static unsafe void StoreAligned(int* address, System.Runtime.Intrinsics.Vector128<int> source) { }
+        public static unsafe void StoreAligned(long* address, System.Runtime.Intrinsics.Vector128<long> source) { }
+        public static unsafe void StoreAligned(sbyte* address, System.Runtime.Intrinsics.Vector128<sbyte> source) { }
+        public static unsafe void StoreAligned(ushort* address, System.Runtime.Intrinsics.Vector128<ushort> source) { }
+        public static unsafe void StoreAligned(uint* address, System.Runtime.Intrinsics.Vector128<uint> source) { }
+        public static unsafe void StoreAligned(ulong* address, System.Runtime.Intrinsics.Vector128<ulong> source) { }
+        public static unsafe void StoreAlignedNonTemporal(byte* address, System.Runtime.Intrinsics.Vector128<byte> source) { }
+        public static unsafe void StoreAlignedNonTemporal(double* address, System.Runtime.Intrinsics.Vector128<double> source) { }
+        public static unsafe void StoreAlignedNonTemporal(short* address, System.Runtime.Intrinsics.Vector128<short> source) { }
+        public static unsafe void StoreAlignedNonTemporal(int* address, System.Runtime.Intrinsics.Vector128<int> source) { }
+        public static unsafe void StoreAlignedNonTemporal(long* address, System.Runtime.Intrinsics.Vector128<long> source) { }
+        public static unsafe void StoreAlignedNonTemporal(sbyte* address, System.Runtime.Intrinsics.Vector128<sbyte> source) { }
+        public static unsafe void StoreAlignedNonTemporal(ushort* address, System.Runtime.Intrinsics.Vector128<ushort> source) { }
+        public static unsafe void StoreAlignedNonTemporal(uint* address, System.Runtime.Intrinsics.Vector128<uint> source) { }
+        public static unsafe void StoreAlignedNonTemporal(ulong* address, System.Runtime.Intrinsics.Vector128<ulong> source) { }
+        public static unsafe void StoreHigh(double* address, System.Runtime.Intrinsics.Vector128<double> source) { }
+        public static unsafe void StoreLow(double* address, System.Runtime.Intrinsics.Vector128<double> source) { }
+        public static unsafe void StoreNonTemporal(int* address, int value) { }
+        public static unsafe void StoreNonTemporal(uint* address, uint value) { }
+        public static unsafe void StoreScalar(double* address, System.Runtime.Intrinsics.Vector128<double> source) { }
+        public static unsafe void StoreScalar(long* address, System.Runtime.Intrinsics.Vector128<long> source) { }
+        public static unsafe void StoreScalar(ulong* address, System.Runtime.Intrinsics.Vector128<ulong> source) { }
         public static System.Runtime.Intrinsics.Vector128<byte> Subtract(System.Runtime.Intrinsics.Vector128<byte> left, System.Runtime.Intrinsics.Vector128<byte> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<double> Subtract(System.Runtime.Intrinsics.Vector128<double> left, System.Runtime.Intrinsics.Vector128<double> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<short> Subtract(System.Runtime.Intrinsics.Vector128<short> left, System.Runtime.Intrinsics.Vector128<short> right) { throw null; }
@@ -1502,8 +1502,8 @@ namespace System.Runtime.Intrinsics.X86
             public static long ConvertToInt64(System.Runtime.Intrinsics.Vector128<long> value) { throw null; }
             public static long ConvertToInt64WithTruncation(System.Runtime.Intrinsics.Vector128<double> value) { throw null; }
             public static ulong ConvertToUInt64(System.Runtime.Intrinsics.Vector128<ulong> value) { throw null; }
-            public unsafe static void StoreNonTemporal(long* address, long value) { }
-            public unsafe static void StoreNonTemporal(ulong* address, ulong value) { }
+            public static unsafe void StoreNonTemporal(long* address, long value) { }
+            public static unsafe void StoreNonTemporal(ulong* address, ulong value) { }
         }
     }
     [System.CLSCompliantAttribute(false)]
@@ -1517,15 +1517,15 @@ namespace System.Runtime.Intrinsics.X86
         public static System.Runtime.Intrinsics.Vector128<float> HorizontalAdd(System.Runtime.Intrinsics.Vector128<float> left, System.Runtime.Intrinsics.Vector128<float> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<double> HorizontalSubtract(System.Runtime.Intrinsics.Vector128<double> left, System.Runtime.Intrinsics.Vector128<double> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> HorizontalSubtract(System.Runtime.Intrinsics.Vector128<float> left, System.Runtime.Intrinsics.Vector128<float> right) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<double> LoadAndDuplicateToVector128(double* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<byte> LoadDquVector128(byte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<short> LoadDquVector128(short* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> LoadDquVector128(int* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> LoadDquVector128(long* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<sbyte> LoadDquVector128(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ushort> LoadDquVector128(ushort* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<uint> LoadDquVector128(uint* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ulong> LoadDquVector128(ulong* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<double> LoadAndDuplicateToVector128(double* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<byte> LoadDquVector128(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<short> LoadDquVector128(short* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> LoadDquVector128(int* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> LoadDquVector128(long* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<sbyte> LoadDquVector128(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ushort> LoadDquVector128(ushort* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<uint> LoadDquVector128(uint* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ulong> LoadDquVector128(ulong* address) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<double> MoveAndDuplicate(System.Runtime.Intrinsics.Vector128<double> source) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> MoveHighAndDuplicate(System.Runtime.Intrinsics.Vector128<float> source) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> MoveLowAndDuplicate(System.Runtime.Intrinsics.Vector128<float> source) { throw null; }
@@ -1557,30 +1557,30 @@ namespace System.Runtime.Intrinsics.X86
         public static System.Runtime.Intrinsics.Vector128<float> CeilingScalar(System.Runtime.Intrinsics.Vector128<float> upper, System.Runtime.Intrinsics.Vector128<float> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<long> CompareEqual(System.Runtime.Intrinsics.Vector128<long> left, System.Runtime.Intrinsics.Vector128<long> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<ulong> CompareEqual(System.Runtime.Intrinsics.Vector128<ulong> left, System.Runtime.Intrinsics.Vector128<ulong> right) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<short> ConvertToVector128Int16(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<short> ConvertToVector128Int16(byte* address) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<short> ConvertToVector128Int16(System.Runtime.Intrinsics.Vector128<byte> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<short> ConvertToVector128Int16(System.Runtime.Intrinsics.Vector128<sbyte> value) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<short> ConvertToVector128Int16(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> ConvertToVector128Int32(byte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> ConvertToVector128Int32(short* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<short> ConvertToVector128Int16(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> ConvertToVector128Int32(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> ConvertToVector128Int32(short* address) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<int> ConvertToVector128Int32(System.Runtime.Intrinsics.Vector128<byte> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<int> ConvertToVector128Int32(System.Runtime.Intrinsics.Vector128<short> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<int> ConvertToVector128Int32(System.Runtime.Intrinsics.Vector128<sbyte> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<int> ConvertToVector128Int32(System.Runtime.Intrinsics.Vector128<ushort> value) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> ConvertToVector128Int32(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> ConvertToVector128Int32(ushort* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(byte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(short* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(int* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> ConvertToVector128Int32(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> ConvertToVector128Int32(ushort* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(short* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(int* address) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(System.Runtime.Intrinsics.Vector128<byte> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(System.Runtime.Intrinsics.Vector128<short> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(System.Runtime.Intrinsics.Vector128<int> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(System.Runtime.Intrinsics.Vector128<sbyte> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(System.Runtime.Intrinsics.Vector128<ushort> value) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(System.Runtime.Intrinsics.Vector128<uint> value) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(ushort* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(uint* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(ushort* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> ConvertToVector128Int64(uint* address) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<double> DotProduct(System.Runtime.Intrinsics.Vector128<double> left, System.Runtime.Intrinsics.Vector128<double> right, byte control) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> DotProduct(System.Runtime.Intrinsics.Vector128<float> left, System.Runtime.Intrinsics.Vector128<float> right, byte control) { throw null; }
         public static byte Extract(System.Runtime.Intrinsics.Vector128<byte> value, byte index) { throw null; }
@@ -1598,14 +1598,14 @@ namespace System.Runtime.Intrinsics.X86
         public static System.Runtime.Intrinsics.Vector128<sbyte> Insert(System.Runtime.Intrinsics.Vector128<sbyte> value, sbyte data, byte index) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<float> Insert(System.Runtime.Intrinsics.Vector128<float> value, System.Runtime.Intrinsics.Vector128<float> data, byte index) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<uint> Insert(System.Runtime.Intrinsics.Vector128<uint> value, uint data, byte index) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<byte> LoadAlignedVector128NonTemporal(byte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<short> LoadAlignedVector128NonTemporal(short* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<int> LoadAlignedVector128NonTemporal(int* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<long> LoadAlignedVector128NonTemporal(long* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<sbyte> LoadAlignedVector128NonTemporal(sbyte* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ushort> LoadAlignedVector128NonTemporal(ushort* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<uint> LoadAlignedVector128NonTemporal(uint* address) { throw null; }
-        public unsafe static System.Runtime.Intrinsics.Vector128<ulong> LoadAlignedVector128NonTemporal(ulong* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<byte> LoadAlignedVector128NonTemporal(byte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<short> LoadAlignedVector128NonTemporal(short* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<int> LoadAlignedVector128NonTemporal(int* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<long> LoadAlignedVector128NonTemporal(long* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<sbyte> LoadAlignedVector128NonTemporal(sbyte* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ushort> LoadAlignedVector128NonTemporal(ushort* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<uint> LoadAlignedVector128NonTemporal(uint* address) { throw null; }
+        public static unsafe System.Runtime.Intrinsics.Vector128<ulong> LoadAlignedVector128NonTemporal(ulong* address) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<int> Max(System.Runtime.Intrinsics.Vector128<int> left, System.Runtime.Intrinsics.Vector128<int> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<sbyte> Max(System.Runtime.Intrinsics.Vector128<sbyte> left, System.Runtime.Intrinsics.Vector128<sbyte> right) { throw null; }
         public static System.Runtime.Intrinsics.Vector128<ushort> Max(System.Runtime.Intrinsics.Vector128<ushort> left, System.Runtime.Intrinsics.Vector128<ushort> right) { throw null; }
index 4362aa6..2c85c59 100644 (file)
@@ -10,7 +10,7 @@ namespace System.Reflection.Metadata
     public static partial class AssemblyExtensions
     {
         [System.CLSCompliantAttribute(false)]
-        public unsafe static bool TryGetRawMetadata(this System.Reflection.Assembly assembly, out byte* blob, out int length) { throw null; }
+        public static unsafe bool TryGetRawMetadata(this System.Reflection.Assembly assembly, out byte* blob, out int length) { throw null; }
     }
 }
 namespace System.Runtime.Loader
index 7aeac0d..f1b0de7 100644 (file)
@@ -8,11 +8,11 @@ namespace System.Runtime.Loader.Tests
 {
     public class TestClass
     {
-       public static Assembly LoadFromDefaultContext(string assemblyNameStr)
-       {
-               var assemblyName = new AssemblyName(assemblyNameStr);
+        public static Assembly LoadFromDefaultContext(string assemblyNameStr)
+        {
+            var assemblyName = new AssemblyName(assemblyNameStr);
             return Assembly.Load(assemblyName);
-       }
+        }
 
         public static Assembly GetRefEmitAssembly(string assemblyNameStr, AssemblyBuilderAccess builderType)
         {
index 2e9538f..b2081d9 100644 (file)
@@ -175,14 +175,14 @@ namespace System.Numerics.Tests
         {
             StackCalc sc1 = new StackCalc(opstring1);
             while (sc1.DoNextOperation())
-            {  
+            {
                 //Run the full calculation
                 sc1.DoNextOperation();
             }
 
             StackCalc sc2 = new StackCalc(opstring2);
             while (sc2.DoNextOperation())
-            {  
+            {
                 //Run the full calculation
                 sc2.DoNextOperation();
             }
index a30e515..3cfb239 100644 (file)
@@ -160,7 +160,7 @@ namespace System.Numerics.Tests
 
             StackCalc sc2 = new StackCalc(opstring2);
             while (sc2.DoNextOperation())
-            {  
+            {
                 //Run the full calculation
                 sc2.DoNextOperation();
             }
index 0be9b8f..d6963c4 100644 (file)
@@ -218,14 +218,14 @@ namespace System.Numerics.Tests
         {
             StackCalc sc1 = new StackCalc(opstring1);
             while (sc1.DoNextOperation())
-            {  
+            {
                 //Run the full calculation
                 sc1.DoNextOperation();
             }
 
             StackCalc sc2 = new StackCalc(opstring2);
             while (sc2.DoNextOperation())
-            {  
+            {
                 //Run the full calculation
                 sc2.DoNextOperation();
             }
index 07c6685..b186e02 100644 (file)
@@ -161,7 +161,7 @@ namespace System.Numerics.Tests
 
             StackCalc sc2 = new StackCalc(opstring2);
             while (sc2.DoNextOperation())
-            {  
+            {
                 //Run the full calculation
                 sc2.DoNextOperation();
             }
index 267bad6..46140d5 100644 (file)
@@ -13,8 +13,8 @@ namespace System.Numerics.Tests
 {
     public partial class parseTest
     {
-        private readonly static int s_samples = 10;
-        private readonly static Random s_random = new Random(100);
+        private static readonly int s_samples = 10;
+        private static readonly Random s_random = new Random(100);
 
         // Invariant culture is commonly used for (de-)serialization and similar to en-US
         // Ukrainian (Ukraine) added to catch regressions (issue #1642)
index 9457a9d..18e0120 100644 (file)
@@ -198,7 +198,7 @@ namespace System.Numerics.Tests
 
             StackCalc sc2 = new StackCalc(opstring2);
             while (sc2.DoNextOperation())
-            {  
+            {
                 //Run the full calculation
                 sc2.DoNextOperation();
             }
index 2dd24b5..4f689c8 100644 (file)
@@ -89,7 +89,7 @@ namespace System.Numerics.Tests
         {
             StackCalc sc1 = new StackCalc(opstring1);
             while (sc1.DoNextOperation())
-            {  
+            {
                 //Run the full calculation
                 sc1.DoNextOperation();
             }
index 434f24c..fbf1c0b 100644 (file)
@@ -3079,7 +3079,7 @@ public static partial class DataContractSerializerTests
         TestObjectInObjectContainerWithSimpleResolver(new SerializationTestTypes.EmptyDCType(), @"<ObjectContainer xmlns=""http://schemas.datacontract.org/2004/07/SerializationTestTypes"" xmlns:i=""http://www.w3.org/2001/XMLSchema-instance""><_data i:type=""a:SerializationTestTypes.EmptyDCType***"" xmlns:a=""http://schemas.datacontract.org/2004/07/SerializationTestTypes.EmptyDCType***""/><_data2 i:type=""a:SerializationTestTypes.EmptyDCType***"" xmlns:a=""http://schemas.datacontract.org/2004/07/SerializationTestTypes.EmptyDCType***""/></ObjectContainer>");
 
         TestObjectInObjectContainerWithSimpleResolver(new SerializationTestTypes.ObjectContainer(true), @"<ObjectContainer xmlns=""http://schemas.datacontract.org/2004/07/SerializationTestTypes"" xmlns:i=""http://www.w3.org/2001/XMLSchema-instance""><_data i:type=""a:SerializationTestTypes.ObjectContainer***"" xmlns:a=""http://schemas.datacontract.org/2004/07/SerializationTestTypes.ObjectContainer***""><_data i:type=""b:boolean"" xmlns:b=""http://www.w3.org/2001/XMLSchema"">true</_data><_data2 i:type=""b:boolean"" xmlns:b=""http://www.w3.org/2001/XMLSchema"">true</_data2></_data><_data2 i:type=""a:SerializationTestTypes.ObjectContainer***"" xmlns:a=""http://schemas.datacontract.org/2004/07/SerializationTestTypes.ObjectContainer***""><_data i:type=""b:boolean"" xmlns:b=""http://www.w3.org/2001/XMLSchema"">true</_data><_data2 i:type=""b:boolean"" xmlns:b=""http://www.w3.org/2001/XMLSchema"">true</_data2></_data2></ObjectContainer>");
-               
+
         TestObjectInObjectContainerWithSimpleResolver(new SerializationTestTypes.POCOObjectContainer(true), @"<ObjectContainer xmlns=""http://schemas.datacontract.org/2004/07/SerializationTestTypes"" xmlns:i=""http://www.w3.org/2001/XMLSchema-instance""><_data i:type=""a:SerializationTestTypes.POCOObjectContainer***"" xmlns:a=""http://schemas.datacontract.org/2004/07/SerializationTestTypes.POCOObjectContainer***""><Data i:type=""b:boolean"" xmlns:b=""http://www.w3.org/2001/XMLSchema"">true</Data></_data><_data2 i:type=""a:SerializationTestTypes.POCOObjectContainer***"" xmlns:a=""http://schemas.datacontract.org/2004/07/SerializationTestTypes.POCOObjectContainer***""><Data i:type=""b:boolean"" xmlns:b=""http://www.w3.org/2001/XMLSchema"">true</Data></_data2></ObjectContainer>");
 
         TestObjectInObjectContainerWithSimpleResolver(new SerializationTestTypes.CircularLink(true), @"<ObjectContainer xmlns=""http://schemas.datacontract.org/2004/07/SerializationTestTypes"" xmlns:i=""http://www.w3.org/2001/XMLSchema-instance""><_data z:Id=""i1"" i:type=""a:SerializationTestTypes.CircularLink***"" xmlns:z=""http://schemas.microsoft.com/2003/10/Serialization/"" xmlns:a=""http://schemas.datacontract.org/2004/07/SerializationTestTypes.CircularLink***""><Link z:Id=""i2""><Link z:Id=""i3""><Link z:Ref=""i1""/><RandomHangingLink i:nil=""true""/></Link><RandomHangingLink i:nil=""true""/></Link><RandomHangingLink z:Id=""i4""><Link z:Id=""i5""><Link z:Id=""i6"" i:type=""b:SerializationTestTypes.CircularLinkDerived***"" xmlns:b=""http://schemas.datacontract.org/2004/07/SerializationTestTypes.CircularLinkDerived***""><Link z:Ref=""i4""/><RandomHangingLink i:nil=""true""/></Link><RandomHangingLink i:nil=""true""/></Link><RandomHangingLink i:nil=""true""/></RandomHangingLink></_data><_data2 z:Ref=""i1"" xmlns:z=""http://schemas.microsoft.com/2003/10/Serialization/""/></ObjectContainer>");
@@ -3522,7 +3522,7 @@ public static partial class DataContractSerializerTests
         string corelibAssemblyName = typeof(String).Assembly.FullName;
 
         TestObjectInObjectContainerWithSimpleResolver(new SerializationTestTypes.ContainsLinkedList(true), "<ObjectContainer xmlns=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\"><_data i:type=\"a:SerializationTestTypes.ContainsLinkedList***\" xmlns:a=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes.ContainsLinkedList***\"><Data><SimpleDCWithRef z:Id=\"i1\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"><Data z:Id=\"i2\"><Data>This is a string</Data></Data><RefData z:Ref=\"i2\"/></SimpleDCWithRef><SimpleDCWithRef z:Id=\"i3\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"><Data z:Id=\"i4\"><Data>This is a string</Data></Data><RefData z:Ref=\"i4\"/></SimpleDCWithRef><SimpleDCWithRef z:Ref=\"i3\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"/><SimpleDCWithRef z:Ref=\"i1\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"/><SimpleDCWithRef z:Id=\"i5\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"><Data z:Id=\"i6\"><Data>This is a string</Data></Data><RefData z:Id=\"i7\"><Data>This is a string</Data></RefData></SimpleDCWithRef><SimpleDCWithRef z:Id=\"i8\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"><Data z:Ref=\"i6\"/><RefData z:Ref=\"i6\"/></SimpleDCWithRef><SimpleDCWithRef z:Id=\"i9\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"><Data z:Id=\"i10\"><Data>This is a string</Data></Data><RefData z:Id=\"i11\"><Data>This is a string</Data></RefData></SimpleDCWithRef></Data></_data><_data2 i:type=\"a:SerializationTestTypes.ContainsLinkedList***\" xmlns:a=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes.ContainsLinkedList***\"><Data><SimpleDCWithRef z:Ref=\"i1\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"/><SimpleDCWithRef z:Ref=\"i3\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"/><SimpleDCWithRef z:Ref=\"i3\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"/><SimpleDCWithRef z:Ref=\"i1\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"/><SimpleDCWithRef z:Ref=\"i5\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"/><SimpleDCWithRef z:Ref=\"i8\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"/><SimpleDCWithRef z:Ref=\"i9\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"/></Data></_data2></ObjectContainer>");
-               
+        
         TestObjectInObjectContainerWithSimpleResolver(new SerializationTestTypes.SimpleCDC(true), "<ObjectContainer xmlns=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\"><_data z:Id=\"i1\" i:type=\"a:SerializationTestTypes.SimpleCDC***\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\" xmlns:a=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes.SimpleCDC***\"><Item>One</Item><Item>Two</Item><Item>two</Item></_data><_data2 z:Ref=\"i1\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"/></ObjectContainer>");
 
         TestObjectInObjectContainerWithSimpleResolver(new SerializationTestTypes.SimpleCDC2(true), "<ObjectContainer xmlns=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\"><_data z:Id=\"i1\" i:type=\"a:SerializationTestTypes.SimpleCDC2***\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\" xmlns:a=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes.SimpleCDC2***\"><Item>One</Item><Item>Two</Item><Item>two</Item></_data><_data2 z:Ref=\"i1\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"/></ObjectContainer>");
@@ -3679,7 +3679,7 @@ public static partial class DataContractSerializerTests
         TestObjectInObjectContainerWithSimpleResolver(new SerializationTestTypes.TestInheritence14(true), "<ObjectContainer xmlns=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\"><_data i:type=\"a:SerializationTestTypes.TestInheritence14***\" xmlns:a=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes.TestInheritence14***\"><baseDC><data>String1</data><data2>String2</data2><days xmlns:b=\"http://schemas.microsoft.com/2003/10/Serialization/Arrays\"><b:string>Base1</b:string><b:string>Base2</b:string><b:string>Base3</b:string><b:string>Base4</b:string><b:string>Base5</b:string><b:string>Base6</b:string><b:string>Base7</b:string></days></baseDC><derived2DC><data>TestString2</data><data2>TestString2</data2><data0>TestString0</data0><data1>TestString1</data1><data3>TestString3</data3><data00>String2</data00><data122>TestString122</data122><data4>TestString4</data4></derived2DC></_data><_data2 i:type=\"a:SerializationTestTypes.TestInheritence14***\" xmlns:a=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes.TestInheritence14***\"><baseDC><data>String1</data><data2>String2</data2><days xmlns:b=\"http://schemas.microsoft.com/2003/10/Serialization/Arrays\"><b:string>Base1</b:string><b:string>Base2</b:string><b:string>Base3</b:string><b:string>Base4</b:string><b:string>Base5</b:string><b:string>Base6</b:string><b:string>Base7</b:string></days></baseDC><derived2DC><data>TestString2</data><data2>TestString2</data2><data0>TestString0</data0><data1>TestString1</data1><data3>TestString3</data3><data00>String2</data00><data122>TestString122</data122><data4>TestString4</data4></derived2DC></_data2></ObjectContainer>");
 
         TestObjectInObjectContainerWithSimpleResolver(new SerializationTestTypes.TestInheritence8(true), "<ObjectContainer xmlns=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\"><_data z:Id=\"i1\" i:type=\"a:SerializationTestTypes.TestInheritence8***\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\" xmlns:a=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes.TestInheritence8***\"><baseDC><data>String2</data><data2>TestString2</data2></baseDC><derived2DC><data>TestString</data><data2>TestString2</data2><data0>TestString0</data0><data1>TestString1</data1><data3>TestString3</data3><data11>String1</data11><data12>String2</data12><data4>TestString4</data4></derived2DC></_data><_data2 z:Ref=\"i1\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"/></ObjectContainer>");
-               
+        
     }
 
     [Fact]
@@ -3732,7 +3732,7 @@ public static partial class DataContractSerializerTests
         TestObjectInObjectContainerWithSimpleResolver(new SerializationTestTypes.BB1(true), "<ObjectContainer xmlns=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\"><_data z:Id=\"i1\" i:type=\"a:SerializationTestTypes.BB1***\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\" xmlns:a=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes.BB1***\"><Data z:Id=\"i2\"><Data z:Id=\"i3\"><Data z:Id=\"i4\"><Data z:Id=\"i5\"><Data z:Ref=\"i2\"/></Data><Data2 z:Id=\"i6\"><Data z:Ref=\"i4\"/></Data2></Data></Data></Data></_data><_data2 z:Ref=\"i1\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"/></ObjectContainer>");
 
         TestObjectInObjectContainerWithSimpleResolver(new SerializationTestTypes.BBB1(true), "<ObjectContainer xmlns=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\"><_data z:Id=\"i1\" i:type=\"a:SerializationTestTypes.BBB1***\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\" xmlns:a=\"http://schemas.datacontract.org/2004/07/SerializationTestTypes.BBB1***\"><Data z:Id=\"i2\"><Data z:Id=\"i3\"><Data z:Id=\"i4\"><Data z:Ref=\"i1\"/></Data><Data2 z:Id=\"i5\"><Data z:Ref=\"i3\"/></Data2></Data></Data></_data><_data2 z:Ref=\"i1\" xmlns:z=\"http://schemas.microsoft.com/2003/10/Serialization/\"/></ObjectContainer>");
-               
+        
     }
 
     [Fact]
index 720b9d8..5f2647d 100644 (file)
@@ -12,8 +12,8 @@ namespace SerializationTestTypes
     [Serializable]
     public class PrimitiveTypeResolver : DataContractResolver
     {
-        private readonly static string s_defaultNS = "http://www.default.com";
-        private readonly static ConcurrentDictionary<string, Type> s_types = new ConcurrentDictionary<string, Type>();
+        private static readonly string s_defaultNS = "http://www.default.com";
+        private static readonly ConcurrentDictionary<string, Type> s_types = new ConcurrentDictionary<string, Type>();
 
         public override bool TryResolveType(Type dcType, Type declaredType, DataContractResolver KTResolver, out XmlDictionaryString typeName, out XmlDictionaryString typeNamespace)
         {
@@ -301,7 +301,7 @@ namespace SerializationTestTypes
 
     public class ResolverDefaultCollections : DataContractResolver
     {
-        private readonly static string s_defaultNs = "http://www.default.com";
+        private static readonly string s_defaultNs = "http://www.default.com";
         public override bool TryResolveType(Type dcType, Type declaredType, DataContractResolver KTResolver, out XmlDictionaryString typeName, out XmlDictionaryString typeNamespace)
         {
             string resolvedNamespace = string.Empty;
index 1ce38ab..252eb69 100644 (file)
@@ -50,11 +50,11 @@ namespace System.IO
                 if (dataBuffer.Length > 0)
                     memStream.Seek(dataBuffer.Length, SeekOrigin.Current);
 
-                return AsyncInfo.CreateCompletedOperation<IBuffer, UInt32>(dataBuffer);
+                return AsyncInfo.CreateCompletedOperation<IBuffer, uint>(dataBuffer);
             }
             catch (Exception ex)
             {
-                return AsyncInfo.CreateFaultedOperation<IBuffer, UInt32>(ex);
+                return AsyncInfo.CreateFaultedOperation<IBuffer, uint>(ex);
             }
         }  // ReadAsync_MemoryStream
 
@@ -150,7 +150,7 @@ namespace System.IO
                 return dataBuffer;
             };  // readOperation
 
-            return AsyncInfo.Run<IBuffer, UInt32>(readOperation);
+            return AsyncInfo.Run<IBuffer, uint>(readOperation);
         }  // ReadAsync_AbstractStream
 
         #endregion ReadAsync implementations
@@ -214,7 +214,7 @@ namespace System.IO
             }  // if-else
 
             // Construct and run the async operation:
-            return AsyncInfo.Run<UInt32, UInt32>(writeOperation);
+            return AsyncInfo.Run<uint, uint>(writeOperation);
         }  // WriteAsync_AbstractStream
 
         #endregion WriteAsync implementations
@@ -237,7 +237,7 @@ namespace System.IO
             };
 
             // Construct and run the async operation:
-            return AsyncInfo.Run<Boolean>(flushOperation);
+            return AsyncInfo.Run<bool>(flushOperation);
         }
         #endregion FlushAsync implementations
 
index d7a9edc..796e65d 100644 (file)
@@ -147,7 +147,7 @@ namespace System.IO
 
 
 #if DEBUG
-        private static void AssertValidStream(Object winRtStream)
+        private static void AssertValidStream(object winRtStream)
         {
             Debug.Assert(winRtStream != null,
                             "This to-NetFx Stream adapter must not be disposed and the underlying WinRT stream must be of compatible type for this operation");
index f514fab..bbfb328 100644 (file)
@@ -53,12 +53,12 @@ namespace System.IO
             if (valueMayBeWrappedInBufferedStream)
             {
                 BufferedStream bufferedValueInMap = valueInMap as BufferedStream;
-                Debug.Assert(Object.ReferenceEquals(value, valueInMap)
-                                || (bufferedValueInMap != null && Object.ReferenceEquals(value, bufferedValueInMap.UnderlyingStream)));
+                Debug.Assert(object.ReferenceEquals(value, valueInMap)
+                                || (bufferedValueInMap != null && object.ReferenceEquals(value, bufferedValueInMap.UnderlyingStream)));
             }
             else
             {
-                Debug.Assert(Object.ReferenceEquals(value, valueInMap));
+                Debug.Assert(object.ReferenceEquals(value, valueInMap));
             }
         }
 #endif  // DEBUG
@@ -301,7 +301,7 @@ namespace System.IO
             // In that case we do not need to put the wrapper into the map.
             if (sAdptr != null)
             {
-                object wrappedWinRtStream = sAdptr.GetWindowsRuntimeStream<Object>();
+                object wrappedWinRtStream = sAdptr.GetWindowsRuntimeStream<object>();
                 if (wrappedWinRtStream == null)
                     throw new ObjectDisposedException(nameof(stream), SR.ObjectDisposed_CannotPerformOperation);
 
index 771ca78..32cdfbb 100644 (file)
@@ -52,7 +52,7 @@ namespace System.Resources
         private static volatile CultureInfo s_globalResourceContextBestFitCultureInfo;
         private static volatile global::Windows.ApplicationModel.Resources.Core.ResourceManager s_globalResourceManager;
 
-        private static Object s_objectForLock = new Object(); // Used by InitializeStatics
+        private static object s_objectForLock = new object(); // Used by InitializeStatics
 
         private static bool InitializeStatics()
         {
@@ -121,7 +121,7 @@ namespace System.Resources
 #pragma warning restore 618
                             if (globalResourceContext != null)
                             {
-                                List<String> languages = new List<string>(globalResourceContext.Languages);
+                                List<string> languages = new List<string>(globalResourceContext.Languages);
 
                                 s_globalResourceContextBestFitCultureInfo = GetBestFitCultureFromLanguageList(languages);
                                 s_globalResourceContextFallBackList = ReadOnlyListToString(languages);
@@ -247,7 +247,7 @@ namespace System.Resources
                 return;
             }
 
-            List<String> languages = new List<string>(langs);
+            List<string> languages = new List<string>(langs);
             
             if (languages.Count > 0 && languages[0] == c_InvariantCulturePrivateName)
             {
@@ -258,13 +258,13 @@ namespace System.Resources
             s_globalResourceContextFallBackList = ReadOnlyListToString(languages);
         }
 
-        private static bool LibpathMatchesPackagepath(String libpath, String packagepath)
+        private static bool LibpathMatchesPackagepath(string libpath, string packagepath)
         {
             Debug.Assert(libpath != null);
             Debug.Assert(packagepath != null);
 
             return packagepath.Length < libpath.Length &&
-                   String.Compare(packagepath, 0,
+                   string.Compare(packagepath, 0,
                                   libpath, 0,
                                   packagepath.Length,
                                   StringComparison.OrdinalIgnoreCase) == 0 &&
@@ -275,7 +275,7 @@ namespace System.Resources
 
 #if netstandard
         /* Returns true if libpath is path to an ni image and if the path contains packagename as a subfolder */
-        private static bool LibpathContainsPackagename(String libpath, String packagename)
+        private static bool LibpathContainsPackagename(string libpath, string packagename)
         {
             Debug.Assert(libpath != null);
             Debug.Assert(packagename != null);
@@ -356,7 +356,7 @@ namespace System.Resources
                 // exceptionInfo structure at this point since we don't have any
                 // reliable information to include in it.
 
-                IReadOnlyDictionary<String, ResourceMap>
+                IReadOnlyDictionary<string, ResourceMap>
                     resourceMapDictionary = s_globalResourceManager.AllResourceMaps;
 
                 if (resourceMapDictionary != null)
@@ -435,7 +435,7 @@ namespace System.Resources
         {
             Debug.Assert(list != null);
 
-            return String.Join(";", list);
+            return string.Join(";", list);
         }
 
         public override CultureInfo GlobalResourceContextBestFitCultureInfo
@@ -472,7 +472,7 @@ namespace System.Resources
                 return true;
             }
 
-            List<String> languages = new List<String>(s_globalResourceContext.Languages);
+            List<string> languages = new List<string>(s_globalResourceContext.Languages);
             languages.Insert(0, ci.Name == CultureInfo.InvariantCulture.Name ? c_InvariantCulturePrivateName : ci.Name);
 
             // remove any duplication in the list
@@ -501,8 +501,8 @@ namespace System.Resources
         // continue to be thread-safe.
 
         // Throws exceptions
-        public override String GetString(String stringName,
-                 String startingCulture, String neutralResourcesCulture)
+        public override string GetString(string stringName,
+                 string startingCulture, string neutralResourcesCulture)
         {
             Debug.Assert(stringName != null);
             Debug.Assert(_resourceMap != null); // Should have been initialized by now
@@ -543,7 +543,7 @@ namespace System.Resources
                     // The worst that can happen is that a string is unexpectedly missing
                     // or in the wrong language.
 
-                    if (!String.Equals(newResourceFallBackList, _clonedResourceContextFallBackList, StringComparison.Ordinal))
+                    if (!string.Equals(newResourceFallBackList, _clonedResourceContextFallBackList, StringComparison.Ordinal))
                     {
                         _clonedResourceContext.Languages = StringToReadOnlyList(newResourceFallBackList);
                         _clonedResourceContextFallBackList = newResourceFallBackList;
index 9a51cd1..11a59d8 100644 (file)
@@ -129,7 +129,7 @@ namespace System.Runtime.InteropServices.WindowsRuntime
             if (source.Capacity - sourceIndex < count) throw new ArgumentException(SR.Argument_InsufficientSpaceInSourceBuffer);
 
             if (count == 0)
-                return Array.Empty<Byte>();
+                return Array.Empty<byte>();
 
             byte[] destination = new byte[count];
             source.CopyTo(sourceIndex, destination, 0, count);
index 672b34d..955103b 100644 (file)
@@ -471,9 +471,9 @@ namespace System
         public static int ByteLength(System.Array array) { throw null; }
         public static byte GetByte(System.Array array, int index) { throw null; }
         [System.CLSCompliantAttribute(false)]
-        public unsafe static void MemoryCopy(void* source, void* destination, long destinationSizeInBytes, long sourceBytesToCopy) { }
+        public static unsafe void MemoryCopy(void* source, void* destination, long destinationSizeInBytes, long sourceBytesToCopy) { }
         [System.CLSCompliantAttribute(false)]
-        public unsafe static void MemoryCopy(void* source, void* destination, ulong destinationSizeInBytes, ulong sourceBytesToCopy) { }
+        public static unsafe void MemoryCopy(void* source, void* destination, ulong destinationSizeInBytes, ulong sourceBytesToCopy) { }
         public static void SetByte(System.Array array, int index, byte value) { }
     }
     public readonly partial struct Byte : System.IComparable, System.IComparable<byte>, System.IConvertible, System.IEquatable<byte>, System.IFormattable
@@ -1641,9 +1641,9 @@ namespace System
         public static explicit operator int (System.IntPtr value) { throw null; }
         public static explicit operator long (System.IntPtr value) { throw null; }
         [System.CLSCompliantAttribute(false)]
-        public unsafe static explicit operator void* (System.IntPtr value) { throw null; }
+        public static unsafe explicit operator void* (System.IntPtr value) { throw null; }
         [System.CLSCompliantAttribute(false)]
-        public unsafe static explicit operator System.IntPtr (void* value) { throw null; }
+        public static unsafe explicit operator System.IntPtr (void* value) { throw null; }
         public static bool operator !=(System.IntPtr value1, System.IntPtr value2) { throw null; }
         public static System.IntPtr operator -(System.IntPtr pointer, int offset) { throw null; }
         public static System.IntPtr Subtract(System.IntPtr pointer, int offset) { throw null; }
@@ -3368,8 +3368,8 @@ namespace System
         public static explicit operator System.UIntPtr (ulong value) { throw null; }
         public static explicit operator uint (System.UIntPtr value) { throw null; }
         public static explicit operator ulong (System.UIntPtr value) { throw null; }
-        public unsafe static explicit operator void* (System.UIntPtr value) { throw null; }
-        public unsafe static explicit operator System.UIntPtr (void* value) { throw null; }
+        public static unsafe explicit operator void* (System.UIntPtr value) { throw null; }
+        public static unsafe explicit operator System.UIntPtr (void* value) { throw null; }
         public static bool operator !=(System.UIntPtr value1, System.UIntPtr value2) { throw null; }
         public static System.UIntPtr operator -(System.UIntPtr pointer, int offset) { throw null; }
         public static System.UIntPtr Subtract(System.UIntPtr pointer, int offset) { throw null; }
@@ -6220,9 +6220,9 @@ namespace System.Reflection
     public sealed partial class Pointer : System.Runtime.Serialization.ISerializable
     {
         internal Pointer() { }
-        public unsafe static object Box(void* ptr, System.Type type) { throw null; }
+        public static unsafe object Box(void* ptr, System.Type type) { throw null; }
         void System.Runtime.Serialization.ISerializable.GetObjectData(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context) { }
-        public unsafe static void* Unbox(object ptr) { throw null; }
+        public static unsafe void* Unbox(object ptr) { throw null; }
     }
     [System.FlagsAttribute]
     public enum PortableExecutableKinds
index 2c15e2f..35d4657 100644 (file)
@@ -88,7 +88,7 @@ namespace System.Tests
         }
 
         [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsArgIteratorNotSupported))]
-        public unsafe static void ArgIterator_Throws_PlatformNotSupportedException()
+        public static unsafe void ArgIterator_Throws_PlatformNotSupportedException()
         {
             Assert.Throws<PlatformNotSupportedException>(() => new ArgIterator(new RuntimeArgumentHandle()));
             Assert.Throws<PlatformNotSupportedException>(() => {
index 84be52a..a2ce81a 100644 (file)
@@ -841,7 +841,7 @@ namespace System.Tests
         [Theory]
         [InlineData("")] // empty string
         [InlineData("hello")] // non-empty string
-        public unsafe static void GetPinnableReference_ReturnsSameAsGCHandleAndLegacyFixed(string input)
+        public static unsafe void GetPinnableReference_ReturnsSameAsGCHandleAndLegacyFixed(string input)
         {
             Assert.NotNull(input); // test shouldn't have null input
 
@@ -896,7 +896,7 @@ namespace System.Tests
         }
 
         [Fact]
-        public unsafe static void GetPinnableReference_WithNullInput_ThrowsNullRef()
+        public static unsafe void GetPinnableReference_WithNullInput_ThrowsNullRef()
         {
             // This test uses an explicit call instead of the normal callvirt that C# would emit.
             // This allows us to make sure the NullReferenceException is coming from *within*
@@ -1241,7 +1241,7 @@ namespace System.Tests
         /// <summary>
         /// Returns true only if U+0020 SPACE is represented as the single byte 0x20 in the active code page.
         /// </summary>
-        public unsafe static bool IsSimpleActiveCodePage
+        public static unsafe bool IsSimpleActiveCodePage
         {
             get
             {
index b61d3c3..638c131 100644 (file)
@@ -290,7 +290,7 @@ namespace System.Text.Tests
         }
 
         [Fact]
-        public unsafe static void NarrowUtf16ToAscii_EmptyInput_NullReferences()
+        public static unsafe void NarrowUtf16ToAscii_EmptyInput_NullReferences()
         {
             Assert.Equal(UIntPtr.Zero, _fnNarrowUtf16ToAscii.Delegate(null, null, UIntPtr.Zero));
         }
index b2ac721..55a5146 100644 (file)
@@ -287,7 +287,7 @@ namespace System.Security.AccessControl.Tests
             gAce = new CustomAce(aceType, aceFlag, opaque);
             rawAcl.InsertAce(rawAcl.Count, gAce);
 
-            // CompoundAce                                     
+            // CompoundAce
             aceFlag = (AceFlags)2;
             accessMask = 1;
             compoundAceType = CompoundAceType.Impersonation;
@@ -326,4 +326,4 @@ namespace System.Security.AccessControl.Tests
 
         }
     }
-}
\ No newline at end of file
+}
index 67c3b5e..10f30d0 100644 (file)
@@ -76,12 +76,12 @@ namespace System.Security.AccessControl.Tests
             //case 3, only three ACEs, index at Count/2
             rawAcl = new RawAcl(1, 3);
 
-            //215 has all AceFlags except InheritOnly                                  
+            //215 has all AceFlags except InheritOnly
             gAce = new CommonAce((AceFlags)(FlagsForAce.AuditFlags | FlagsForAce.OI | FlagsForAce.CI | FlagsForAce.NP | FlagsForAce.IH), AceQualifier.AccessAllowed, 1,
                 new SecurityIdentifier(Utils.TranslateStringConstFormatSidToStandardFormatSid(owner1)), false, null);
             rawAcl.InsertAce(0, gAce);
 
-            //199 has all AceFlags except InheritOnly and Inherited                            
+            //199 has all AceFlags except InheritOnly and Inherited
             gAce = new CommonAce((AceFlags)(FlagsForAce.AuditFlags | FlagsForAce.OI | FlagsForAce.CI | FlagsForAce.NP), AceQualifier.AccessDenied, 1,
                 new SecurityIdentifier(Utils.TranslateStringConstFormatSidToStandardFormatSid(owner2)), false, null);
             rawAcl.InsertAce(1, gAce);
@@ -188,4 +188,4 @@ namespace System.Security.AccessControl.Tests
             });
         }
     }
-}
\ No newline at end of file
+}
index 5b93a09..0ae1f44 100644 (file)
@@ -83,7 +83,7 @@ namespace System.Security.AccessControl.Tests
             rawAcl = new RawAcl(revision, capacity);
             sidStr = "BG";
             sid = new SecurityIdentifier(Utils.TranslateStringConstFormatSidToStandardFormatSid(sidStr));
-            //199 has all aceflags but inheritonly and inherited                                       
+            //199 has all aceflags but inheritonly and inherited
             gAce = new CommonAce((AceFlags)199, AceQualifier.AccessAllowed, 1, sid, false, null);
             rawAcl.InsertAce(0, gAce);
             isContainer = false;
@@ -117,7 +117,7 @@ namespace System.Security.AccessControl.Tests
             rawAcl = new RawAcl(revision, capacity);
             sidStr = "BG";
             sid = new SecurityIdentifier(Utils.TranslateStringConstFormatSidToStandardFormatSid(sidStr));
-            //215 has all aceflags but inheritedonly                           
+            //215 has all aceflags but inheritedonly
             gAce = new CommonAce((AceFlags)215, AceQualifier.AccessAllowed, 1, sid, false, null);
             rawAcl.InsertAce(0, gAce);
             isContainer = false;
@@ -152,7 +152,7 @@ namespace System.Security.AccessControl.Tests
             rawAcl = new RawAcl(revision, capacity);
             sidStr = "BG";
             sid = new SecurityIdentifier(Utils.TranslateStringConstFormatSidToStandardFormatSid(sidStr));
-            //207 has all AceFlags but inherited                               
+            //207 has all AceFlags but inherited
             gAce = new CommonAce((AceFlags)207, AceQualifier.AccessAllowed, 1, sid, false, null);
             rawAcl.InsertAce(0, gAce);
             gAce = new CommonAce(AceFlags.None, AceQualifier.AccessDenied, 2, sid, false, null);
@@ -194,7 +194,7 @@ namespace System.Security.AccessControl.Tests
             revision = 127;
             capacity = 1;
             rawAcl = new RawAcl(revision, capacity);
-            //207 has all AceFlags but inherited                               
+            //207 has all AceFlags but inherited
             aceFlag = (AceFlags)207;
             accessMask = 1;
             compoundAceType = CompoundAceType.Impersonation;
@@ -220,7 +220,7 @@ namespace System.Security.AccessControl.Tests
             capacity = 1;
             rawAcl = new RawAcl(revision, capacity);
             sid = new SecurityIdentifier(Utils.TranslateStringConstFormatSidToStandardFormatSid("BG"));
-            //207 has all AceFlags but inherited                                               
+            //207 has all AceFlags but inherited
             aceFlag = (AceFlags)207;
             aceQualifier = AceQualifier.AccessAllowed;
             accessMask = 1;
index 9d34f1b..9802141 100644 (file)
@@ -59,7 +59,7 @@ namespace System.Security.AccessControl.Tests
                 if (!Utils.IsBinaryFormEqual(dAclBinaryForm, rAclBinaryForm))
                     result = false;
 
-                //redundant index check                                        
+                //redundant index check
                 for (int i = 0; i < discretionaryAcl.Count; i++)
                 {
                     if (!Utils.IsAceEqual(discretionaryAcl[i], rawAcl[i]))
index e42cfbe..3ca94d0 100644 (file)
@@ -49,7 +49,7 @@ namespace System.Security.AccessControl.Tests
                 if (!Utils.IsBinaryFormEqual(dAclBinaryForm, rAclBinaryForm))
                     result = false;
 
-                //redundant index check                                        
+                //redundant index check
                 for (int i = 0; i < discretionaryAcl.Count; i++)
                 {
                     if (!Utils.IsAceEqual(discretionaryAcl[i], rawAcl[i]))
index 365dc27..40fd982 100644 (file)
@@ -184,11 +184,11 @@ namespace System.Security.AccessControl.Tests
             revision = 255;
             capacity = 1;
             rawAcl = new RawAcl(revision, capacity);
-            //199  has all AceFlags except InheritOnly and Inherited                                   
+            //199  has all AceFlags except InheritOnly and Inherited
             gAce = new CommonAce((AceFlags)(FlagsForAce.AuditFlags | FlagsForAce.OI | FlagsForAce.CI | FlagsForAce.NP), AceQualifier.AccessDenied, 1,
                 new SecurityIdentifier(Utils.TranslateStringConstFormatSidToStandardFormatSid("BG")), false, null);
             rawAcl.InsertAce(0, gAce);
-            //215  has all AceFlags except InheritOnly                                 
+            //215  has all AceFlags except InheritOnly
             gAce = new CommonAce((AceFlags)(FlagsForAce.AuditFlags | FlagsForAce.OI | FlagsForAce.CI | FlagsForAce.NP | FlagsForAce.IH), AceQualifier.AccessAllowed, 1,
                 new SecurityIdentifier(Utils.TranslateStringConstFormatSidToStandardFormatSid("BA")), false, null);
             rawAcl.InsertAce(1, gAce);
@@ -202,7 +202,7 @@ namespace System.Security.AccessControl.Tests
             revision = 255;
             capacity = 1;
             rawAcl = new RawAcl(revision, capacity);
-            //215  has all AceFlags except InheritOnly                                 
+            //215  has all AceFlags except InheritOnly
             gAce = new CommonAce((AceFlags)215, AceQualifier.AccessAllowed, 1,
                 new SecurityIdentifier(Utils.TranslateStringConstFormatSidToStandardFormatSid("BG")), false, null);
             rawAcl.InsertAce(0, gAce);
@@ -270,4 +270,4 @@ namespace System.Security.AccessControl.Tests
 
         }
     }
-}
\ No newline at end of file
+}
index c4b35a5..bcefa88 100644 (file)
@@ -89,7 +89,7 @@ namespace Internal.Cryptography
         private void Reset()
         {
             // Ensure we've called CryptEncrypt with the final=true flag so the handle is reset property
-            EncryptData(_hKey, Array.Empty<Byte>(), 0, 0, Array.Empty<Byte>(), 0, 0, true);
+            EncryptData(_hKey, Array.Empty<byte>(), 0, 0, Array.Empty<byte>(), 0, 0, true);
         }
 
         private int Transform(byte[] input, int inputOffset, int count, byte[] output, int outputOffset, bool isFinal)
index 9975d26..bfe16eb 100644 (file)
@@ -189,7 +189,7 @@ namespace System.Security.Cryptography
                 _hash.TransformBlock(_salt, 0, _salt.Length, _salt, 0);
             }
 
-            _hash.TransformFinalBlock(Array.Empty<Byte>(), 0, 0);
+            _hash.TransformFinalBlock(Array.Empty<byte>(), 0, 0);
             _baseValue = _hash.Hash;
             _hash.Initialize();
 
index 0c92ff1..188bdeb 100644 (file)
@@ -72,7 +72,7 @@ namespace System.Security.Cryptography.Xml
             }
         }
 
-        internal protected bool CacheValid
+        protected internal bool CacheValid
         {
             get
             {
index 02e54ea..32a7f8d 100644 (file)
@@ -11,8 +11,8 @@ namespace System.Security.Cryptography.Xml
     // abstract class providing symmetric key wrap implementation
     internal static class SymmetricKeyWrap
     {
-        private readonly static byte[] s_rgbTripleDES_KW_IV = { 0x4a, 0xdd, 0xa2, 0x2c, 0x79, 0xe8, 0x21, 0x05 };
-        private readonly static byte[] s_rgbAES_KW_IV = { 0xa6, 0xa6, 0xa6, 0xa6, 0xa6, 0xa6, 0xa6, 0xa6 };
+        private static readonly byte[] s_rgbTripleDES_KW_IV = { 0x4a, 0xdd, 0xa2, 0x2c, 0x79, 0xe8, 0x21, 0x05 };
+        private static readonly byte[] s_rgbAES_KW_IV = { 0xa6, 0xa6, 0xa6, 0xa6, 0xa6, 0xa6, 0xa6, 0xa6 };
 
         //
         // internal static methods
index 39441fc..7277382 100644 (file)
@@ -4,7 +4,7 @@
 // MonoTests.System.Security.Cryptography.Xml.AssertCrypto.cs
 //
 // Author:
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
index 005b7ca..0c9d4ca 100644 (file)
@@ -4,7 +4,7 @@
 // DSAKeyValueTest.cs - Test Cases for DSAKeyValue
 //
 // Author:
-//     Sebastien Pouliot (spouliot@motus.com)
+//  Sebastien Pouliot (spouliot@motus.com)
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 //
index f8190fe..c5ca767 100644 (file)
@@ -4,8 +4,8 @@
 // DataObjectTest.cs - Test Cases for DataObject
 //
 // Author:
-//     Sebastien Pouliot (spouliot@motus.com)
-//     Atsushi Enomoto (atsushi@ximian.com)
+//  Sebastien Pouliot (spouliot@motus.com)
+//  Atsushi Enomoto (atsushi@ximian.com)
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 // (C) 2004 Novell Inc.
@@ -132,7 +132,7 @@ namespace System.Security.Cryptography.Xml.Tests
             DataObject obj = new DataObject();
             XmlElement el1 = obj.GetXml();
             obj.LoadXml(doc.DocumentElement);
-            //                 obj.Id = "hogehoge";
+            //            obj.Id = "hogehoge";
             XmlElement el2 = obj.GetXml();
             Assert.Equal(doc, el2.OwnerDocument);
         }
@@ -163,10 +163,10 @@ namespace System.Security.Cryptography.Xml.Tests
             XmlElement el1 = obj.GetXml();
             Assert.Equal("<Object Id=\"hoge\" MimeType=\"application/octet-stream\" Encoding=\"euc-kr\" xmlns=\"http://www.w3.org/2000/09/xmldsig#\">test</Object>", el1.OuterXml);
             /* looks curious? but the element does not look to 
-                          be appended to the document.
-                          Just commented out since it is not fixed.
-                       Assert.AreEqual (String.Empty, el1.OwnerDocument.OuterXml);
-                       */
+               be appended to the document.
+               Just commented out since it is not fixed.
+            Assert.AreEqual (String.Empty, el1.OwnerDocument.OuterXml);
+            */
         }
 
         [Fact]
index 86cfc46..8bcfe30 100644 (file)
@@ -4,7 +4,7 @@
 // DataReferenceTest.cs
 //
 // Author:
-//     Atsushi Enomoto  <atsushi@ximian.com>
+//  Atsushi Enomoto  <atsushi@ximian.com>
 //
 // Copyright (C) 2006 Novell, Inc.
 //
index b004fcd..9bd54a7 100644 (file)
@@ -4,7 +4,7 @@
 // EncryptedXmlTest.cs
 //
 // Author:
-//     Atsushi Enomoto  <atsushi@ximian.com>
+//  Atsushi Enomoto  <atsushi@ximian.com>
 //
 // Copyright (C) 2006 Novell, Inc (http://www.novell.com)
 //
index eff7bad..1e7c3ff 100644 (file)
@@ -4,7 +4,7 @@
 // KeyInfoNameTest.cs - Test Cases for KeyInfoName
 //
 // Author:
-//     Sebastien Pouliot (spouliot@motus.com)
+//  Sebastien Pouliot (spouliot@motus.com)
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 //
index ab9a11f..9a0d801 100644 (file)
@@ -4,7 +4,7 @@
 // KeyInfoNodeTest.cs - Test Cases for KeyInfoNode
 //
 // Author:
-//     Sebastien Pouliot (spouliot@motus.com)
+//  Sebastien Pouliot (spouliot@motus.com)
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 //
index 4a46d47..48f9872 100644 (file)
@@ -4,7 +4,7 @@
 // KeyInfoRetrievalMethodTest.cs - Test Cases for KeyInfoRetrievalMethod
 //
 // Author:
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
index 1e4a23e..e43d067 100644 (file)
@@ -4,7 +4,7 @@
 // KeyInfoTest.cs - Test Cases for KeyInfo
 //
 // Author:
-//     Sebastien Pouliot <sebastien@ximian.com>
+//  Sebastien Pouliot <sebastien@ximian.com>
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 // Copyright (C) 2004-2005 Novell, Inc (http://www.novell.com)
index f80e5cc..2ed7fff 100644 (file)
@@ -4,7 +4,7 @@
 // KeyInfoX509DataTest.cs - Test Cases for KeyInfoX509Data
 //
 // Author:
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
index 019659f..9b69f15 100644 (file)
@@ -4,7 +4,7 @@
 // RSAKeyValueTest.cs - Test Cases for RSAKeyValue
 //
 // Author:
-//     Sebastien Pouliot (spouliot@motus.com)
+//  Sebastien Pouliot (spouliot@motus.com)
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 //
index 6ae1826..ed583e6 100644 (file)
@@ -4,7 +4,7 @@
 // ReferenceTest.cs - Test Cases for Reference
 //
 // Author:
-//     Sebastien Pouliot <sebastien@ximian.com>
+//  Sebastien Pouliot <sebastien@ximian.com>
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 // (C) 2004 Novell (http://www.novell.com)
@@ -250,10 +250,10 @@ namespace System.Security.Cryptography.Xml.Tests
         }
 
         const string xml = @"<player bats=""left"" id=""10012"" throws=""right"">
-       <!-- Here&apos;s a comment -->
-       <name>Alfonso Soriano</name>
-       <position>2B</position>
-       <team>New York Yankees</team>
+    <!-- Here&apos;s a comment -->
+    <name>Alfonso Soriano</name>
+    <position>2B</position>
+    <team>New York Yankees</team>
 <dsig:Signature xmlns=""http://www.w3.org/2000/09/xmldsig#"" xmlns:dsig=""http://www.w3.org/2000/09/xmldsig#"">"
 + @"<dsig:SignedInfo><dsig:CanonicalizationMethod Algorithm=""http://www.w3.org/TR/2001/REC-xml-c14n-withcomments-20010315""/><dsig:SignatureMethod Algorithm=""http://www.w3.org/2000/09/xmldsig#rsa-sha1""/>"
 + @"<dsig:Reference URI=""""><dsig:Transforms><dsig:Transform Algorithm=""http://www.w3.org/2000/09/xmldsig#enveloped-signature""/></dsig:Transforms><dsig:DigestMethod Algorithm=""http://www.w3.org/2000/09/xmldsig#sha1""/><dsig:DigestValue>nDF2V/bzRd0VE3EwShWtsBzTEDc=</dsig:DigestValue></dsig:Reference></dsig:SignedInfo><dsig:SignatureValue>fbye4Xm//RPUTsLd1dwJPo0gPZYX6gVYCEB/gz2348EARNk/nCCch1fFfpuqAGMKg4ayVC0yWkUyE5V4QB33jaGlh9wuNQSjxs6TIvFwSsT+0ioDgVgFv0gVeasbyNL4rFEHuAWL8QKwDT9L6b2wUvJC90DmpBs9GMR2jTZIWlM=</dsig:SignatureValue><dsig:KeyInfo><dsig:X509Data><dsig:X509Certificate>MIIC0DCCAjmgAwIBAgIDD0JBMA0GCSqGSIb3DQEBBAUAMHwxCzAJBgNVBAYTAlVTMREwDwYDVQQIEwhOZXcgWW9yazERMA8GA1UEBxMITmV3IFlvcmsxGTAXBgNVBAoTEFBoYW9zIFRlY2hub2xvZ3kxFDASBgNVBAsTC0VuZ2luZWVyaW5nMRYwFAYDVQQDEw1UZXN0IENBIChSU0EpMB4XDTAyMDQyOTE5MTY0MFoXDTEyMDQyNjE5MTY0MFowgYAxCzAJBgNVBAYTAlVTMREwDwYDVQQIEwhOZXcgWW9yazERMA8GA1UEBxMITmV3IFlvcmsxGTAXBgNVBAoTEFBoYW9zIFRlY2hub2xvZ3kxFDASBgNVBAsTC0VuZ2luZWVyaW5nMRowGAYDVQQDExFUZXN0IENsaWVudCAoUlNBKTCBnzANBgkqhkiG9w0BAQEFAAOBjQAwgYkCgYEAgIb6nAB9oS/AI5jIj6WymvQhRxiMlE07G4abmMliYi5zWzvaFE2tnU+RZIBgtoXcgDEIU/vsLQut7nzCn9mHxC8JEaV4D4U91j64AyZakShqJw7qjJfqUxxPL0yJv2oFiouPDjGuJ9JPi0NrsZq+yfWfM54s4b9SNkcOIVMybZUCAwEAAaNbMFkwDAYDVR0TAQH/BAIwADAPBgNVHQ8BAf8EBQMDB9gAMBkGA1UdEQQSMBCBDnRlY2hAcGhhb3MuY29tMB0GA1UdDgQWBBQT58rBCxPmVLeZaYGRqVROnQlFbzANBgkqhkiG9w0BAQQFAAOBgQCxbCovFST25t+ryN1RipqozxJQcguKfeCwbfgBNobzcRvoW0kSIf7zi4mtQajDM0NfslFF51/dex5Rn64HmFFshSwSvQQMyf5Cfaqv2XQ60OXq6nAFG6WbHoge6RqfIez2MWDLoSB6plsjKtMmL3mcybBhROtX5GGuLx1NtfhNFQ==</dsig:X509Certificate><dsig:X509IssuerSerial><dsig:X509IssuerName>CN=Test CA (RSA),OU=Engineering,O=Phaos Technology,L=New York,ST=New York,C=US</dsig:X509IssuerName><dsig:X509SerialNumber>1000001</dsig:X509SerialNumber></dsig:X509IssuerSerial><dsig:X509SubjectName>CN=Test Client (RSA),OU=Engineering,O=Phaos Technology,L=New York,ST=New York,C=US</dsig:X509SubjectName><dsig:X509SKI>E+fKwQsT5lS3mWmBkalUTp0JRW8=</dsig:X509SKI></dsig:X509Data></dsig:KeyInfo></dsig:Signature></player>";
index 60415eb..063be49 100644 (file)
@@ -4,7 +4,7 @@
 // SignatureTest.cs - Test Cases for SignedXml
 //
 // Author:
-//     Sebastien Pouliot <sebastien@ximian.com>
+//  Sebastien Pouliot <sebastien@ximian.com>
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 // Copyright (C) 2004-2005 Novell, Inc (http://www.novell.com)
index 2e1502a..c4c0fff 100644 (file)
@@ -4,7 +4,7 @@
 // SignedInfoTest.cs - Test Cases for SignedInfo
 //
 // Author:
-//     Sebastien Pouliot <sebastien@ximian.com>
+//  Sebastien Pouliot <sebastien@ximian.com>
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 // Copyright (C) 2005, 2009 Novell, Inc (http://www.novell.com)
@@ -119,10 +119,10 @@ namespace System.Security.Cryptography.Xml.Tests
 
         // from phaos testcase
         const string xmlForGetXml = @"<player bats=""left"" id=""10012"" throws=""right"">
-       <!-- Here&apos;s a comment -->
-       <name>Alfonso Soriano</name>
-       <position>2B</position>
-       <team>New York Yankees</team>
+    <!-- Here&apos;s a comment -->
+    <name>Alfonso Soriano</name>
+    <position>2B</position>
+    <team>New York Yankees</team>
 <dsig:Signature xmlns=""http://www.w3.org/2000/09/xmldsig#"" xmlns:dsig=""http://www.w3.org/2000/09/xmldsig#"">"
 + @"<dsig:SignedInfo><dsig:CanonicalizationMethod Algorithm=""http://www.w3.org/TR/2001/REC-xml-c14n-withcomments-20010315""/><dsig:SignatureMethod Algorithm=""http://www.w3.org/2000/09/xmldsig#rsa-sha1""/>"
 + @"<dsig:Reference URI=""""><dsig:Transforms><dsig:Transform Algorithm=""http://www.w3.org/2000/09/xmldsig#enveloped-signature""/></dsig:Transforms><dsig:DigestMethod Algorithm=""http://www.w3.org/2000/09/xmldsig#sha1""/><dsig:DigestValue>nDF2V/bzRd0VE3EwShWtsBzTEDc=</dsig:DigestValue></dsig:Reference></dsig:SignedInfo><dsig:SignatureValue>fbye4Xm//RPUTsLd1dwJPo0gPZYX6gVYCEB/gz2348EARNk/nCCch1fFfpuqAGMKg4ayVC0yWkUyE5V4QB33jaGlh9wuNQSjxs6TIvFwSsT+0ioDgVgFv0gVeasbyNL4rFEHuAWL8QKwDT9L6b2wUvJC90DmpBs9GMR2jTZIWlM=</dsig:SignatureValue><dsig:KeyInfo><dsig:X509Data><dsig:X509Certificate>MIIC0DCCAjmgAwIBAgIDD0JBMA0GCSqGSIb3DQEBBAUAMHwxCzAJBgNVBAYTAlVTMREwDwYDVQQIEwhOZXcgWW9yazERMA8GA1UEBxMITmV3IFlvcmsxGTAXBgNVBAoTEFBoYW9zIFRlY2hub2xvZ3kxFDASBgNVBAsTC0VuZ2luZWVyaW5nMRYwFAYDVQQDEw1UZXN0IENBIChSU0EpMB4XDTAyMDQyOTE5MTY0MFoXDTEyMDQyNjE5MTY0MFowgYAxCzAJBgNVBAYTAlVTMREwDwYDVQQIEwhOZXcgWW9yazERMA8GA1UEBxMITmV3IFlvcmsxGTAXBgNVBAoTEFBoYW9zIFRlY2hub2xvZ3kxFDASBgNVBAsTC0VuZ2luZWVyaW5nMRowGAYDVQQDExFUZXN0IENsaWVudCAoUlNBKTCBnzANBgkqhkiG9w0BAQEFAAOBjQAwgYkCgYEAgIb6nAB9oS/AI5jIj6WymvQhRxiMlE07G4abmMliYi5zWzvaFE2tnU+RZIBgtoXcgDEIU/vsLQut7nzCn9mHxC8JEaV4D4U91j64AyZakShqJw7qjJfqUxxPL0yJv2oFiouPDjGuJ9JPi0NrsZq+yfWfM54s4b9SNkcOIVMybZUCAwEAAaNbMFkwDAYDVR0TAQH/BAIwADAPBgNVHQ8BAf8EBQMDB9gAMBkGA1UdEQQSMBCBDnRlY2hAcGhhb3MuY29tMB0GA1UdDgQWBBQT58rBCxPmVLeZaYGRqVROnQlFbzANBgkqhkiG9w0BAQQFAAOBgQCxbCovFST25t+ryN1RipqozxJQcguKfeCwbfgBNobzcRvoW0kSIf7zi4mtQajDM0NfslFF51/dex5Rn64HmFFshSwSvQQMyf5Cfaqv2XQ60OXq6nAFG6WbHoge6RqfIez2MWDLoSB6plsjKtMmL3mcybBhROtX5GGuLx1NtfhNFQ==</dsig:X509Certificate><dsig:X509IssuerSerial><dsig:X509IssuerName>CN=Test CA (RSA),OU=Engineering,O=Phaos Technology,L=New York,ST=New York,C=US</dsig:X509IssuerName><dsig:X509SerialNumber>1000001</dsig:X509SerialNumber></dsig:X509IssuerSerial><dsig:X509SubjectName>CN=Test Client (RSA),OU=Engineering,O=Phaos Technology,L=New York,ST=New York,C=US</dsig:X509SubjectName><dsig:X509SKI>E+fKwQsT5lS3mWmBkalUTp0JRW8=</dsig:X509SKI></dsig:X509Data></dsig:KeyInfo></dsig:Signature></player>";
index ea679f0..8882267 100644 (file)
@@ -4,7 +4,7 @@
 // SignedXmlTest.cs - Test Cases for SignedXml
 //
 // Author:
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 // Copyright (C) 2004-2005, 2008 Novell, Inc (http://www.novell.com)
index 4421363..296a027 100644 (file)
@@ -4,7 +4,7 @@
 // TransformChainTest.cs - Test Cases for TransformChain
 //
 // Author:
-//     Sebastien Pouliot (spouliot@motus.com)
+//  Sebastien Pouliot (spouliot@motus.com)
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 //
index 24927f3..8f2b505 100644 (file)
@@ -4,7 +4,7 @@
 // Unit tests for Transform
 //
 // Author:
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // Copyright (C) 2008 Novell, Inc (http://www.novell.com)
 //
index 1557e9c..d1691c0 100644 (file)
@@ -4,7 +4,7 @@
 // Unit tests for XmlDecryptionTransform
 //
 // Author:
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // Copyright (C) 2008 Novell, Inc (http://www.novell.com)
 //
index 2aadc04..918ad18 100644 (file)
@@ -4,7 +4,7 @@
 // XmlDsigBase64TransformTest.cs - Test Cases for XmlDsigBase64Transform
 //
 // Author:
-//     Sebastien Pouliot <sebastien@ximian.com>
+//  Sebastien Pouliot <sebastien@ximian.com>
 //
 // (C) 2002 Motus Technologies Inc. (http://www.motus.com)
 // (C) 2004 Novell (http://www.novell.com)
index 9f3d2a3..1783d98 100644 (file)
@@ -4,8 +4,8 @@
 // XmlDsigC14NTransformTest.cs - Test Cases for XmlDsigC14NTransform
 //
 // Author:
-//     Sebastien Pouliot <sebastien@ximian.com>
-//     Aleksey Sanin (aleksey@aleksey.com)
+//  Sebastien Pouliot <sebastien@ximian.com>
+//  Aleksey Sanin (aleksey@aleksey.com)
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 // (C) 2003 Aleksey Sanin (aleksey@aleksey.com)
@@ -276,7 +276,7 @@ namespace System.Security.Cryptography.Xml.Tests
                 "       <e7 xmlns=\"http://www.ietf.org\">\n" +
                 "           <e8 xmlns=\"\">\n" +
                 "               <e9 xmlns:a=\"http://www.ietf.org\" attr=\"default\"></e9>\n" +
-                //                     "               <e9 xmlns:a=\"http://www.ietf.org\"></e9>\n" +
+                //                    "               <e9 xmlns:a=\"http://www.ietf.org\"></e9>\n" +
                 "           </e8>\n" +
                 "       </e7>\n" +
                 "   </e6>\n" +
index 7802020..c472613 100644 (file)
@@ -2,10 +2,10 @@
 // See the LICENSE file in the project root for more information
 //
 // XmlDsigC14NWithCommentsTransformTest.cs 
-//     - Test Cases for XmlDsigC14NWithCommentsTransform
+//  - Test Cases for XmlDsigC14NWithCommentsTransform
 //
 // Author:
-//     Sebastien Pouliot <sebastien@ximian.com>
+//  Sebastien Pouliot <sebastien@ximian.com>
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 // Copyright (C) 2004-2005 Novell, Inc (http://www.novell.com)
@@ -213,7 +213,7 @@ namespace System.Security.Cryptography.Xml.Tests
                 "       <e7 xmlns=\"http://www.ietf.org\">\n" +
                 "           <e8 xmlns=\"\">\n" +
                 "               <e9 xmlns:a=\"http://www.ietf.org\" attr=\"default\"></e9>\n" +
-                //                         "               <e9 xmlns:a=\"http://www.ietf.org\"></e9>\n" +
+                //                    "               <e9 xmlns:a=\"http://www.ietf.org\"></e9>\n" +
                 "           </e8>\n" +
                 "       </e7>\n" +
                 "   </e6>\n" +
index bb4bdd5..821debd 100644 (file)
@@ -5,10 +5,10 @@
 //
 // Author:
 //  original:
-//     Sebastien Pouliot <sebastien@ximian.com>
-//     Aleksey Sanin (aleksey@aleksey.com)
+//  Sebastien Pouliot <sebastien@ximian.com>
+//  Aleksey Sanin (aleksey@aleksey.com)
 //  this file:
-//     Atsushi Enomoto <atsushi@ximian.com>
+//  Atsushi Enomoto <atsushi@ximian.com>
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 // (C) 2003 Aleksey Sanin (aleksey@aleksey.com)
@@ -316,7 +316,7 @@ namespace System.Security.Cryptography.Xml.Tests
         }
 
         [Fact]
-        //             [Ignore ("This test should be fine, but it does not pass under MS.NET")]
+        //        [Ignore ("This test should be fine, but it does not pass under MS.NET")]
         public void ExcC14NSpecExample4()
         {
             string res = ExecuteXmlDSigExcC14NTransform(ExcC14NSpecExample4Input);
@@ -456,7 +456,7 @@ namespace System.Security.Cryptography.Xml.Tests
                 "       <e7 xmlns=\"http://www.ietf.org\">\n" +
                 "           <e8 xmlns=\"\">\n" +
                 "               <e9 attr=\"default\"></e9>\n" +
-                //                     "               <e9 xmlns:a=\"http://www.ietf.org\"></e9>\n" +
+                //                    "               <e9 xmlns:a=\"http://www.ietf.org\"></e9>\n" +
                 "           </e8>\n" +
                 "       </e7>\n" +
                 "   </e6>\n" +
index 0b9683c..f9d80b2 100644 (file)
@@ -6,10 +6,10 @@
 //
 // Author:
 //  original:
-//     Sebastien Pouliot <sebastien@ximian.com>
-//     Aleksey Sanin (aleksey@aleksey.com)
+//  Sebastien Pouliot <sebastien@ximian.com>
+//  Aleksey Sanin (aleksey@aleksey.com)
 //  this file:
-//     Gert Driesen <drieseng@users.sourceforge.net>
+//  Gert Driesen <drieseng@users.sourceforge.net>
 //
 // (C) 2003 Aleksey Sanin (aleksey@aleksey.com)
 // (C) 2004 Novell (http://www.novell.com)
index 671dd67..fabb64e 100644 (file)
@@ -4,7 +4,7 @@
 // XmlDsigXPathTransformTest.cs - Test Cases for XmlDsigXPathTransform
 //
 // Author:
-//     Sebastien Pouliot <sebastien@ximian.com>
+//  Sebastien Pouliot <sebastien@ximian.com>
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 // Copyright (C) 2004-2005 Novell, Inc (http://www.novell.com)
@@ -240,8 +240,8 @@ namespace System.Security.Cryptography.Xml.Tests
             // MS.NET bug - ms.net returns ns node even when the
             // current node is ns node (it is like returning
             // attribute from attribute nodes).
-            //                 Assert.Equal (XmlNodeType.Attribute, nl [4].NodeType);
-            //                 Assert.Equal ("xmlns", nl [4].LocalName);
+            //            Assert.Equal (XmlNodeType.Attribute, nl [4].NodeType);
+            //            Assert.Equal ("xmlns", nl [4].LocalName);
         }
 
         [Fact]
@@ -251,7 +251,7 @@ namespace System.Security.Cryptography.Xml.Tests
             XmlDsigXPathTransform t = new XmlDsigXPathTransform();
             XmlDocument xpdoc = new XmlDocument();
             string ns = "http://www.w3.org/2000/09/xmldsig#";
-            //                 string xpath = "<XPath xmlns='" + ns + "' xmlns:x='urn:foo'>here()</XPath>";
+            //            string xpath = "<XPath xmlns='" + ns + "' xmlns:x='urn:foo'>here()</XPath>";
             string xpath = "<XPath xmlns='" + ns + "' xmlns:x='urn:foo'></XPath>";
             xpdoc.LoadXml(xpath);
             t.LoadInnerXml(xpdoc.ChildNodes);
index 25d2e84..0a68fc0 100644 (file)
@@ -4,8 +4,8 @@
 // XmlDsigXsltTransformTest.cs - Test Cases for XmlDsigXsltTransform
 //
 // Author:
-//     Sebastien Pouliot <sebastien@ximian.com>
-//     Atsushi Enomoto <atsushi@ximian.com>
+//  Sebastien Pouliot <sebastien@ximian.com>
+//  Atsushi Enomoto <atsushi@ximian.com>
 //
 // (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
 // (C) 2004 Novell (http://www.novell.com)
index c22e51b..a140ce2 100644 (file)
@@ -5,10 +5,10 @@
 //
 // Author:
 //  original:
-//     Sebastien Pouliot <sebastien@ximian.com>
-//     Aleksey Sanin (aleksey@aleksey.com)
+//  Sebastien Pouliot <sebastien@ximian.com>
+//  Aleksey Sanin (aleksey@aleksey.com)
 //  this file:
-//     Gert Driesen <drieseng@users.sourceforge.net>
+//  Gert Driesen <drieseng@users.sourceforge.net>
 //
 // (C) 2003 Aleksey Sanin (aleksey@aleksey.com)
 // (C) 2004 Novell (http://www.novell.com)
@@ -159,7 +159,7 @@ namespace System.Security.Cryptography.Xml.Tests
         {
             AssertExtensions.Throws<ArgumentException>("type", () => transform.GetOutput(typeof(string)));
         }
-               
+
         [Fact]
         public static void ItDecryptsLicense()
         {
index 0306384..f01a3ec 100644 (file)
@@ -8,9 +8,9 @@ using System.Security.Permissions;
 namespace System.Configuration
 {
     [AttributeUsage(AttributeTargets.All, AllowMultiple = true, Inherited = false)]
-    sealed public class ConfigurationPermissionAttribute : CodeAccessSecurityAttribute
+    public sealed class ConfigurationPermissionAttribute : CodeAccessSecurityAttribute
     {
         public ConfigurationPermissionAttribute(SecurityAction action) : base(default(SecurityAction)) { }
         public override IPermission CreatePermission() { return default(IPermission); }
     }
-}
\ No newline at end of file
+}
index 948fb97..2004c56 100644 (file)
@@ -7,7 +7,7 @@ namespace System.Security.Permissions
     [AttributeUsage(AttributeTargets.Method | AttributeTargets.Constructor
      | AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Assembly,
     AllowMultiple = true, Inherited = false)]
-    sealed public class IsolatedStorageFilePermissionAttribute : IsolatedStoragePermissionAttribute
+    public sealed class IsolatedStorageFilePermissionAttribute : IsolatedStoragePermissionAttribute
     {
         public IsolatedStorageFilePermissionAttribute(SecurityAction action) : base(action) { }
         public override IPermission CreatePermission() { return null; }
index e10cbb5..bbc06d8 100644 (file)
@@ -24,7 +24,7 @@ namespace System.Security.Permissions
         SafeImage,
         AllImage,
     }
-    sealed public class MediaPermission : CodeAccessPermission, IUnrestrictedPermission
+    public sealed class MediaPermission : CodeAccessPermission, IUnrestrictedPermission
     {
         public MediaPermission() { }
         public MediaPermission(PermissionState state) { }
@@ -47,7 +47,7 @@ namespace System.Security.Permissions
         public MediaPermissionImage Image { get { return MediaPermissionImage.AllImage; } }
     }
     [AttributeUsage(AttributeTargets.Method | AttributeTargets.Constructor | AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Assembly, AllowMultiple = true, Inherited = false)]
-    sealed public class MediaPermissionAttribute : CodeAccessSecurityAttribute
+    public sealed class MediaPermissionAttribute : CodeAccessSecurityAttribute
     {
         public MediaPermissionAttribute(SecurityAction action) : base(action) { }
         public override IPermission CreatePermission() { return new MediaPermission(); }
index 2db3f62..f0b5cb1 100644 (file)
@@ -9,7 +9,7 @@ namespace System.Security.Permissions
         Safe,
         Unrestricted
     }
-    sealed public class WebBrowserPermission : CodeAccessPermission, IUnrestrictedPermission
+    public sealed class WebBrowserPermission : CodeAccessPermission, IUnrestrictedPermission
     {
         public WebBrowserPermission() { }
         public WebBrowserPermission(PermissionState state) { }
@@ -25,7 +25,7 @@ namespace System.Security.Permissions
     }
 
     [AttributeUsage(AttributeTargets.Method | AttributeTargets.Constructor | AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Assembly, AllowMultiple = true, Inherited = false)]
-    sealed public class WebBrowserPermissionAttribute : CodeAccessSecurityAttribute
+    public sealed class WebBrowserPermissionAttribute : CodeAccessSecurityAttribute
     {
         public WebBrowserPermissionAttribute(SecurityAction action) : base(action) { }
         public override IPermission CreatePermission() { return new WebBrowserPermission(); }
index 4857cd6..5b2746c 100644 (file)
@@ -8,7 +8,7 @@ using System.Security.Permissions;
 namespace System.Web
 {
     [AttributeUsage(AttributeTargets.All, AllowMultiple = true, Inherited = false )]
-    sealed public class AspNetHostingPermissionAttribute : CodeAccessSecurityAttribute
+    public sealed class AspNetHostingPermissionAttribute : CodeAccessSecurityAttribute
     {
         public AspNetHostingPermissionAttribute(SecurityAction action) : base(action) { }
         public AspNetHostingPermissionLevel Level { get; set; }
index 694fd06..cc5ba53 100644 (file)
@@ -2,7 +2,7 @@
 // See the LICENSE file in the project root for more information.
 //
 // Author:
-//     Sebastien Pouliot (spouliot@motus.com)
+//  Sebastien Pouliot (spouliot@motus.com)
 //
 // (C) 2003 Motus Technologies Inc. (http://www.motus.com)
 
index 2f5a249..9607013 100644 (file)
@@ -2,8 +2,8 @@
 // See the LICENSE file in the project root for more information.
 //
 // Authors:
-//     Lawrence Pit (loz@cable.a2000.nl)
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Lawrence Pit (loz@cable.a2000.nl)
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // Portions (C) 2004 Motus Technologies Inc. (http://www.motus.com)
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
index dd05996..21ac7b0 100644 (file)
@@ -45,6 +45,6 @@ namespace System.ServiceModel.Syndication
 
         internal override bool IsInline => true;
 
-        internal protected virtual SyndicationCategory CreateCategory() => new SyndicationCategory();
+        protected internal virtual SyndicationCategory CreateCategory() => new SyndicationCategory();
     }
 }
index bdb63a1..51e7ce5 100644 (file)
@@ -54,7 +54,7 @@ namespace System.ServiceModel.Syndication
 
         public abstract void WriteTo(XmlWriter writer);
 
-        internal static protected SyndicationCategory CreateCategory(SyndicationFeed feed)
+        protected internal static SyndicationCategory CreateCategory(SyndicationFeed feed)
         {
             if (feed == null)
             {
@@ -64,7 +64,7 @@ namespace System.ServiceModel.Syndication
             return GetNonNullValue(feed.CreateCategory(), SR.FeedCreatedNullCategory);
         }
 
-        internal static protected SyndicationCategory CreateCategory(SyndicationItem item)
+        protected internal static SyndicationCategory CreateCategory(SyndicationItem item)
         {
             if (item == null)
             {
@@ -74,7 +74,7 @@ namespace System.ServiceModel.Syndication
             return GetNonNullValue(item.CreateCategory(), SR.ItemCreatedNullCategory);
         }
 
-        internal static protected SyndicationItem CreateItem(SyndicationFeed feed)
+        protected internal static SyndicationItem CreateItem(SyndicationFeed feed)
         {
             if (feed == null)
             {
@@ -84,7 +84,7 @@ namespace System.ServiceModel.Syndication
             return GetNonNullValue(feed.CreateItem(), SR.FeedCreatedNullItem);
         }
 
-        internal static protected SyndicationLink CreateLink(SyndicationFeed feed)
+        protected internal static SyndicationLink CreateLink(SyndicationFeed feed)
         {
             if (feed == null)
             {
@@ -94,7 +94,7 @@ namespace System.ServiceModel.Syndication
             return GetNonNullValue(feed.CreateLink(), SR.FeedCreatedNullPerson);
         }
 
-        internal static protected SyndicationLink CreateLink(SyndicationItem item)
+        protected internal static SyndicationLink CreateLink(SyndicationItem item)
         {
             if (item == null)
             {
@@ -104,7 +104,7 @@ namespace System.ServiceModel.Syndication
             return GetNonNullValue(item.CreateLink(), SR.ItemCreatedNullPerson);
         }
 
-        internal static protected SyndicationPerson CreatePerson(SyndicationFeed feed)
+        protected internal static SyndicationPerson CreatePerson(SyndicationFeed feed)
         {
             if (feed == null)
             {
@@ -114,7 +114,7 @@ namespace System.ServiceModel.Syndication
             return GetNonNullValue(feed.CreatePerson(), SR.FeedCreatedNullPerson);
         }
 
-        internal static protected SyndicationPerson CreatePerson(SyndicationItem item)
+        protected internal static SyndicationPerson CreatePerson(SyndicationItem item)
         {
             if (item == null)
             {
@@ -124,7 +124,7 @@ namespace System.ServiceModel.Syndication
             return GetNonNullValue(item.CreatePerson(), SR.ItemCreatedNullPerson);
         }
 
-        internal static protected void LoadElementExtensions(XmlReader reader, SyndicationFeed feed, int maxExtensionSize)
+        protected internal static void LoadElementExtensions(XmlReader reader, SyndicationFeed feed, int maxExtensionSize)
         {
             if (feed == null)
             {
@@ -134,7 +134,7 @@ namespace System.ServiceModel.Syndication
             feed.LoadElementExtensions(reader, maxExtensionSize);
         }
 
-        internal static protected void LoadElementExtensions(XmlReader reader, SyndicationItem item, int maxExtensionSize)
+        protected internal static void LoadElementExtensions(XmlReader reader, SyndicationItem item, int maxExtensionSize)
         {
             if (item == null)
             {
@@ -144,7 +144,7 @@ namespace System.ServiceModel.Syndication
             item.LoadElementExtensions(reader, maxExtensionSize);
         }
 
-        internal static protected void LoadElementExtensions(XmlReader reader, SyndicationCategory category, int maxExtensionSize)
+        protected internal static void LoadElementExtensions(XmlReader reader, SyndicationCategory category, int maxExtensionSize)
         {
             if (category == null)
             {
@@ -154,7 +154,7 @@ namespace System.ServiceModel.Syndication
             category.LoadElementExtensions(reader, maxExtensionSize);
         }
 
-        internal static protected void LoadElementExtensions(XmlReader reader, SyndicationLink link, int maxExtensionSize)
+        protected internal static void LoadElementExtensions(XmlReader reader, SyndicationLink link, int maxExtensionSize)
         {
             if (link == null)
             {
@@ -164,7 +164,7 @@ namespace System.ServiceModel.Syndication
             link.LoadElementExtensions(reader, maxExtensionSize);
         }
 
-        internal static protected void LoadElementExtensions(XmlReader reader, SyndicationPerson person, int maxExtensionSize)
+        protected internal static void LoadElementExtensions(XmlReader reader, SyndicationPerson person, int maxExtensionSize)
         {
             if (person == null)
             {
@@ -174,7 +174,7 @@ namespace System.ServiceModel.Syndication
             person.LoadElementExtensions(reader, maxExtensionSize);
         }
 
-        internal static protected bool TryParseAttribute(string name, string ns, string value, SyndicationFeed feed, string version)
+        protected internal static bool TryParseAttribute(string name, string ns, string value, SyndicationFeed feed, string version)
         {
             if (feed == null)
             {
@@ -188,7 +188,7 @@ namespace System.ServiceModel.Syndication
             return feed.TryParseAttribute(name, ns, value, version);
         }
 
-        internal static protected bool TryParseAttribute(string name, string ns, string value, SyndicationItem item, string version)
+        protected internal static bool TryParseAttribute(string name, string ns, string value, SyndicationItem item, string version)
         {
             if (item == null)
             {
@@ -202,7 +202,7 @@ namespace System.ServiceModel.Syndication
             return item.TryParseAttribute(name, ns, value, version);
         }
 
-        internal static protected bool TryParseAttribute(string name, string ns, string value, SyndicationCategory category, string version)
+        protected internal static bool TryParseAttribute(string name, string ns, string value, SyndicationCategory category, string version)
         {
             if (category == null)
             {
@@ -216,7 +216,7 @@ namespace System.ServiceModel.Syndication
             return category.TryParseAttribute(name, ns, value, version);
         }
 
-        internal static protected bool TryParseAttribute(string name, string ns, string value, SyndicationLink link, string version)
+        protected internal static bool TryParseAttribute(string name, string ns, string value, SyndicationLink link, string version)
         {
             if (link == null)
             {
@@ -230,7 +230,7 @@ namespace System.ServiceModel.Syndication
             return link.TryParseAttribute(name, ns, value, version);
         }
 
-        internal static protected bool TryParseAttribute(string name, string ns, string value, SyndicationPerson person, string version)
+        protected internal static bool TryParseAttribute(string name, string ns, string value, SyndicationPerson person, string version)
         {
             if (person == null)
             {
@@ -244,12 +244,12 @@ namespace System.ServiceModel.Syndication
             return person.TryParseAttribute(name, ns, value, version);
         }
 
-        internal static protected bool TryParseContent(XmlReader reader, SyndicationItem item, string contentType, string version, out SyndicationContent content)
+        protected internal static bool TryParseContent(XmlReader reader, SyndicationItem item, string contentType, string version, out SyndicationContent content)
         {
             return item.TryParseContent(reader, contentType, version, out content);
         }
 
-        internal static protected bool TryParseElement(XmlReader reader, SyndicationFeed feed, string version)
+        protected internal static bool TryParseElement(XmlReader reader, SyndicationFeed feed, string version)
         {
             if (feed == null)
             {
@@ -259,7 +259,7 @@ namespace System.ServiceModel.Syndication
             return feed.TryParseElement(reader, version);
         }
 
-        internal static protected bool TryParseElement(XmlReader reader, SyndicationItem item, string version)
+        protected internal static bool TryParseElement(XmlReader reader, SyndicationItem item, string version)
         {
             if (item == null)
             {
@@ -269,7 +269,7 @@ namespace System.ServiceModel.Syndication
             return item.TryParseElement(reader, version);
         }
 
-        internal static protected bool TryParseElement(XmlReader reader, SyndicationCategory category, string version)
+        protected internal static bool TryParseElement(XmlReader reader, SyndicationCategory category, string version)
         {
             if (category == null)
             {
@@ -279,7 +279,7 @@ namespace System.ServiceModel.Syndication
             return category.TryParseElement(reader, version);
         }
 
-        internal static protected bool TryParseElement(XmlReader reader, SyndicationLink link, string version)
+        protected internal static bool TryParseElement(XmlReader reader, SyndicationLink link, string version)
         {
             if (link == null)
             {
@@ -289,7 +289,7 @@ namespace System.ServiceModel.Syndication
             return link.TryParseElement(reader, version);
         }
 
-        internal static protected bool TryParseElement(XmlReader reader, SyndicationPerson person, string version)
+        protected internal static bool TryParseElement(XmlReader reader, SyndicationPerson person, string version)
         {
             if (person == null)
             {
@@ -299,7 +299,7 @@ namespace System.ServiceModel.Syndication
             return person.TryParseElement(reader, version);
         }
 
-        internal static protected void WriteAttributeExtensions(XmlWriter writer, SyndicationFeed feed, string version)
+        protected internal static void WriteAttributeExtensions(XmlWriter writer, SyndicationFeed feed, string version)
         {
             if (feed == null)
             {
@@ -309,7 +309,7 @@ namespace System.ServiceModel.Syndication
             feed.WriteAttributeExtensions(writer, version);
         }
 
-        internal static protected void WriteAttributeExtensions(XmlWriter writer, SyndicationItem item, string version)
+        protected internal static void WriteAttributeExtensions(XmlWriter writer, SyndicationItem item, string version)
         {
             if (item == null)
             {
@@ -319,7 +319,7 @@ namespace System.ServiceModel.Syndication
             item.WriteAttributeExtensions(writer, version);
         }
 
-        internal static protected void WriteAttributeExtensions(XmlWriter writer, SyndicationCategory category, string version)
+        protected internal static void WriteAttributeExtensions(XmlWriter writer, SyndicationCategory category, string version)
         {
             if (category == null)
             {
@@ -329,7 +329,7 @@ namespace System.ServiceModel.Syndication
             category.WriteAttributeExtensions(writer, version);
         }
 
-        internal static protected void WriteAttributeExtensions(XmlWriter writer, SyndicationLink link, string version)
+        protected internal static void WriteAttributeExtensions(XmlWriter writer, SyndicationLink link, string version)
         {
             if (link == null)
             {
@@ -339,7 +339,7 @@ namespace System.ServiceModel.Syndication
             link.WriteAttributeExtensions(writer, version);
         }
 
-        internal static protected void WriteAttributeExtensions(XmlWriter writer, SyndicationPerson person, string version)
+        protected internal static void WriteAttributeExtensions(XmlWriter writer, SyndicationPerson person, string version)
         {
             if (person == null)
             {
@@ -349,7 +349,7 @@ namespace System.ServiceModel.Syndication
             person.WriteAttributeExtensions(writer, version);
         }
 
-        internal static protected void WriteElementExtensions(XmlWriter writer, SyndicationFeed feed, string version)
+        protected internal static void WriteElementExtensions(XmlWriter writer, SyndicationFeed feed, string version)
         {
             if (feed == null)
             {
@@ -359,7 +359,7 @@ namespace System.ServiceModel.Syndication
             feed.WriteElementExtensions(writer, version);
         }
 
-        internal static protected void WriteElementExtensions(XmlWriter writer, SyndicationItem item, string version)
+        protected internal static void WriteElementExtensions(XmlWriter writer, SyndicationItem item, string version)
         {
             if (item == null)
             {
@@ -369,7 +369,7 @@ namespace System.ServiceModel.Syndication
             item.WriteElementExtensions(writer, version);
         }
 
-        internal static protected void WriteElementExtensions(XmlWriter writer, SyndicationCategory category, string version)
+        protected internal static void WriteElementExtensions(XmlWriter writer, SyndicationCategory category, string version)
         {
             if (category == null)
             {
@@ -379,7 +379,7 @@ namespace System.ServiceModel.Syndication
             category.WriteElementExtensions(writer, version);
         }
 
-        internal static protected void WriteElementExtensions(XmlWriter writer, SyndicationLink link, string version)
+        protected internal static void WriteElementExtensions(XmlWriter writer, SyndicationLink link, string version)
         {
             if (link == null)
             {
@@ -389,7 +389,7 @@ namespace System.ServiceModel.Syndication
             link.WriteElementExtensions(writer, version);
         }
 
-        internal static protected void WriteElementExtensions(XmlWriter writer, SyndicationPerson person, string version)
+        protected internal static void WriteElementExtensions(XmlWriter writer, SyndicationPerson person, string version)
         {
             if (person == null)
             {
@@ -399,7 +399,7 @@ namespace System.ServiceModel.Syndication
             person.WriteElementExtensions(writer, version);
         }
 
-        internal protected virtual void SetFeed(SyndicationFeed feed)
+        protected internal virtual void SetFeed(SyndicationFeed feed)
         {
             _feed = feed ?? throw new ArgumentNullException(nameof(feed));
         }
index 776a4ef..4f7fc92 100644 (file)
@@ -34,7 +34,7 @@ namespace System.ServiceModel.Syndication
 
         public abstract void WriteTo(XmlWriter writer);
 
-        internal protected virtual void SetItem(SyndicationItem item)
+        protected internal virtual void SetItem(SyndicationItem item)
         {
             _item = item ?? throw new ArgumentNullException(nameof(item));
         }
index 23c3e11..b7dddc9 100644 (file)
@@ -211,7 +211,7 @@ namespace System.ServiceModel.Syndication.Tests
             {
                 XmlDiffAttribute current1 = elem1.FirstAttribute;
                 XmlDiffAttribute current2 = elem2.FirstAttribute;
-                //                     NodePosition result = 0;
+                //            NodePosition result = 0;
                 int nCompare = 0;
                 while (current1 != null && current2 != null && nCompare == 0)
                 {
@@ -467,7 +467,7 @@ namespace System.ServiceModel.Syndication.Tests
             if (!bEmptyElement)
             {
                 //            bool rtn = reader.Read();
-                //                     rtn = reader.Read();
+                //            rtn = reader.Read();
                 reader.Read(); //move to child
                 ReadChildNodes(elem, reader, pInfo);
             }
index 8d0c2a6..d4b6321 100644 (file)
@@ -132,7 +132,7 @@ namespace System.ServiceProcess
         {
             get
             {
-                if (String.IsNullOrEmpty(_displayName))
+                if (string.IsNullOrEmpty(_displayName))
                     GenerateNames();
                 return _displayName;
             }
@@ -241,7 +241,7 @@ namespace System.ServiceProcess
         {
             get
             {
-                if (String.IsNullOrEmpty(_name))
+                if (string.IsNullOrEmpty(_name))
                     GenerateNames();
                 return _name;
             }
@@ -481,13 +481,13 @@ namespace System.ServiceProcess
         {
             GetDataBaseHandleWithConnectAccess();
 
-            if (String.IsNullOrEmpty(_name))
+            if (string.IsNullOrEmpty(_name))
             {
                 // Figure out the _name based on the information we have. 
                 // We must either have _displayName or the constructor parameter _eitherName.
-                string userGivenName = String.IsNullOrEmpty(_eitherName) ? _displayName : _eitherName;
+                string userGivenName = string.IsNullOrEmpty(_eitherName) ? _displayName : _eitherName;
 
-                if (String.IsNullOrEmpty(userGivenName))
+                if (string.IsNullOrEmpty(userGivenName))
                     throw new InvalidOperationException(SR.Format(SR.ServiceName, userGivenName, ServiceBase.MaxNameLength.ToString()));
 
                 // Try it as a display name
@@ -514,7 +514,7 @@ namespace System.ServiceProcess
                 _displayName = result;
                 _eitherName = null;
             }
-            else if (String.IsNullOrEmpty(_displayName))
+            else if (string.IsNullOrEmpty(_displayName))
             {
                 // We must have _name
                 string result = GetServiceDisplayName(_serviceManagerHandle, _name);
index 65f4e42..464ab45 100644 (file)
@@ -220,7 +220,7 @@ namespace System.Text
                 if (s_InternalSyncObject == null)
                 {
                     object o = new object();
-                    Interlocked.CompareExchange<Object>(ref s_InternalSyncObject, o, null);
+                    Interlocked.CompareExchange<object>(ref s_InternalSyncObject, o, null);
                 }
                 return s_InternalSyncObject;
             }
index 3d4d468..34aaed4 100644 (file)
@@ -73,7 +73,7 @@ namespace System.Text
                 if (s_InternalSyncObject == null)
                 {
                     object o = new object();
-                    Interlocked.CompareExchange<Object>(ref s_InternalSyncObject, o, null);
+                    Interlocked.CompareExchange<object>(ref s_InternalSyncObject, o, null);
                 }
                 return s_InternalSyncObject;
             }
index e303e22..69c3e81 100644 (file)
@@ -73,7 +73,7 @@ namespace System.Text
                 if (s_InternalSyncObject == null)
                 {
                     object o = new object();
-                    Interlocked.CompareExchange<Object>(ref s_InternalSyncObject, o, null);
+                    Interlocked.CompareExchange<object>(ref s_InternalSyncObject, o, null);
                 }
                 return s_InternalSyncObject;
             }
index 59e36c9..b606f41 100644 (file)
@@ -124,7 +124,7 @@ namespace System.Text
                 if (s_InternalSyncObject == null)
                 {
                     object o = new object();
-                    Interlocked.CompareExchange<Object>(ref s_InternalSyncObject, o, null);
+                    Interlocked.CompareExchange<object>(ref s_InternalSyncObject, o, null);
                 }
                 return s_InternalSyncObject;
             }
index dbfe8a2..069dd63 100644 (file)
@@ -25,9 +25,9 @@ namespace System.Text.Encodings.Tests
             byte [] bytes2 = utf8.GetBytes(s2);
             byte [] bytes3 = utf8.GetBytes(s3);
 
-               int bytesUsed;
-               int charsUsed;
-               bool completed;
+            int bytesUsed;
+            int charsUsed;
+            bool completed;
 
             fixed (byte *pBytes1 = bytes1)
             fixed (byte *pBytes2 = bytes2)
@@ -82,9 +82,9 @@ namespace System.Text.Encodings.Tests
         public static unsafe void ConvertNegativeTest()
         {
             Decoder decoder = Encoding.UTF8.GetDecoder();
-               int bytesUsed;
-               int charsUsed;
-               bool completed;
+            int bytesUsed;
+            int charsUsed;
+            bool completed;
 
             byte [] bytes = Encoding.UTF8.GetBytes("\u0D800\uDC00");
 
index ac398a3..dbba9ac 100644 (file)
@@ -26,9 +26,9 @@ namespace System.Text.Encodings.Tests
 
             byte [] bytes = new byte[50];
 
-               int bytesUsed;
-               int charsUsed;
-               bool completed;
+            int bytesUsed;
+            int charsUsed;
+            bool completed;
 
             fixed (char *pChars1 = s1)
             fixed (char *pChars2 = s2)
@@ -78,9 +78,9 @@ namespace System.Text.Encodings.Tests
         public static unsafe void ConvertNegativeTest()
         {
             Encoder encoder = Encoding.UTF8.GetEncoder();
-               int bytesUsed;
-               int charsUsed;
-               bool completed;
+            int bytesUsed;
+            int charsUsed;
+            bool completed;
 
             string chars = "\u0D800\uDC00";
             byte [] bytes = new byte[4];
index 55162cc..dd567a5 100644 (file)
@@ -322,7 +322,7 @@ namespace System.Text.Unicode
         private static int GetScalarValueFromUtf16Slow(char first, char? second, out bool wasSurrogatePair)
         {
 #if DEBUG
-            if (!Char.IsSurrogate(first))
+            if (!char.IsSurrogate(first))
             {
                 Debug.Assert(false, "This case should've been handled by the fast path.");
                 wasSurrogatePair = false;
index ac439f0..25214cc 100644 (file)
@@ -294,7 +294,7 @@ namespace Microsoft.Framework.WebEncoders
         private static string GetKnownGoodPercentEncodedValue(int codePoint)
         {
             // Convert the code point to UTF16, then call Encoding.UTF8.GetBytes, then hex-encode everything
-            return string.Concat(_utf8EncodingThrowOnInvalidBytes.GetBytes(Char.ConvertFromUtf32(codePoint)).Select(b => string.Format(CultureInfo.InvariantCulture, "%{0:X2}", b)));
+            return string.Concat(_utf8EncodingThrowOnInvalidBytes.GetBytes(char.ConvertFromUtf32(codePoint)).Select(b => string.Format(CultureInfo.InvariantCulture, "%{0:X2}", b)));
         }
 
         private static bool IsSurrogateCodePoint(int codePoint)
index c4146f8..420a9f9 100644 (file)
@@ -20,7 +20,7 @@ namespace System.Text.Json
         /// <typeparamref name="TValue"/> is not compatible with the JSON,
         /// or when there is remaining data in the Stream.
         /// </exception>
-        /// <remarks>Using a <see cref="System.String"/> is not as efficient as using the
+        /// <remarks>Using a <see cref="string"/> is not as efficient as using the
         /// UTF-8 methods since the implementation natively uses UTF-8.
         /// </remarks>
         public static TValue Deserialize<TValue>(string json, JsonSerializerOptions options = null)
@@ -46,7 +46,7 @@ namespace System.Text.Json
         /// the <paramref name="returnType"/> is not compatible with the JSON,
         /// or when there is remaining data in the Stream.
         /// </exception>
-        /// <remarks>Using a <see cref="System.String"/> is not as efficient as using the
+        /// <remarks>Using a <see cref="string"/> is not as efficient as using the
         /// UTF-8 methods since the implementation natively uses UTF-8.
         /// </remarks>
         public static object Deserialize(string json, Type returnType, JsonSerializerOptions options = null)
index d9909d1..60cc0e4 100644 (file)
@@ -7,7 +7,7 @@ namespace System.Text.Json
     public static partial class JsonSerializer
     {
         /// <summary>
-        /// Convert the provided value into a <see cref="System.Byte"/> array.
+        /// Convert the provided value into a <see cref="byte"/> array.
         /// </summary>
         /// <returns>A UTF-8 representation of the value.</returns>
         /// <param name="value">The value to convert.</param>
@@ -18,7 +18,7 @@ namespace System.Text.Json
         }
 
         /// <summary>
-        /// Convert the provided value into a <see cref="System.Byte"/> array.
+        /// Convert the provided value into a <see cref="byte"/> array.
         /// </summary>
         /// <returns>A UTF-8 representation of the value.</returns>
         /// <param name="value">The value to convert.</param>
index 2e5bb02..013ed66 100644 (file)
@@ -7,12 +7,12 @@ namespace System.Text.Json
     public static partial class JsonSerializer
     {
         /// <summary>
-        /// Convert the provided value into a <see cref="System.String"/>.
+        /// Convert the provided value into a <see cref="string"/>.
         /// </summary>
-        /// <returns>A <see cref="System.String"/> representation of the value.</returns>
+        /// <returns>A <see cref="string"/> representation of the value.</returns>
         /// <param name="value">The value to convert.</param>
         /// <param name="options">Options to control the conversion behavior.</param>
-        /// <remarks>Using a <see cref="System.String"/> is not as efficient as using UTF-8
+        /// <remarks>Using a <see cref="string"/> is not as efficient as using UTF-8
         /// encoding since the implementation internally uses UTF-8. See also <see cref="SerializeToUtf8Bytes"/>
         /// and <see cref="SerializeAsync"/>.
         /// </remarks>
@@ -22,13 +22,13 @@ namespace System.Text.Json
         }
 
         /// <summary>
-        /// Convert the provided value into a <see cref="System.String"/>.
+        /// Convert the provided value into a <see cref="string"/>.
         /// </summary>
-        /// <returns>A <see cref="System.String"/> representation of the value.</returns>
+        /// <returns>A <see cref="string"/> representation of the value.</returns>
         /// <param name="value">The value to convert.</param>
         /// <param name="type">The type of the <paramref name="value"/> to convert.</param>
         /// <param name="options">Options to control the conversion behavior.</param>
-        /// <remarks>Using a <see cref="System.String"/> is not as efficient as using UTF-8
+        /// <remarks>Using a <see cref="string"/> is not as efficient as using UTF-8
         /// encoding since the implementation internally uses UTF-8. See also <see cref="SerializeToUtf8Bytes"/>
         /// and <see cref="SerializeAsync"/>.
         /// </remarks>
index b533eeb..d22e2d0 100644 (file)
@@ -26,7 +26,7 @@ namespace System.Text.Json
         /// <param name="bytesConsumed">On exit, contains the number of bytes that were consumed from the <paramref name="utf16Source"/>.</param>
         /// <param name="bytesWritten">On exit, contains the number of bytes written to <paramref name="utf8Destination"/></param>
         /// <returns>A <see cref="OperationStatus"/> value representing the state of the conversion.</returns>
-        public unsafe static OperationStatus ToUtf8(ReadOnlySpan<byte> utf16Source, Span<byte> utf8Destination, out int bytesConsumed, out int bytesWritten)
+        public static unsafe OperationStatus ToUtf8(ReadOnlySpan<byte> utf16Source, Span<byte> utf8Destination, out int bytesConsumed, out int bytesWritten)
         {
             //
             //
@@ -319,14 +319,14 @@ namespace System.Text.Json
         }
 
         [MethodImpl(MethodImplOptions.AggressiveInlining)]
-        private unsafe static int PtrDiff(char* a, char* b)
+        private static unsafe int PtrDiff(char* a, char* b)
         {
             return (int)(((uint)((byte*)a - (byte*)b)) >> 1);
         }
 
         // byte* flavor just for parity
         [MethodImpl(MethodImplOptions.AggressiveInlining)]
-        private unsafe static int PtrDiff(byte* a, byte* b)
+        private static unsafe int PtrDiff(byte* a, byte* b)
         {
             return (int)(a - b);
         }
index 0d94527..2d4a403 100644 (file)
@@ -188,7 +188,7 @@ namespace System.Text.RegularExpressions
                         prevat = match.Index + match.Length;
                         string result = evaluator(match);
                         if (!string.IsNullOrEmpty(result))
-                               vsb.Append(result);
+                            vsb.Append(result);
 
                         if (--count == 0)
                             break;
index 17c63ca..1bfdaea 100644 (file)
@@ -30,14 +30,14 @@ namespace System.Threading
         public int OffsetHigh { get { throw null; } set { } }
         public int OffsetLow { get { throw null; } set { } }
         [System.CLSCompliantAttribute(false)]
-        public unsafe static void Free(System.Threading.NativeOverlapped* nativeOverlappedPtr) { }
+        public static unsafe void Free(System.Threading.NativeOverlapped* nativeOverlappedPtr) { }
         [System.CLSCompliantAttribute(false)]
         [System.ObsoleteAttribute("This method is not safe.  Use Pack (iocb, userData) instead.  https://go.microsoft.com/fwlink/?linkid=14202")]
         public unsafe System.Threading.NativeOverlapped* Pack(System.Threading.IOCompletionCallback? iocb) { throw null; }
         [System.CLSCompliantAttribute(false)]
         public unsafe System.Threading.NativeOverlapped* Pack(System.Threading.IOCompletionCallback? iocb, object? userData) { throw null; }
         [System.CLSCompliantAttribute(false)]
-        public unsafe static System.Threading.Overlapped Unpack(System.Threading.NativeOverlapped* nativeOverlappedPtr) { throw null; }
+        public static unsafe System.Threading.Overlapped Unpack(System.Threading.NativeOverlapped* nativeOverlappedPtr) { throw null; }
         [System.CLSCompliantAttribute(false)]
         [System.ObsoleteAttribute("This method is not safe.  Use UnsafePack (iocb, userData) instead.  https://go.microsoft.com/fwlink/?linkid=14202")]
         public unsafe System.Threading.NativeOverlapped* UnsafePack(System.Threading.IOCompletionCallback? iocb) { throw null; }
@@ -64,6 +64,6 @@ namespace System.Threading
         [System.CLSCompliantAttribute(false)]
         public unsafe void FreeNativeOverlapped(System.Threading.NativeOverlapped* overlapped) { }
         [System.CLSCompliantAttribute(false)]
-        public unsafe static object? GetNativeOverlappedState(System.Threading.NativeOverlapped* overlapped) { throw null; }
+        public static unsafe object? GetNativeOverlappedState(System.Threading.NativeOverlapped* overlapped) { throw null; }
     }
 }
index 40b3378..a51bc1e 100644 (file)
@@ -7,23 +7,23 @@ using System.Runtime.InteropServices;
 
 public class AsyncResult : IAsyncResult
 {
-       public object AsyncState
-       {
-               get { throw new NotImplementedException(); }
-       }
+    public object AsyncState
+    {
+        get { throw new NotImplementedException(); }
+    }
 
-       public System.Threading.WaitHandle AsyncWaitHandle
-       {
-               get { throw new NotImplementedException(); }
-       }
+    public System.Threading.WaitHandle AsyncWaitHandle
+    {
+        get { throw new NotImplementedException(); }
+    }
 
-       public bool CompletedSynchronously
-       {
-               get { throw new NotImplementedException(); }
-       }
+    public bool CompletedSynchronously
+    {
+        get { throw new NotImplementedException(); }
+    }
 
-       public bool IsCompleted
-       {
-               get { throw new NotImplementedException(); }
-       }
+    public bool IsCompleted
+    {
+        get { throw new NotImplementedException(); }
+    }
 }
index f3b16ae..a06150b 100644 (file)
@@ -16,7 +16,7 @@ internal static class DllImport
        FileAttributes dwFlagsAndAttributes, IntPtr hTemplateFile);
 #else
     [DllImport("kernel32.dll", SetLastError = true, CharSet = CharSet.Unicode, BestFitMapping = false)]
-    internal static unsafe extern Win32Handle CreateFile2(string lpFileName,
+    internal static extern unsafe Win32Handle CreateFile2(string lpFileName,
         FileAccess dwDesiredAccess, FileShare dwShareMode,
         CreationDisposition dwCreationDisposition, CREATEFILE2_EXTENDED_PARAMETERS* pCreateExParams);
 
index 4a8f40e..96bd7a9 100644 (file)
@@ -299,7 +299,7 @@ namespace System.Threading.Tasks.Dataflow
 
             // Fast path check for cancellation
             if (cancellationToken.IsCancellationRequested)
-                return Common.CreateTaskFromCancellation<Boolean>(cancellationToken);
+                return Common.CreateTaskFromCancellation<bool>(cancellationToken);
 
             SendAsyncSource<TInput> source;
 
@@ -338,7 +338,7 @@ namespace System.Threading.Tasks.Dataflow
             {
                 // If the target throws from OfferMessage, return a faulted task
                 Common.StoreDataflowMessageValueIntoExceptionData(exc, item);
-                return Common.CreateTaskFromException<Boolean>(exc);
+                return Common.CreateTaskFromException<bool>(exc);
             }
 
             Debug.Assert(source != null, "The SendAsyncSource instance must have been constructed.");
@@ -828,7 +828,7 @@ namespace System.Threading.Tasks.Dataflow
         /// </returns>
         /// <exception cref="System.ArgumentNullException">The <paramref name="source"/> is null (Nothing in Visual Basic).</exception>
         /// <exception cref="System.ArgumentOutOfRangeException">
-        /// timeout is a negative number other than -1 milliseconds, which represents an infinite time-out -or- timeout is greater than <see cref="System.Int32.MaxValue"/>.
+        /// timeout is a negative number other than -1 milliseconds, which represents an infinite time-out -or- timeout is greater than <see cref="int.MaxValue"/>.
         /// </exception>
         public static Task<TOutput> ReceiveAsync<TOutput>(
             this ISourceBlock<TOutput> source, TimeSpan timeout)
@@ -849,7 +849,7 @@ namespace System.Threading.Tasks.Dataflow
         /// </returns>
         /// <exception cref="System.ArgumentNullException">The <paramref name="source"/> is null (Nothing in Visual Basic).</exception>
         /// <exception cref="System.ArgumentOutOfRangeException">
-        /// timeout is a negative number other than -1 milliseconds, which represents an infinite time-out -or- timeout is greater than <see cref="System.Int32.MaxValue"/>.
+        /// timeout is a negative number other than -1 milliseconds, which represents an infinite time-out -or- timeout is greater than <see cref="int.MaxValue"/>.
         /// </exception>
         public static Task<TOutput> ReceiveAsync<TOutput>(
             this ISourceBlock<TOutput> source, TimeSpan timeout, CancellationToken cancellationToken)
@@ -903,7 +903,7 @@ namespace System.Threading.Tasks.Dataflow
         /// <param name="timeout">A <see cref="System.TimeSpan"/> that represents the number of milliseconds to wait, or a TimeSpan that represents -1 milliseconds to wait indefinitely.</param>
         /// <returns>The received item.</returns>
         /// <exception cref="System.ArgumentOutOfRangeException">
-        /// timeout is a negative number other than -1 milliseconds, which represents an infinite time-out -or- timeout is greater than <see cref="System.Int32.MaxValue"/>.
+        /// timeout is a negative number other than -1 milliseconds, which represents an infinite time-out -or- timeout is greater than <see cref="int.MaxValue"/>.
         /// </exception>
         /// <exception cref="System.ArgumentNullException">The <paramref name="source"/> is null (Nothing in Visual Basic).</exception>
         /// <exception cref="System.InvalidOperationException">No item could be received from the source.</exception>
@@ -926,7 +926,7 @@ namespace System.Threading.Tasks.Dataflow
         /// <returns>The received item.</returns>
         /// <exception cref="System.ArgumentNullException">The <paramref name="source"/> is null (Nothing in Visual Basic).</exception>
         /// <exception cref="System.ArgumentOutOfRangeException">
-        /// timeout is a negative number other than -1 milliseconds, which represents an infinite time-out -or- timeout is greater than <see cref="System.Int32.MaxValue"/>.
+        /// timeout is a negative number other than -1 milliseconds, which represents an infinite time-out -or- timeout is greater than <see cref="int.MaxValue"/>.
         /// </exception>
         /// <exception cref="System.InvalidOperationException">No item could be received from the source.</exception>
         /// <exception cref="System.TimeoutException">The specified timeout expired before an item was received from the source.</exception>
@@ -1938,7 +1938,7 @@ namespace System.Threading.Tasks.Dataflow
 
             // Early cancellation check and bail out
             if (dataflowBlockOptions.CancellationToken.IsCancellationRequested)
-                return Common.CreateTaskFromCancellation<Int32>(dataflowBlockOptions.CancellationToken);
+                return Common.CreateTaskFromCancellation<int>(dataflowBlockOptions.CancellationToken);
 
             // Fast path: if any of the sources already has data available that can be received immediately.
             Task<int> resultTask;
index 685bb24..3d57754 100644 (file)
@@ -341,7 +341,7 @@ namespace System.Threading.Tasks.Dataflow.Internal
             // By using these same tasks, we're a bit more robust against disposals,
             // in that such a disposed task's ((IAsyncResult)task).AsyncWaitHandle
             // is still valid.
-            var atmb = System.Runtime.CompilerServices.AsyncTaskMethodBuilder<Boolean>.Create();
+            var atmb = System.Runtime.CompilerServices.AsyncTaskMethodBuilder<bool>.Create();
             atmb.SetResult(value);
             return atmb.Task; // must be accessed after SetResult to get the cached task
         }
index 3ea50b2..4878c55 100644 (file)
@@ -50,9 +50,9 @@ namespace System.Threading.Tasks.Test
         // Hold list of verification
         private Queue<Action<ParallelLoopResult?>> _verifications = new Queue<Action<ParallelLoopResult?>>();
 
-        private volatile bool _isStopped = false;                      // Flag to indicate that we called Stop() on the Parallel state
-        private long? _lowestBreakIter = null;                             // LowestBreakIteration value holder, null indicates that Break hasn't been called
-        private volatile bool _isExceptional = false;          // Flag to indicate exception thrown in the test
+        private volatile bool _isStopped = false;     // Flag to indicate that we called Stop() on the Parallel state
+        private long? _lowestBreakIter = null;        // LowestBreakIteration value holder, null indicates that Break hasn't been called
+        private volatile bool _isExceptional = false; // Flag to indicate exception thrown in the test
 
         private int _iterCount = 0;  // test own counter for certain scenario, so the test can change behaviour after certain number of loop iteration
 
index d408916..2fe9d53 100644 (file)
@@ -65,8 +65,8 @@ namespace System.Threading.Tasks.Tests
 
         //public int SchedulerID
         //{
-        //     get;
-        //     set;
+        //    get;
+        //    set;
         //}
 
         protected override IEnumerable<Task> GetScheduledTasks() { return null; }
index ca93fb8..2912f7e 100644 (file)
@@ -38,7 +38,7 @@ namespace System.Threading
         public static bool SetMaxThreads(int workerThreads, int completionPortThreads) { throw null; }
         public static bool SetMinThreads(int workerThreads, int completionPortThreads) { throw null; }
         [System.CLSCompliantAttribute(false)]
-        public unsafe static bool UnsafeQueueNativeOverlapped(System.Threading.NativeOverlapped* overlapped) { throw null; }
+        public static unsafe bool UnsafeQueueNativeOverlapped(System.Threading.NativeOverlapped* overlapped) { throw null; }
         public static bool UnsafeQueueUserWorkItem(System.Threading.IThreadPoolWorkItem callBack, bool preferLocal) { throw null; }
         public static bool UnsafeQueueUserWorkItem(System.Threading.WaitCallback callBack, object? state) { throw null; }
         public static bool UnsafeQueueUserWorkItem<TState>(System.Action<TState> callBack, TState state, bool preferLocal) { throw null; }
index 1c9d869..95544c1 100644 (file)
@@ -193,7 +193,7 @@ namespace System.Threading
         /// </summary>
         /// <param name="participantCount">The number of participating threads.</param>
         /// <exception cref="ArgumentOutOfRangeException"> <paramref name="participantCount"/> is less than 0
-        /// or greater than <see cref="System.Int16.MaxValue"/>.</exception>
+        /// or greater than <see cref="short.MaxValue"/>.</exception>
         public Barrier(int participantCount)
             : this(participantCount, null)
         {
@@ -206,7 +206,7 @@ namespace System.Threading
         /// <param name="postPhaseAction">The <see cref="System.Action{Barrier}"/> to be executed after each
         /// phase.</param>
         /// <exception cref="System.ArgumentOutOfRangeException"> <paramref name="participantCount"/> is less than 0
-        /// or greater than <see cref="System.Int32.MaxValue"/>.</exception>
+        /// or greater than <see cref="int.MaxValue"/>.</exception>
         /// <remarks>
         /// The <paramref name="postPhaseAction"/> delegate will be executed after
         /// all participants have arrived at the barrier in one phase.  The participants
@@ -277,7 +277,7 @@ namespace System.Threading
         /// participate.</returns>
         /// <exception cref="System.InvalidOperationException">
         /// Adding a participant would cause the barrier's participant count to 
-        /// exceed <see cref="System.Int16.MaxValue"/>.
+        /// exceed <see cref="short.MaxValue"/>.
         /// </exception>
         /// <exception cref="System.InvalidOperationException">
         /// The method was invoked from within a post-phase action.
@@ -306,7 +306,7 @@ namespace System.Threading
         /// <exception cref="System.ArgumentOutOfRangeException"><paramref name="participantCount"/> is less than
         /// 0.</exception>
         /// <exception cref="System.ArgumentOutOfRangeException">Adding <paramref name="participantCount"/> participants would cause the
-        /// barrier's participant count to exceed <see cref="System.Int16.MaxValue"/>.</exception>
+        /// barrier's participant count to exceed <see cref="short.MaxValue"/>.</exception>
         /// <exception cref="System.InvalidOperationException">
         /// The method was invoked from within a post-phase action.
         /// </exception>
@@ -526,7 +526,7 @@ namespace System.Threading
         /// <returns>true if all other participants reached the barrier; otherwise, false.</returns>
         /// <exception cref="System.ArgumentOutOfRangeException"><paramref name="timeout"/>is a negative number
         /// other than -1 milliseconds, which represents an infinite time-out, or it is greater than
-        /// <see cref="System.Int32.MaxValue"/>.</exception>
+        /// <see cref="int.MaxValue"/>.</exception>
         /// <exception cref="System.InvalidOperationException">
         /// The method was invoked from within a post-phase action, the barrier currently has 0 participants,
         /// or the barrier is being used by more threads than are registered as participants.
index 4ecf05a..676aa96 100644 (file)
@@ -262,7 +262,7 @@ namespace System.Threading
         /// <exception cref="System.InvalidOperationException">The current instance is already
         /// set.</exception>
         /// <exception cref="System.InvalidOperationException"><see cref="CurrentCount"/> is equal to <see
-        /// cref="System.Int32.MaxValue"/>.</exception>
+        /// cref="int.MaxValue"/>.</exception>
         /// <exception cref="System.ObjectDisposedException">
         /// The current instance has already been disposed.
         /// </exception>
@@ -277,7 +277,7 @@ namespace System.Threading
         /// <returns>true if the increment succeeded; otherwise, false. If <see cref="CurrentCount"/> is
         /// already at zero. this will return false.</returns>
         /// <exception cref="System.InvalidOperationException"><see cref="CurrentCount"/> is equal to <see
-        /// cref="System.Int32.MaxValue"/>.</exception>
+        /// cref="int.MaxValue"/>.</exception>
         /// <exception cref="System.ObjectDisposedException">The current instance has already been
         /// disposed.</exception>
         public bool TryAddCount()
@@ -295,7 +295,7 @@ namespace System.Threading
         /// <exception cref="System.InvalidOperationException">The current instance is already
         /// set.</exception>
         /// <exception cref="System.InvalidOperationException"><see cref="CurrentCount"/> is equal to <see
-        /// cref="System.Int32.MaxValue"/>.</exception>
+        /// cref="int.MaxValue"/>.</exception>
         /// <exception cref="System.ObjectDisposedException">The current instance has already been
         /// disposed.</exception>
         public void AddCount(int signalCount)
@@ -318,7 +318,7 @@ namespace System.Threading
         /// <exception cref="System.InvalidOperationException">The current instance is already
         /// set.</exception>
         /// <exception cref="System.InvalidOperationException"><see cref="CurrentCount"/> is equal to <see
-        /// cref="System.Int32.MaxValue"/>.</exception>
+        /// cref="int.MaxValue"/>.</exception>
         /// <exception cref="System.ObjectDisposedException">The current instance has already been
         /// disposed.</exception>
         public bool TryAddCount(int signalCount)
@@ -454,7 +454,7 @@ namespace System.Threading
         /// false.</returns>
         /// <exception cref="System.ArgumentOutOfRangeException"><paramref name="timeout"/> is a negative
         /// number other than -1 milliseconds, which represents an infinite time-out -or- timeout is greater
-        /// than <see cref="System.Int32.MaxValue"/>.</exception>
+        /// than <see cref="int.MaxValue"/>.</exception>
         /// <exception cref="System.ObjectDisposedException">The current instance has already been
         /// disposed.</exception>
         public bool Wait(TimeSpan timeout)
@@ -482,7 +482,7 @@ namespace System.Threading
         /// false.</returns>
         /// <exception cref="System.ArgumentOutOfRangeException"><paramref name="timeout"/> is a negative
         /// number other than -1 milliseconds, which represents an infinite time-out -or- timeout is greater
-        /// than <see cref="System.Int32.MaxValue"/>.</exception>
+        /// than <see cref="int.MaxValue"/>.</exception>
         /// <exception cref="System.ObjectDisposedException">The current instance has already been
         /// disposed.</exception>
         /// <exception cref="System.OperationCanceledException"><paramref name="cancellationToken"/> has
index dec45d6..978b762 100644 (file)
@@ -63,7 +63,7 @@ namespace System.Transactions.Tests
                 irm.Value = 2;
 
                 /* Not completing this..
-                               scope.Complete ();*/
+                scope.Complete ();*/
             }
 
             irm.Check(0, 0, 0, 1, 0, 0, 0, "irm");
@@ -151,8 +151,8 @@ namespace System.Transactions.Tests
         }
 
         /* We support only 1 durable with 2PC
-                * On .net, this becomes a distributed transaction
-                */
+         * On .net, this becomes a distributed transaction
+         */
         [ActiveIssue(13532)] //Distributed transactions are not supported.
         [Fact]
         public void Vol0_Dur1_2PC()
@@ -160,8 +160,8 @@ namespace System.Transactions.Tests
             IntResourceManager irm = new IntResourceManager(1);
 
             /* Durable resource enlisted with a IEnlistedNotification
-                        * object
-                        */
+             * object
+             */
             irm.Type = ResourceManagerType.Durable;
 
             using (TransactionScope scope = new TransactionScope())
@@ -178,8 +178,8 @@ namespace System.Transactions.Tests
             IntResourceManager irm = new IntResourceManager(1);
 
             /* Durable resource enlisted with a IEnlistedNotification
-                        * object
-                        */
+             * object
+             */
             irm.Type = ResourceManagerType.Durable;
             irm.FailSPC = true;
             irm.UseSingle = true;
@@ -229,8 +229,8 @@ namespace System.Transactions.Tests
         }
 
         /* >1vol + 1 durable
-                * Durable fails SPC
-                */
+         * Durable fails SPC
+         */
         [Fact]
         public void Vol2_Dur1_Fail1()
         {
@@ -247,7 +247,7 @@ namespace System.Transactions.Tests
                 irm[i].UseSingle = true;
 
             /* Durable RM irm[0] does Abort on SPC, so
-                        * all volatile RMs get Rollback */
+             * all volatile RMs get Rollback */
             Assert.Throws<TransactionAbortedException>(() =>
             {
                 using (TransactionScope scope = new TransactionScope())
@@ -267,8 +267,8 @@ namespace System.Transactions.Tests
         }
 
         /* >1vol + 1 durable
-                * Volatile fails Prepare
-                */
+         * Volatile fails Prepare
+         */
         [Fact]
         public void Vol2_Dur1_Fail3()
         {
@@ -285,7 +285,7 @@ namespace System.Transactions.Tests
                 irm[i].UseSingle = true;
 
             /* Durable RM irm[2] does on SPC, so
-                        * all volatile RMs get Rollback */
+             * all volatile RMs get Rollback */
             Assert.Throws<TransactionAbortedException>(() =>
             {
                 using (TransactionScope scope = new TransactionScope())
@@ -324,7 +324,7 @@ namespace System.Transactions.Tests
                 irm[i].UseSingle = true;
 
             /* Durable RM irm[2] does on SPC, so
-                        * all volatile RMs get Rollback */
+             * all volatile RMs get Rollback */
             TransactionAbortedException e = Assert.Throws<TransactionAbortedException>(() =>
             {
                 using (TransactionScope scope = new TransactionScope())
@@ -358,7 +358,7 @@ namespace System.Transactions.Tests
                 irm[i].UseSingle = true;
 
             /* Durable RM irm[2] does on SPC, so
-                        * all volatile RMs get Rollback */
+             * all volatile RMs get Rollback */
 
             using (TransactionScope scope = new TransactionScope())
             {
@@ -455,9 +455,9 @@ namespace System.Transactions.Tests
 
         #region Others
         /* >1vol  
-                * > 1 durable, On .net this becomes a distributed transaction
-                * We don't support this in mono yet. 
-                */
+         * > 1 durable, On .net this becomes a distributed transaction
+         * We don't support this in mono yet. 
+         */
         [ActiveIssue(13532)] //Distributed transactions are not supported.
         [Fact]
         public void Vol0_Dur2()
index a8dc466..90d22fb 100644 (file)
@@ -219,7 +219,7 @@ namespace System.Transactions.Tests
 
                 Assert.Equal(TransactionStatus.Active, Transaction.Current.TransactionInformation.Status);
                 /* Not completing outer scope
-                               scope.Complete (); */
+                scope.Complete (); */
             }
 
             Assert.Null(Transaction.Current);
@@ -275,7 +275,7 @@ namespace System.Transactions.Tests
                 {
                     irm2.Value = 20;
                     /* Not completing 
-                                        scope2.Complete();*/
+                     scope2.Complete();*/
                 }
 
                 /* irm2, rolled back*/
@@ -432,15 +432,15 @@ namespace System.Transactions.Tests
                 {
                     irm.Value = 4;
                     /* Not completing this, so the transaction will
-                                        * get aborted 
-                                       scope2.Complete (); */
+                     * get aborted 
+                    scope2.Complete (); */
                 }
 
                 using (TransactionScope scope3 = new TransactionScope(TransactionScopeOption.RequiresNew))
                 {
                     /* Using RequiresNew here, so outer transaction
-                                        * being aborted doesn't matter
-                                        */
+                     * being aborted doesn't matter
+                     */
                     scope3.Complete();
                 }
             }
@@ -491,8 +491,8 @@ namespace System.Transactions.Tests
                     irm3.Value = 24;
 
                     /* Make second RM fail to prepare, this should throw
-                                        * TransactionAbortedException when the scope ends 
-                                        */
+                     * TransactionAbortedException when the scope ends 
+                     */
                     irm2.FailPrepare = true;
                     scope.Complete();
                 }
@@ -524,9 +524,9 @@ namespace System.Transactions.Tests
                     irm3.Value = 24;
 
                     /* irm2 won't call Prepared or ForceRollback in
-                                        * its Prepare (), so TransactionManager will timeout
-                                        * waiting for it 
-                                        */
+                     * its Prepare (), so TransactionManager will timeout
+                     * waiting for it 
+                     */
                     irm2.IgnorePrepare = true;
                     scope.Complete();
                 }
@@ -692,8 +692,8 @@ namespace System.Transactions.Tests
             Transaction oldTransaction = Transaction.Current;
 
             /* Not setting ambient transaction 
-                        Transaction.Current = ct; 
-                        */
+             Transaction.Current = ct; 
+             */
 
             IntResourceManager irm = new IntResourceManager(1);
 
@@ -724,8 +724,8 @@ namespace System.Transactions.Tests
             Transaction oldTransaction = Transaction.Current;
 
             /* Not setting ambient transaction 
-                        Transaction.Current = ct; 
-                        */
+             Transaction.Current = ct; 
+             */
 
             IntResourceManager irm = new IntResourceManager(1);
 
@@ -736,7 +736,7 @@ namespace System.Transactions.Tests
                 irm.Value = 2;
 
                 /* Not completing this scope
-                               scope.Complete (); */
+                scope.Complete (); */
             }
 
             Assert.Equal(oldTransaction, Transaction.Current);
index 2f168bf..34c2ca9 100644 (file)
@@ -32,7 +32,7 @@ namespace System.Tests
         }
 
         [Fact]
-        public unsafe static void MemoryOfByte_WithUtf8String_Pin()
+        public static unsafe void MemoryOfByte_WithUtf8String_Pin()
         {
             Utf8String theString = u8("Hello");
             ReadOnlyMemory<byte> rom = theString.AsMemoryBytes();
@@ -56,7 +56,7 @@ namespace System.Tests
         }
 
         [Fact]
-        public unsafe static void MemoryOfChar8_WithUtf8String_Pin()
+        public static unsafe void MemoryOfChar8_WithUtf8String_Pin()
         {
             Utf8String theString = u8("Hello");
             ReadOnlyMemory<Char8> rom = theString.AsMemory();
@@ -80,7 +80,7 @@ namespace System.Tests
         }
 
         [Fact]
-        public unsafe static void ReadOnlyMemoryOfByte_WithUtf8String_Pin()
+        public static unsafe void ReadOnlyMemoryOfByte_WithUtf8String_Pin()
         {
             Utf8String theString = u8("Hello");
             ReadOnlyMemory<byte> rom = theString.AsMemoryBytes();
@@ -103,7 +103,7 @@ namespace System.Tests
         }
 
         [Fact]
-        public unsafe static void ReadOnlyMemoryOfChar8_WithUtf8String_Pin()
+        public static unsafe void ReadOnlyMemoryOfChar8_WithUtf8String_Pin()
         {
             Utf8String theString = u8("Hello");
             ReadOnlyMemory<Char8> rom = theString.AsMemory();
index 1df50cb..1ea63d1 100644 (file)
@@ -26,7 +26,7 @@ namespace System.Tests
         /// <summary>
         /// Mimics returning a literal <see cref="Utf8String"/> instance.
         /// </summary>
-        public unsafe static Utf8String u8(string str)
+        public static unsafe Utf8String u8(string str)
         {
             if (str is null)
             {
index 56b444b..8950e65 100644 (file)
@@ -5,7 +5,7 @@
 // System.Web.HttpUtilityTest.cs - Unit tests for System.Web.HttpUtility
 //
 // Author:
-//     Sebastien Pouliot  <sebastien@ximian.com>
+//  Sebastien Pouliot  <sebastien@ximian.com>
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //