Contribute to StyleCop SA1002 (semicolon spacing)
authorStephen Toub <stoub@microsoft.com>
Thu, 22 Aug 2019 17:10:47 +0000 (13:10 -0400)
committerStephen Toub <stoub@microsoft.com>
Sat, 24 Aug 2019 11:47:35 +0000 (07:47 -0400)
However, I'm not enabling the rule permanently, as it disagrees with VS IDE0055 about the spacing around semicolons at the end of empty while and for loops.

Because this also impacts `for (;;)` loops, I also searched and replaced those with `while (true)`, to standardize on that across the codebase.

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

159 files changed:
src/libraries/Common/src/Interop/OSX/System.Security.Cryptography.Native.Apple/Interop.Ssl.cs
src/libraries/Common/src/Interop/Unix/System.Net.Security.Native/Interop.GssApiException.cs
src/libraries/Common/src/Interop/Windows/WinSock/WSABuffer.cs
src/libraries/Common/src/System/Globalization/FormatProvider.Number.cs
src/libraries/Microsoft.CSharp/src/Microsoft/CSharp/RuntimeBinder/RuntimeBinder.cs
src/libraries/Microsoft.CSharp/src/Microsoft/CSharp/RuntimeBinder/Semantics/Conversion.cs
src/libraries/Microsoft.CSharp/src/Microsoft/CSharp/RuntimeBinder/Semantics/ExpressionBinder.cs
src/libraries/Microsoft.CSharp/src/Microsoft/CSharp/RuntimeBinder/Semantics/GroupToArgsBinder.cs
src/libraries/Microsoft.CSharp/src/Microsoft/CSharp/RuntimeBinder/Semantics/MemberLookup.cs
src/libraries/Microsoft.CSharp/src/Microsoft/CSharp/RuntimeBinder/Semantics/MethodIterator.cs
src/libraries/Microsoft.CSharp/src/Microsoft/CSharp/RuntimeBinder/Semantics/Types/TypeManager.cs
src/libraries/System.Collections.Concurrent/src/System/Collections/Concurrent/PartitionerStatic.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Hosting/CompositionContainer.cs
src/libraries/System.ComponentModel.Composition/src/System/ComponentModel/Composition/Hosting/CompositionServices.cs
src/libraries/System.ComponentModel.TypeConverter/src/System/ComponentModel/Design/StandardCommands.cs
src/libraries/System.Configuration.ConfigurationManager/src/System/Configuration/BaseConfigurationRecord.cs
src/libraries/System.Configuration.ConfigurationManager/src/System/Configuration/MgmtConfigurationRecord.cs
src/libraries/System.Configuration.ConfigurationManager/src/System/Configuration/SafeBitVector32.cs
src/libraries/System.Data.Common/src/System/Data/Common/DataStorage.cs
src/libraries/System.Data.Common/src/System/Data/Common/SQLTypes/SQLByteStorage.cs
src/libraries/System.Data.Common/src/System/Data/Common/SQLTypes/SQLBytesStorage.cs
src/libraries/System.Data.Common/src/System/Data/Common/SQLTypes/SQLCharsStorage.cs
src/libraries/System.Data.Common/src/System/Data/Common/SQLTypes/SQLDateTimeStorage.cs
src/libraries/System.Data.Common/src/System/Data/Common/SQLTypes/SQLDoubleStorage.cs
src/libraries/System.Data.Common/src/System/Data/Common/SQLTypes/SQLInt16Storage.cs
src/libraries/System.Data.Common/src/System/Data/Common/SQLTypes/SQLInt64Storage.cs
src/libraries/System.Data.Common/src/System/Data/DataColumn.cs
src/libraries/System.Data.Common/src/System/Data/DataColumnPropertyDescriptor.cs
src/libraries/System.Data.Common/src/System/Data/DataRow.cs
src/libraries/System.Data.Common/src/System/Data/DataSet.cs
src/libraries/System.Data.Common/src/System/Data/DataTable.cs
src/libraries/System.Data.Common/src/System/Data/Filter/Operators.cs
src/libraries/System.Data.Common/src/System/Data/ForeignKeyConstraint.cs
src/libraries/System.Data.Common/src/System/Data/Merger.cs
src/libraries/System.Data.Common/src/System/Data/SQLTypes/SQLDecimal.cs
src/libraries/System.Data.Common/src/System/Data/Select.cs
src/libraries/System.Data.Common/src/System/Data/SimpleType.cs
src/libraries/System.Data.Common/src/System/Data/UniqueConstraint.cs
src/libraries/System.Data.Common/src/System/Data/XMLDiffLoader.cs
src/libraries/System.Data.Common/src/System/Data/XMLSchema.cs
src/libraries/System.Data.Common/src/System/Data/xmlsaver.cs
src/libraries/System.Data.Odbc/src/Common/System/Data/Common/NameValuePermission.cs
src/libraries/System.Data.Odbc/src/Common/System/Data/ProviderBase/DbConnectionPool.cs
src/libraries/System.Data.OleDb/src/DbConnectionOptions.cs
src/libraries/System.Data.OleDb/src/OleDbDataReader.cs
src/libraries/System.Data.OleDb/src/System/Data/ProviderBase/DbConnectionPool.cs
src/libraries/System.Data.SqlClient/src/Microsoft/SqlServer/Server/SmiEventSink_Default.cs
src/libraries/System.Data.SqlClient/src/Microsoft/SqlServer/Server/SmiMetaData.cs
src/libraries/System.Data.SqlClient/src/System/Data/ProviderBase/DbConnectionPool.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/LocalDBAPI.Common.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/TdsParser.cs
src/libraries/System.Data.SqlClient/src/System/Data/SqlClient/TdsValueSetter.cs
src/libraries/System.Diagnostics.DiagnosticSource/src/System/Diagnostics/DiagnosticListener.cs
src/libraries/System.Diagnostics.DiagnosticSource/src/System/Diagnostics/DiagnosticSourceEventSource.cs
src/libraries/System.Diagnostics.PerformanceCounter/src/System/Diagnostics/SharedPerformanceCounter.cs
src/libraries/System.Diagnostics.Process/src/System/Diagnostics/ProcessManager.Win32.cs
src/libraries/System.Diagnostics.Process/src/System/Diagnostics/ProcessManager.Windows.cs
src/libraries/System.Diagnostics.Tracing/tests/BasicEventSourceTest/TestEventCounter.cs
src/libraries/System.DirectoryServices/src/System/DirectoryServices/ActiveDirectory/Utils.cs
src/libraries/System.Drawing.Common/src/System/Drawing/GdiplusNative.cs
src/libraries/System.Drawing.Common/src/System/Drawing/Internal/SystemColorTracker.cs
src/libraries/System.Drawing.Common/src/System/Drawing/NativeMethods.cs
src/libraries/System.Drawing.Common/src/System/Drawing/Printing/PrintController.Windows.cs
src/libraries/System.IO.FileSystem/src/System/IO/File.cs
src/libraries/System.Linq.Expressions/src/System/Dynamic/BindingRestrictions.cs
src/libraries/System.Linq.Expressions/src/System/Dynamic/UpdateDelegates.Generated.cs
src/libraries/System.Linq.Expressions/src/System/Dynamic/Utils/TypeUtils.cs
src/libraries/System.Linq.Expressions/src/System/Linq/Expressions/Compiler/LambdaCompiler.Statements.cs
src/libraries/System.Linq.Expressions/tests/Dynamic/BindingRestrictionsProxyTests.cs
src/libraries/System.Linq.Expressions/tests/ILReader/SigParser.cs
src/libraries/System.Management/src/System/Management/InteropClasses/WMIInterop.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/ManagementEventWatcher.cs
src/libraries/System.Management/src/System/Management/ManagementObject.cs
src/libraries/System.Management/src/System/Management/ManagementObjectCollection.cs
src/libraries/System.Management/src/System/Management/ManagementOptions.cs
src/libraries/System.Management/src/System/Management/ManagementPath.cs
src/libraries/System.Management/src/System/Management/ManagementQuery.cs
src/libraries/System.Management/src/System/Management/ManagementScope.cs
src/libraries/System.Management/src/System/Management/Property.cs
src/libraries/System.Management/src/System/Management/WMIGenerator.cs
src/libraries/System.Management/src/System/Management/WmiEventSink.cs
src/libraries/System.Net.Http/src/System/Net/Http/SocketsHttpHandler/HttpEnvironmentProxy.cs
src/libraries/System.Net.HttpListener/src/System/Net/Windows/HttpListener.Windows.cs
src/libraries/System.Net.Mail/src/System/Net/Base64Stream.cs
src/libraries/System.Net.Mail/src/System/Net/Mail/SmtpConnection.cs
src/libraries/System.Net.Mail/src/System/Net/Mime/QEncodedStream.cs
src/libraries/System.Net.Mail/src/System/Net/Mime/QuotedPrintableStream.cs
src/libraries/System.Net.Sockets/src/System/Net/Sockets/SocketAsyncEventArgs.Windows.cs
src/libraries/System.Net.Sockets/src/System/Net/Sockets/SocketPal.Unix.cs
src/libraries/System.Net.Sockets/tests/FunctionalTests/SendFile.cs
src/libraries/System.Net.Sockets/tests/FunctionalTests/SendReceive.cs
src/libraries/System.Private.DataContractSerialization/src/System/Runtime/Serialization/DataContract.cs
src/libraries/System.Private.DataContractSerialization/src/System/Runtime/Serialization/XmlFormatWriterGenerator.cs
src/libraries/System.Private.Uri/src/System/Uri.cs
src/libraries/System.Private.Uri/src/System/UriExt.cs
src/libraries/System.Private.Uri/src/System/UriHelper.cs
src/libraries/System.Private.Xml/src/System/Xml/BinaryXml/SqlUtils.cs
src/libraries/System.Private.Xml/src/System/Xml/BinaryXml/XmlBinaryReader.cs
src/libraries/System.Private.Xml/src/System/Xml/Cache/XPathDocumentView.cs
src/libraries/System.Private.Xml/src/System/Xml/Core/HtmlEncodedRawTextWriter.cs
src/libraries/System.Private.Xml/src/System/Xml/Core/HtmlUtf8RawTextWriter.cs
src/libraries/System.Private.Xml/src/System/Xml/Core/ReadContentAsBinaryHelper.cs
src/libraries/System.Private.Xml/src/System/Xml/Core/ReadContentAsBinaryHelperAsync.cs
src/libraries/System.Private.Xml/src/System/Xml/Core/XmlEncodedRawTextWriter.cs
src/libraries/System.Private.Xml/src/System/Xml/Core/XmlEncodedRawTextWriterAsync.cs
src/libraries/System.Private.Xml/src/System/Xml/Core/XmlTextEncoder.cs
src/libraries/System.Private.Xml/src/System/Xml/Core/XmlTextReaderImpl.cs
src/libraries/System.Private.Xml/src/System/Xml/Core/XmlTextReaderImplAsync.cs
src/libraries/System.Private.Xml/src/System/Xml/Core/XmlTextWriter.cs
src/libraries/System.Private.Xml/src/System/Xml/Core/XmlUtf8RawTextWriter.cs
src/libraries/System.Private.Xml/src/System/Xml/Core/XmlUtf8RawTextWriterAsync.cs
src/libraries/System.Private.Xml/src/System/Xml/Core/XmlValidatingReaderImpl.cs
src/libraries/System.Private.Xml/src/System/Xml/Dom/DocumentXPathNavigator.cs
src/libraries/System.Private.Xml/src/System/Xml/Schema/DtdParser.cs
src/libraries/System.Private.Xml/src/System/Xml/Schema/DtdParserAsync.cs
src/libraries/System.Private.Xml/src/System/Xml/Schema/Inference/Infer.cs
src/libraries/System.Private.Xml/src/System/Xml/Schema/Preprocessor.cs
src/libraries/System.Private.Xml/src/System/Xml/Schema/SchemaCollectionpreProcessor.cs
src/libraries/System.Private.Xml/src/System/Xml/Schema/XdrValidator.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/XmlSchemaValidator.cs
src/libraries/System.Private.Xml/src/System/Xml/Schema/XsdValidator.cs
src/libraries/System.Private.Xml/src/System/Xml/Serialization/XmlSerializationReader.cs
src/libraries/System.Private.Xml/src/System/Xml/XPath/Internal/CacheOutputQuery.cs
src/libraries/System.Private.Xml/src/System/Xml/XPath/Internal/XPathScanner.cs
src/libraries/System.Private.Xml/src/System/Xml/XPath/XPathNavigatorReader.cs
src/libraries/System.Private.Xml/src/System/Xml/XmlConvert.cs
src/libraries/System.Private.Xml/src/System/Xml/Xsl/XPath/XPathScanner.cs
src/libraries/System.Private.Xml/tests/Readers/NameTable/XmlNameTable.cs
src/libraries/System.Reflection.MetadataLoadContext/src/System/Reflection/Runtime/BindingFlagSupport/Shared.cs
src/libraries/System.Reflection.MetadataLoadContext/src/System/Reflection/TypeLoading/CustomAttributes/RoCustomAttributeData.cs
src/libraries/System.Reflection.MetadataLoadContext/src/System/Reflection/TypeLoading/General/Assignability.cs
src/libraries/System.Reflection.MetadataLoadContext/tests/src/TestUtils/CustomAttributeInstantiator.cs
src/libraries/System.Runtime.Caching/src/System/Runtime/Caching/CacheExpires.cs
src/libraries/System.Runtime.Caching/src/System/Runtime/Caching/CacheUsage.cs
src/libraries/System.Runtime.Caching/src/System/Runtime/Caching/SafeBitVector32.cs
src/libraries/System.Runtime.Numerics/src/System/Numerics/BigInteger.cs
src/libraries/System.Runtime.Serialization.Formatters/src/System/Runtime/Serialization/Formatters/Binary/BinaryObjectReader.cs
src/libraries/System.Runtime.Serialization.Formatters/src/System/Runtime/Serialization/ObjectManager.cs
src/libraries/System.Security.AccessControl/src/System/Security/AccessControl/ACL.cs
src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/AsymmetricKeyExchangeDeformatter.cs
src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/AsymmetricKeyExchangeFormatter.cs
src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSAOAEPKeyExchangeDeformatter.cs
src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSAOAEPKeyExchangeFormatter.cs
src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSAPKCS1KeyExchangeDeformatter.cs
src/libraries/System.Security.Cryptography.Csp/src/System/Security/Cryptography/CapiHelper.DSA.Shared.cs
src/libraries/System.Text.Encoding.CodePages/src/System/Text/BaseCodePageEncoding.cs
src/libraries/System.Text.RegularExpressions/src/System/Text/RegularExpressions/Regex.Split.cs
src/libraries/System.Text.RegularExpressions/src/System/Text/RegularExpressions/RegexBoyerMoore.cs
src/libraries/System.Text.RegularExpressions/src/System/Text/RegularExpressions/RegexFCD.cs
src/libraries/System.Text.RegularExpressions/src/System/Text/RegularExpressions/RegexInterpreter.cs
src/libraries/System.Text.RegularExpressions/src/System/Text/RegularExpressions/RegexNode.cs
src/libraries/System.Text.RegularExpressions/src/System/Text/RegularExpressions/RegexParser.cs
src/libraries/System.Text.RegularExpressions/src/System/Text/RegularExpressions/RegexRunner.cs
src/libraries/System.Text.RegularExpressions/src/System/Text/RegularExpressions/RegexWriter.cs
src/libraries/System.Threading.Tasks.Dataflow/src/Blocks/JoinBlock.cs

index b9357d7..9be36cf 100644 (file)
@@ -341,7 +341,7 @@ internal static partial class Interop
             {
                 if (cfProtocolsArrayRef != null)
                 {
-                    for (int i = 0; i < cfProtocolsArrayRef.Length ; i++)
+                    for (int i = 0; i < cfProtocolsArrayRef.Length; i++)
                     {
                         cfProtocolsArrayRef[i]?.Dispose();
                     }
index 51eca49..ff58308 100644 (file)
@@ -17,12 +17,12 @@ internal static partial class Interop
 
             public Status MajorStatus
             {
-                get { return (Status)HResult;}
+                get { return (Status)HResult; }
             }
 
             public Status MinorStatus
             {
-                get { return _minorStatus;}
+                get { return _minorStatus; }
             }
 
             public GssApiException(string message) : base(message)
index f145d09..bfc5507 100644 (file)
@@ -10,6 +10,6 @@ namespace System.Net.Sockets
     internal struct WSABuffer
     {
         internal int Length; // Length of Buffer
-        internal IntPtr Pointer;// Pointer to Buffer
+        internal IntPtr Pointer; // Pointer to Buffer
     }
 }
index a95cb8c..646b950 100644 (file)
@@ -1222,7 +1222,7 @@ namespace System.Globalization
                 fixed (char* pFormat = &MemoryMarshal.GetReference(format))
                 {
                     int src = 0;
-                    for (;;)
+                    while (true)
                     {
                         if (src >= format.Length)
                         {
index c77c7e2..8fff712 100644 (file)
@@ -964,7 +964,7 @@ namespace Microsoft.CSharp.RuntimeBinder
         {
             if (pArg is ExprList list)
             {
-                for (;;)
+                while (true)
                 {
                     list.OptionalElement = StripNamedArgument(list.OptionalElement);
 
index 8711181..4941f16 100644 (file)
@@ -1033,7 +1033,7 @@ namespace Microsoft.CSharp.RuntimeBinder.Semantics
 
         private static void MarkAsIntermediateConversion(Expr pExpr)
         {
-            for (;;)
+            while (true)
             {
                 Debug.Assert(pExpr != null);
                 if (pExpr is ExprCall call)
index f6ae4ba..c179ee4 100644 (file)
@@ -594,7 +594,7 @@ namespace Microsoft.CSharp.RuntimeBinder.Semantics
             MethodSymbol methCur = null;
             AggregateType atsCur = (AggregateType)typeSrc;
 
-            for (;;)
+            while (true)
             {
                 // Find the next operator.
                 methCur = (methCur == null
index 599931e..fa24d71 100644 (file)
@@ -809,7 +809,7 @@ namespace Microsoft.CSharp.RuntimeBinder.Semantics
                 while (_HiddenTypes.Contains(_pCurrentType))
                 {
                     // Move through this type and get the next one.
-                    for (; iterator.CurrentType == _pCurrentType; iterator.MoveNext()) ;
+                    for (; iterator.CurrentType == _pCurrentType; iterator.MoveNext());
                     _pCurrentSym = iterator.CurrentSymbol;
                     _pCurrentType = iterator.CurrentType;
 
index 6882fed..98fc779 100644 (file)
@@ -431,7 +431,7 @@ namespace Microsoft.CSharp.RuntimeBinder.Semantics
             Debug.Assert(typeCur != null);
 
             // Loop through the interfaces.
-            for (; ;)
+            while (true)
             {
                 Debug.Assert(typeCur != null && typeCur.IsInterfaceType);
 
index be5d2a5..80b49b4 100644 (file)
@@ -121,7 +121,7 @@ namespace Microsoft.CSharp.RuntimeBinder.Semantics
 
             private bool FindNextMethod()
             {
-                for (;;)
+                while (true)
                 {
                     CurrentSymbol = (CurrentSymbol == null
                         ? SymbolLoader.LookupAggMember(_name, CurrentType.OwningAggregate, _mask)
index cbf0f11..8fb58bd 100644 (file)
@@ -608,7 +608,7 @@ namespace Microsoft.CSharp.RuntimeBinder.Semantics
 
             if (typeSrc is AggregateType aggSrc)
             {
-                for (;;)
+                while (true)
                 {
                     if ((aggSrc.IsInterfaceType || aggSrc.IsDelegateType) && TryVarianceAdjustmentToGetAccessibleType(context, aggSrc, out CType typeDst))
                     {
index 854413f..e6d73f3 100644 (file)
@@ -553,7 +553,7 @@ namespace System.Collections.Concurrent
             {
                 //reader through which we access the source data
                 private readonly IEnumerator<TSource> _sharedReader;
-                private readonly SharedLong _sharedIndex;//initial value -1
+                private readonly SharedLong _sharedIndex; //initial value -1
 
                 private volatile KeyValuePair<long, TSource>[]? _fillBuffer;  // intermediate buffer to reduce locking
                 private volatile int _fillBufferSize;               // actual number of elements in _FillBuffer. Will start
@@ -566,7 +566,7 @@ namespace System.Collections.Concurrent
                 private readonly SharedBool _sourceDepleted;    // no elements left in the enumerator, but there may be elements in the Fill Buffer
 
                 //shared synchronization lock, created by this Enumerable
-                private readonly object _sharedLock;//deferring allocation by enumerator
+                private readonly object _sharedLock; //deferring allocation by enumerator
 
                 private bool _disposed;
 
index ccbcf5d..57da31e 100644 (file)
@@ -325,7 +325,7 @@ namespace System.ComponentModel.Composition.Hosting
                             disposableRootProvider = _disposableRootProvider;
                             _disposableRootProvider = null;
 
-                            disposableLocalExportProvider = _disposableLocalExportProvider ;
+                            disposableLocalExportProvider = _disposableLocalExportProvider;
                             _disposableLocalExportProvider = null;
                             _localExportProvider = null;
 
index f481ed2..38a0392 100644 (file)
@@ -224,7 +224,7 @@ internal static Type GetContractTypeFromImport(this IAttributedImport import, Im
                 bool hasConstraints = false;
                 object[] genericParameterConstraints = new object[genericArguments.Length];
                 GenericParameterAttributes[] genericParameterAttributes = new GenericParameterAttributes[genericArguments.Length];
-                for (int i=0; i< genericArguments.Length ; i++)
+                for (int i=0; i< genericArguments.Length; i++)
                 {
                     Type genericArgument = genericArguments[i];
 
index 0c33897..67cca2b 100644 (file)
@@ -486,7 +486,7 @@ namespace System.ComponentModel.Design
             internal const int cmdidObjectVerbList6 = 143;
             internal const int cmdidObjectVerbList7 = 144;
             internal const int cmdidObjectVerbList8 = 145;
-            internal const int cmdidObjectVerbList9 = 146;// Unused on purpose!
+            internal const int cmdidObjectVerbList9 = 146; // Unused on purpose!
 
             internal const int cmdidConvertObject = 147;
             internal const int cmdidCustomControl = 148;
@@ -515,49 +515,49 @@ namespace System.ComponentModel.Design
             internal const int cmdidRemove = 168;
             internal const int cmdidJoinLeftAll = 169;
             internal const int cmdidJoinRightAll = 170;
-            internal const int cmdidAddToOutput = 171;// Add selected fields to query output
-            internal const int cmdidOtherQuery = 172;// change query type to 'other'
+            internal const int cmdidAddToOutput = 171; // Add selected fields to query output
+            internal const int cmdidOtherQuery = 172; // change query type to 'other'
             internal const int cmdidGenerateChangeScript = 173;
-            internal const int cmdidSaveSelection = 174;// Save current selection
-            internal const int cmdidAutojoinCurrent = 175;// Autojoin current tables
-            internal const int cmdidAutojoinAlways = 176;// Toggle Autojoin state
-            internal const int cmdidEditPage = 177;// Launch editor for url
-            internal const int cmdidViewLinks = 178;// Launch new webscope for url
-            internal const int cmdidStop = 179;// Stope webscope rendering
-            internal const int cmdidPause = 180;// Pause webscope rendering
-            internal const int cmdidResume = 181;// Resume webscope rendering
-            internal const int cmdidFilterDiagram = 182;// Filter webscope diagram
-            internal const int cmdidShowAllObjects = 183;// Show All objects in webscope diagram
-            internal const int cmdidShowApplications = 184;// Show Application objects in webscope diagram
-            internal const int cmdidShowOtherObjects = 185;// Show other objects in webscope diagram
-            internal const int cmdidShowPrimRelationships = 186;// Show primary relationships
-            internal const int cmdidExpand = 187;// Expand links
-            internal const int cmdidCollapse = 188;// Collapse links
-            internal const int cmdidRefresh = 189;// Refresh Webscope diagram
-            internal const int cmdidLayout = 190;// Layout websope diagram
-            internal const int cmdidShowResources = 191;// Show resouce objects in webscope diagram
-            internal const int cmdidInsertHTMLWizard = 192;// Insert HTML using a Wizard
-            internal const int cmdidShowDownloads = 193;// Show download objects in webscope diagram
-            internal const int cmdidShowExternals = 194;// Show external objects in webscope diagram
-            internal const int cmdidShowInBoundLinks = 195;// Show inbound links in webscope diagram
-            internal const int cmdidShowOutBoundLinks = 196;// Show out bound links in webscope diagram
-            internal const int cmdidShowInAndOutBoundLinks = 197;// Show in and out bound links in webscope diagram
-            internal const int cmdidPreview = 198;// Preview page
-            internal const int cmdidOpen = 261;// Open
-            internal const int cmdidOpenWith = 199;// Open with
-            internal const int cmdidShowPages = 200;// Show HTML pages
-            internal const int cmdidRunQuery = 201;// Runs a query
-            internal const int cmdidClearQuery = 202;// Clears the query's associated cursor
-            internal const int cmdidRecordFirst = 203;// Go to first record in set
-            internal const int cmdidRecordLast = 204;// Go to last record in set
-            internal const int cmdidRecordNext = 205;// Go to next record in set
-            internal const int cmdidRecordPrevious = 206;// Go to previous record in set
-            internal const int cmdidRecordGoto = 207;// Go to record via dialog
-            internal const int cmdidRecordNew = 208;// Add a record to set
-
-            internal const int cmdidInsertNewMenu = 209;// menu designer
-            internal const int cmdidInsertSeparator = 210;// menu designer
-            internal const int cmdidEditMenuNames = 211;// menu designer
+            internal const int cmdidSaveSelection = 174; // Save current selection
+            internal const int cmdidAutojoinCurrent = 175; // Autojoin current tables
+            internal const int cmdidAutojoinAlways = 176; // Toggle Autojoin state
+            internal const int cmdidEditPage = 177; // Launch editor for url
+            internal const int cmdidViewLinks = 178; // Launch new webscope for url
+            internal const int cmdidStop = 179; // Stope webscope rendering
+            internal const int cmdidPause = 180; // Pause webscope rendering
+            internal const int cmdidResume = 181; // Resume webscope rendering
+            internal const int cmdidFilterDiagram = 182; // Filter webscope diagram
+            internal const int cmdidShowAllObjects = 183; // Show All objects in webscope diagram
+            internal const int cmdidShowApplications = 184; // Show Application objects in webscope diagram
+            internal const int cmdidShowOtherObjects = 185; // Show other objects in webscope diagram
+            internal const int cmdidShowPrimRelationships = 186; // Show primary relationships
+            internal const int cmdidExpand = 187; // Expand links
+            internal const int cmdidCollapse = 188; // Collapse links
+            internal const int cmdidRefresh = 189; // Refresh Webscope diagram
+            internal const int cmdidLayout = 190; // Layout websope diagram
+            internal const int cmdidShowResources = 191; // Show resouce objects in webscope diagram
+            internal const int cmdidInsertHTMLWizard = 192; // Insert HTML using a Wizard
+            internal const int cmdidShowDownloads = 193; // Show download objects in webscope diagram
+            internal const int cmdidShowExternals = 194; // Show external objects in webscope diagram
+            internal const int cmdidShowInBoundLinks = 195; // Show inbound links in webscope diagram
+            internal const int cmdidShowOutBoundLinks = 196; // Show out bound links in webscope diagram
+            internal const int cmdidShowInAndOutBoundLinks = 197; // Show in and out bound links in webscope diagram
+            internal const int cmdidPreview = 198; // Preview page
+            internal const int cmdidOpen = 261; // Open
+            internal const int cmdidOpenWith = 199; // Open with
+            internal const int cmdidShowPages = 200; // Show HTML pages
+            internal const int cmdidRunQuery = 201; // Runs a query
+            internal const int cmdidClearQuery = 202; // Clears the query's associated cursor
+            internal const int cmdidRecordFirst = 203; // Go to first record in set
+            internal const int cmdidRecordLast = 204; // Go to last record in set
+            internal const int cmdidRecordNext = 205; // Go to next record in set
+            internal const int cmdidRecordPrevious = 206; // Go to previous record in set
+            internal const int cmdidRecordGoto = 207; // Go to record via dialog
+            internal const int cmdidRecordNew = 208; // Add a record to set
+
+            internal const int cmdidInsertNewMenu = 209; // menu designer
+            internal const int cmdidInsertSeparator = 210; // menu designer
+            internal const int cmdidEditMenuNames = 211; // menu designer
 
             internal const int cmdidDebugExplorer = 212;
             internal const int cmdidDebugProcesses = 213;
@@ -669,7 +669,7 @@ namespace System.ComponentModel.Design
             internal const int cmdidDockingViewFloater = 291;
             internal const int cmdidAutoHideWindow = 292;
             internal const int cmdidMoveToDropdownBar = 293;
-            internal const int cmdidFindCmd = 294;// internal Find commands
+            internal const int cmdidFindCmd = 294; // internal Find commands
             internal const int cmdidStart = 295;
             internal const int cmdidRestart = 296;
 
@@ -754,8 +754,8 @@ namespace System.ComponentModel.Design
             internal const int cmdidFindHelp = 356;
             internal const int cmdidFindInFiles = 277;
             internal const int cmdidReplaceInFiles = 278;
-            internal const int cmdidNextLocation = 279;// next item in task list, find in files results, etc.
-            internal const int cmdidPreviousLocation = 280;// prev item "
+            internal const int cmdidNextLocation = 279; // next item in task list, find in files results, etc.
+            internal const int cmdidPreviousLocation = 280; // prev item "
 
             internal const int cmdidTaskListNextError = 357;
             internal const int cmdidTaskListPrevError = 358;
@@ -799,7 +799,7 @@ namespace System.ComponentModel.Design
             internal const int cmdidMarkerCmd8 = 408;
             internal const int cmdidMarkerCmd9 = 409;
             internal const int cmdidMarkerLast = 409;
-            internal const int cmdidMarkerEnd = 410;// list terminator reserved
+            internal const int cmdidMarkerEnd = 410; // list terminator reserved
 
             // user-invoked project reload and unload
             internal const int cmdidReloadProject = 412;
@@ -848,7 +848,7 @@ namespace System.ComponentModel.Design
             internal const int cmdidWindow22 = 591;
             internal const int cmdidWindow23 = 592;
             internal const int cmdidWindow24 = 593;
-            internal const int cmdidWindow25 = 594;// note cmdidWindow25 is unused on purpose!
+            internal const int cmdidWindow25 = 594; // note cmdidWindow25 is unused on purpose!
             internal const int cmdidMoreWindows = 595;
 
             //internal const int    = 597;//UNUSED
@@ -880,7 +880,7 @@ namespace System.ComponentModel.Design
             internal const int cmdidMRUProj22 = 621;
             internal const int cmdidMRUProj23 = 622;
             internal const int cmdidMRUProj24 = 623;
-            internal const int cmdidMRUProj25 = 624;// note cmdidMRUProj25 is unused on purpose!
+            internal const int cmdidMRUProj25 = 624; // note cmdidMRUProj25 is unused on purpose!
 
             internal const int cmdidSplitNext = 625;
             internal const int cmdidSplitPrev = 626;
@@ -889,8 +889,8 @@ namespace System.ComponentModel.Design
             internal const int cmdidNextDocument = 628;
             internal const int cmdidPrevDocument = 629;
 
-            internal const int cmdidTool1 = 630;// note cmdidTool1 - cmdidTool24 must be
-            internal const int cmdidTool2 = 631;// consecutive
+            internal const int cmdidTool1 = 630; // note cmdidTool1 - cmdidTool24 must be
+            internal const int cmdidTool2 = 631; // consecutive
             internal const int cmdidTool3 = 632;
             internal const int cmdidTool4 = 633;
             internal const int cmdidTool5 = 634;
@@ -921,30 +921,30 @@ namespace System.ComponentModel.Design
             internal const int cmdidCloseDocument = 658;
             internal const int cmdidToolboxSortItems = 659;
 
-            internal const int cmdidViewBarView1 = 660;//UNUSED
-            internal const int cmdidViewBarView2 = 661;//UNUSED
-            internal const int cmdidViewBarView3 = 662;//UNUSED
-            internal const int cmdidViewBarView4 = 663;//UNUSED
-            internal const int cmdidViewBarView5 = 664;//UNUSED
-            internal const int cmdidViewBarView6 = 665;//UNUSED
-            internal const int cmdidViewBarView7 = 666;//UNUSED
-            internal const int cmdidViewBarView8 = 667;//UNUSED
-            internal const int cmdidViewBarView9 = 668;//UNUSED
-            internal const int cmdidViewBarView10 = 669;//UNUSED
-            internal const int cmdidViewBarView11 = 670;//UNUSED
-            internal const int cmdidViewBarView12 = 671;//UNUSED
-            internal const int cmdidViewBarView13 = 672;//UNUSED
-            internal const int cmdidViewBarView14 = 673;//UNUSED
-            internal const int cmdidViewBarView15 = 674;//UNUSED
-            internal const int cmdidViewBarView16 = 675;//UNUSED
-            internal const int cmdidViewBarView17 = 676;//UNUSED
-            internal const int cmdidViewBarView18 = 677;//UNUSED
-            internal const int cmdidViewBarView19 = 678;//UNUSED
-            internal const int cmdidViewBarView20 = 679;//UNUSED
-            internal const int cmdidViewBarView21 = 680;//UNUSED
-            internal const int cmdidViewBarView22 = 681;//UNUSED
-            internal const int cmdidViewBarView23 = 682;//UNUSED
-            internal const int cmdidViewBarView24 = 683;//UNUSED
+            internal const int cmdidViewBarView1 = 660; //UNUSED
+            internal const int cmdidViewBarView2 = 661; //UNUSED
+            internal const int cmdidViewBarView3 = 662; //UNUSED
+            internal const int cmdidViewBarView4 = 663; //UNUSED
+            internal const int cmdidViewBarView5 = 664; //UNUSED
+            internal const int cmdidViewBarView6 = 665; //UNUSED
+            internal const int cmdidViewBarView7 = 666; //UNUSED
+            internal const int cmdidViewBarView8 = 667; //UNUSED
+            internal const int cmdidViewBarView9 = 668; //UNUSED
+            internal const int cmdidViewBarView10 = 669; //UNUSED
+            internal const int cmdidViewBarView11 = 670; //UNUSED
+            internal const int cmdidViewBarView12 = 671; //UNUSED
+            internal const int cmdidViewBarView13 = 672; //UNUSED
+            internal const int cmdidViewBarView14 = 673; //UNUSED
+            internal const int cmdidViewBarView15 = 674; //UNUSED
+            internal const int cmdidViewBarView16 = 675; //UNUSED
+            internal const int cmdidViewBarView17 = 676; //UNUSED
+            internal const int cmdidViewBarView18 = 677; //UNUSED
+            internal const int cmdidViewBarView19 = 678; //UNUSED
+            internal const int cmdidViewBarView20 = 679; //UNUSED
+            internal const int cmdidViewBarView21 = 680; //UNUSED
+            internal const int cmdidViewBarView22 = 681; //UNUSED
+            internal const int cmdidViewBarView23 = 682; //UNUSED
+            internal const int cmdidViewBarView24 = 683; //UNUSED
 
             internal const int cmdidSolutionCfg = 684;
             internal const int cmdidSolutionCfgGetList = 685;
@@ -1006,7 +1006,7 @@ namespace System.ComponentModel.Design
             internal const int cmdidTaskListCustomView47 = 724;
             internal const int cmdidTaskListCustomView48 = 725;
             internal const int cmdidTaskListCustomView49 = 726;
-            internal const int cmdidTaskListCustomView50 = 727;//not used on purpose, ends the list
+            internal const int cmdidTaskListCustomView50 = 727; //not used on purpose, ends the list
 
             internal const int cmdidObjectSearch = 728;
 
@@ -1059,7 +1059,7 @@ namespace System.ComponentModel.Design
             internal const int cmdidTaggedExp8 = 767;
             internal const int cmdidTaggedExp9 = 768;
 
-            internal const int cmdidEditorWidgetClick = 769;// param    = 0;is the moniker as VT_BSTR, param    = 1;is the buffer line as VT_I4, and param    = 2;is the buffer index as VT_I4
+            internal const int cmdidEditorWidgetClick = 769; // param    = 0;is the moniker as VT_BSTR, param    = 1;is the buffer line as VT_I4, and param    = 2;is the buffer index as VT_I4
             internal const int cmdidCmdWinUpdateAC = 770;
 
             internal const int cmdidSlnCfgMgr = 771;
@@ -1101,7 +1101,7 @@ namespace System.ComponentModel.Design
             internal const int cmdidAutoHideContext30 = 805;
             internal const int cmdidAutoHideContext31 = 806;
             internal const int cmdidAutoHideContext32 = 807;
-            internal const int cmdidAutoHideContext33 = 808;// must remain unused
+            internal const int cmdidAutoHideContext33 = 808; // must remain unused
 
             internal const int cmdidShellNavBackward = 809;
             internal const int cmdidShellNavForward = 810;
@@ -1138,7 +1138,7 @@ namespace System.ComponentModel.Design
             internal const int cmdidShellNavigate30 = 840;
             internal const int cmdidShellNavigate31 = 841;
             internal const int cmdidShellNavigate32 = 842;
-            internal const int cmdidShellNavigate33 = 843;// must remain unused
+            internal const int cmdidShellNavigate33 = 843; // must remain unused
 
             internal const int cmdidShellWindowNavigate1 = 844;
             internal const int cmdidShellWindowNavigate2 = 845;
@@ -1172,7 +1172,7 @@ namespace System.ComponentModel.Design
             internal const int cmdidShellWindowNavigate30 = 873;
             internal const int cmdidShellWindowNavigate31 = 874;
             internal const int cmdidShellWindowNavigate32 = 875;
-            internal const int cmdidShellWindowNavigate33 = 876;// must remain unused
+            internal const int cmdidShellWindowNavigate33 = 876; // must remain unused
 
             // ObjectSearch cmds
             internal const int cmdidOBSDoFind = 877;
@@ -1226,7 +1226,7 @@ namespace System.ComponentModel.Design
             internal const int cmdidMRUFile22 = 921;
             internal const int cmdidMRUFile23 = 922;
             internal const int cmdidMRUFile24 = 923;
-            internal const int cmdidMRUFile25 = 924;// note cmdidMRUFile25 is unused on purpose!
+            internal const int cmdidMRUFile25 = 924; // note cmdidMRUFile25 is unused on purpose!
 
             // Object Browsing & ClassView cmds
             // Shared shell cmds (for accessing Object Browsing functionality)
@@ -1250,7 +1250,7 @@ namespace System.ComponentModel.Design
             internal const int cmdidCVShowPackages = 953;
             internal const int cmdidQryManageIndexes = 954;
             internal const int cmdidBrowseComponent = 955;
-            internal const int cmdidPrintDefault = 956;// quick print
+            internal const int cmdidPrintDefault = 956; // quick print
 
             internal const int cmdidBrowseDoc = 957;
 
index 25b0c18..0283dc3 100644 (file)
@@ -3582,7 +3582,7 @@ namespace System.Configuration
                 throw new ConfigurationErrorsException(SR.EncryptedNode_not_found, filename, lineNumber);
 
             // Find the <EncryptedData> node
-            for (;;)
+            while (true)
             {
                 clone.Read(); // Keep reading till we find a relavant node
 
index c00ffa0..a45f60b 100644 (file)
@@ -614,7 +614,7 @@ namespace System.Configuration
                 if (reader.Name != name)
                     throw new ConfigurationErrorsException(SR.Format(SR.Config_unexpected_element_name, reader.Name));
 
-                for (;;)
+                while (true)
                 {
                     if (!reader.Read())
                     {
index 7b59fb4..b976b54 100644 (file)
@@ -25,7 +25,7 @@ namespace System.Configuration
             }
             set
             {
-                for (;;)
+                while (true)
                 {
                     int oldData = _data;
                     int newData;
index 34b262b..585c48a 100644 (file)
@@ -277,7 +277,7 @@ namespace System.Data.Common
         public abstract string ConvertObjectToXml(object value);
         public virtual void ConvertObjectToXml(object value, XmlWriter xmlWriter, XmlRootAttribute xmlAttrib)
         {
-            xmlWriter.WriteString(ConvertObjectToXml(value));// should it be NO OP?
+            xmlWriter.WriteString(ConvertObjectToXml(value)); // should it be NO OP?
         }
 
         public static DataStorage CreateStorage(DataColumn column, Type dataType, StorageType typeCode)
index 999cbcf..a35248f 100644 (file)
@@ -139,7 +139,7 @@ namespace System.Data.Common
                         {
                             return _values[records[0]];
                         }
-                        return null;// no data => null
+                        return null; // no data => null
 
                     case AggregateType.Count:
                         count = 0;
index c2979da..609ea54 100644 (file)
@@ -31,7 +31,7 @@ namespace System.Data.Common
                         {
                             return _values[records[0]];
                         }
-                        return null;// no data => null
+                        return null; // no data => null
 
                     case AggregateType.Count:
                         int count = 0;
index 7f0dc53..ffc131c 100644 (file)
@@ -31,7 +31,7 @@ namespace System.Data.Common
                         {
                             return _values[records[0]];
                         }
-                        return null;// no data => null
+                        return null; // no data => null
 
                     case AggregateType.Count:
                         int count = 0;
index e3c7515..9ff763d 100644 (file)
@@ -66,7 +66,7 @@ namespace System.Data.Common
                         {
                             return _values[records[0]];
                         }
-                        return null;// no data => null
+                        return null; // no data => null
 
                     case AggregateType.Count:
                         int count = 0;
index 491747d..273ebc6 100644 (file)
@@ -139,7 +139,7 @@ namespace System.Data.Common
                         {
                             return _values[records[0]];
                         }
-                        return null;// no data => null
+                        return null; // no data => null
 
                     case AggregateType.Count:
                         count = 0;
index 99ec070..a643e7e 100644 (file)
@@ -139,7 +139,7 @@ namespace System.Data.Common
                         {
                             return _values[records[0]];
                         }
-                        return null;// no data => null
+                        return null; // no data => null
 
                     case AggregateType.Count:
                         count = 0;
index 2769e98..42693ea 100644 (file)
@@ -140,7 +140,7 @@ namespace System.Data.Common
                         {
                             return _values[records[0]];
                         }
-                        return null;// no data => null
+                        return null; // no data => null
 
                     case AggregateType.Count:
                         count = 0;
index 614101c..d44ec1e 100644 (file)
@@ -1280,7 +1280,7 @@ namespace System.Data
                 // there is a change, since we are supporting hierarchy(bacause of Names Simple Type) old check (just one leel base check) is wrong
                 if (value != null && value.CanHaveMaxLength())
                 {
-                    _maxLength = _simpleType.MaxLength;// this is temp solution, since we dont let simple content to have
+                    _maxLength = _simpleType.MaxLength; // this is temp solution, since we dont let simple content to have
                 }
 
                 //maxlength set but for simple type we want to set it, after coming to decision about it , we should
@@ -1532,7 +1532,7 @@ namespace System.Data
             clone.DataType = DataType;
             clone._defaultValue = _defaultValue;
             clone._defaultValueIsNull = ((_defaultValue == DBNull.Value) || (clone.ImplementsINullable && DataStorage.IsObjectSqlNull(_defaultValue))) ? true : false;
-            clone._columnMapping = _columnMapping;// clone column Mapping since we dont let MaxLength to be set throu API
+            clone._columnMapping = _columnMapping; // clone column Mapping since we dont let MaxLength to be set throu API
             clone._readOnly = _readOnly;
             clone.MaxLength = MaxLength;
             clone.XmlDataType = XmlDataType;
index 8669d8b..1bc2753 100644 (file)
@@ -76,7 +76,7 @@ namespace System.Data
         public override void ResetValue(object component)
         {
             DataRowView dataRowView = (DataRowView)component;
-            dataRowView.SetColumnValue(Column, DBNull.Value);// no need to ccheck for the col type and set Sql...Null!
+            dataRowView.SetColumnValue(Column, DBNull.Value); // no need to ccheck for the col type and set Sql...Null!
         }
 
         public override void SetValue(object component, object value)
index 0693827..121de16 100644 (file)
@@ -889,7 +889,7 @@ namespace System.Data
                     return row;
                 }
             }
-            return null;// Rule 1: At all times, only ONE FK  "(in a row) can be non-Null
+            return null; // Rule 1: At all times, only ONE FK  "(in a row) can be non-Null
         }
         // No Nested in 1-many
 
index 165d157..99f7c60 100644 (file)
@@ -1127,7 +1127,7 @@ namespace System.Data
                         ForeignKeyConstraint foreign = constraints[j] as ForeignKeyConstraint;
                         if (foreign.Table == foreign.RelatedTable)
                         {
-                            continue;// we have already added this foreign key in while cloning the datatable
+                            continue; // we have already added this foreign key in while cloning the datatable
                         }
 
                         ds.Tables[i].Constraints.Add(constraints[j].Clone(ds));
index 9f06533..3cd42b5 100644 (file)
@@ -484,7 +484,7 @@ namespace System.Data
             //Constraints
             if (isSingleTable)
             {
-                DeserializeConstraints(info, context, /*table index */ 0, /* serialize all constraints */false);// since single table, send table index as 0, meanwhile passing
+                DeserializeConstraints(info, context, /*table index */ 0, /* serialize all constraints */false); // since single table, send table index as 0, meanwhile passing
                 // false for 'allConstraints' means, handle all the constraint related to the table
             }
         }
@@ -761,9 +761,9 @@ namespace System.Data
                 ArrayList storeList = (ArrayList)info.GetValue(string.Format(formatProvider, "DataTable_{0}.Records", serIndex), typeof(ArrayList));
                 ArrayList nullbitList = (ArrayList)info.GetValue(string.Format(formatProvider, "DataTable_{0}.NullBits", serIndex), typeof(ArrayList));
                 Hashtable rowErrors = (Hashtable)info.GetValue(string.Format(formatProvider, "DataTable_{0}.RowErrors", serIndex), typeof(Hashtable));
-                rowErrors.OnDeserialization(this);//OnDeSerialization must be called since the hashtable gets deserialized after the whole graph gets deserialized
+                rowErrors.OnDeserialization(this); //OnDeSerialization must be called since the hashtable gets deserialized after the whole graph gets deserialized
                 Hashtable colErrors = (Hashtable)info.GetValue(string.Format(formatProvider, "DataTable_{0}.ColumnErrors", serIndex), typeof(Hashtable));
-                colErrors.OnDeserialization(this);//OnDeSerialization must be called since the hashtable gets deserialized after the whole graph gets deserialized
+                colErrors.OnDeserialization(this); //OnDeSerialization must be called since the hashtable gets deserialized after the whole graph gets deserialized
 
                 if (recordCount <= 0)
                 {
@@ -969,7 +969,7 @@ namespace System.Data
                         int numIndexes = _shadowIndexes.Count;
                         for (int i = 0; i < numIndexes; i++)
                         {
-                            Index ndx = _shadowIndexes[i];// shadowindexes may change, see ShadowIndexCopy()
+                            Index ndx = _shadowIndexes[i]; // shadowindexes may change, see ShadowIndexCopy()
                             try
                             {
                                 if (forceReset || ndx.HasRemoteAggregate)
@@ -1846,7 +1846,7 @@ namespace System.Data
                     DataTable parentTable = nestedRelations[j].ParentTable;
                     if (!visitedTables.Contains(parentTable))
                         visitedTables.Add(parentTable);
-                    return parentTable.GetInheritedNamespace(visitedTables);// this is the same as return parentTable.Namespace
+                    return parentTable.GetInheritedNamespace(visitedTables); // this is the same as return parentTable.Namespace
                 }
             } // dont put else
 
@@ -2793,7 +2793,7 @@ namespace System.Data
             }
             finally
             {
-                row.ResetLastChangedColumn();// if expression is evaluated while adding, before  return, we want to clear it
+                row.ResetLastChangedColumn(); // if expression is evaluated while adding, before  return, we want to clear it
             }
         }
 
@@ -3749,7 +3749,7 @@ namespace System.Data
                 int numIndexes = _shadowIndexes.Count;
                 for (int i = 0; i < numIndexes; i++)
                 {
-                    Index ndx = _shadowIndexes[i];// shadowindexes may change, see ShadowIndexCopy()
+                    Index ndx = _shadowIndexes[i]; // shadowindexes may change, see ShadowIndexCopy()
                     if (0 < ndx.RefCount)
                     {
                         ndx.RecordChanged(record);
@@ -3775,7 +3775,7 @@ namespace System.Data
                 int numIndexes = _shadowIndexes.Count;
                 for (int i = 0; i < numIndexes; i++)
                 {
-                    Index ndx = _shadowIndexes[i];// shadowindexes may change, see ShadowIndexCopy()
+                    Index ndx = _shadowIndexes[i]; // shadowindexes may change, see ShadowIndexCopy()
                     if (0 < ndx.RefCount)
                     {
                         ndx.RecordChanged(oldIndex[i], newIndex[i]);
@@ -3796,7 +3796,7 @@ namespace System.Data
                 int numIndexes = _shadowIndexes.Count;
                 for (int i = 0; i < numIndexes; i++)
                 {
-                    Index ndx = _shadowIndexes[i];// shadowindexes may change, see ShadowIndexCopy()
+                    Index ndx = _shadowIndexes[i]; // shadowindexes may change, see ShadowIndexCopy()
                     if (0 < ndx.RefCount)
                     {
                         ndx.RecordStateChanged(record, oldState, newState);
@@ -3819,7 +3819,7 @@ namespace System.Data
                 int numIndexes = _shadowIndexes.Count;
                 for (int i = 0; i < numIndexes; i++)
                 {
-                    Index ndx = _shadowIndexes[i];// shadowindexes may change, see ShadowIndexCopy()
+                    Index ndx = _shadowIndexes[i]; // shadowindexes may change, see ShadowIndexCopy()
                     if (0 < ndx.RefCount)
                     {
                         if (record1 != -1 && record2 != -1)
@@ -3926,9 +3926,9 @@ namespace System.Data
             // if expression has changed
             if (!equalValues)
             {
-                int[] oldIndex = dr.Table.RemoveRecordFromIndexes(dr, version);// conditional, if it exists it will try to remove with no event fired
+                int[] oldIndex = dr.Table.RemoveRecordFromIndexes(dr, version); // conditional, if it exists it will try to remove with no event fired
                 dc.SetValue(record, newValue);
-                int[] newIndex = dr.Table.InsertRecordToIndexes(dr, version);// conditional, it will insert if it qualifies, no event will be fired
+                int[] newIndex = dr.Table.InsertRecordToIndexes(dr, version); // conditional, it will insert if it qualifies, no event will be fired
                 if (dr.HasVersion(version))
                 {
                     if (version != DataRowVersion.Original)
@@ -4053,7 +4053,7 @@ namespace System.Data
                 int numIndexes = _shadowIndexes.Count;
                 for (int i = 0; i < numIndexes; i++)
                 {
-                    Index ndx = _shadowIndexes[i];// shadowindexes may change, see ShadowIndexCopy()
+                    Index ndx = _shadowIndexes[i]; // shadowindexes may change, see ShadowIndexCopy()
                     if (0 < ndx.RefCount)
                     {
                         if (null == column)
@@ -4771,10 +4771,10 @@ namespace System.Data
                 if (_inDataLoad && !AreIndexEventsSuspended)
                 {
                     // we do not want to fire any listchanged in new Load/Fill
-                    SuspendIndexEvents();// so suspend events here(not suspended == table already has some rows initially)
+                    SuspendIndexEvents(); // so suspend events here(not suspended == table already has some rows initially)
                 }
 
-                DataRow dataRow = LoadRow(values, loadOption, indextoUse);// if indextoUse == null, it means we dont have PK,
+                DataRow dataRow = LoadRow(values, loadOption, indextoUse); // if indextoUse == null, it means we dont have PK,
                                                                           // so LoadRow will take care of just adding the row to end
 
                 return dataRow;
@@ -5518,7 +5518,7 @@ namespace System.Data
                 }
 
                 DataSet ds = null;
-                string tablenamespace = _tableNamespace;//SQL BU Defect Tracking 286968
+                string tablenamespace = _tableNamespace; //SQL BU Defect Tracking 286968
 
                 // Generate SchemaTree and write it out
                 if (null == DataSet)
index 5e68f9d..d070b88 100644 (file)
@@ -27,7 +27,7 @@ namespace System.Data
         internal const int EqualTo = 7;     // =
         internal const int GreaterThen = 8; // >
         internal const int LessThen = 9;        // <
-        internal const int GreaterOrEqual = 10;// >=
+        internal const int GreaterOrEqual = 10; // >=
         internal const int LessOrEqual = 11;    // <=
         internal const int NotEqual = 12;       // <>
         /* End of Comparison (relational) operators */
index ef771ca..650cac5 100644 (file)
@@ -699,7 +699,7 @@ namespace System.Data
             }
             else
             {
-                iDest = destination.Tables.IndexOf(RelatedTable.TableName, RelatedTable.Namespace, false);// pass false for last param
+                iDest = destination.Tables.IndexOf(RelatedTable.TableName, RelatedTable.Namespace, false); // pass false for last param
             }
             if (iDest < 0)
             {
index 6f123b0..702a0e1 100644 (file)
@@ -48,7 +48,7 @@ namespace System.Data
             _IgnoreNSforTableLookup = (_dataSet._namespaceURI != source._namespaceURI); // if two DataSets have different
             // Namespaces, ignore NS for table lookups as we won't be able to find the right tables which inherits its NS
 
-            List<DataColumn> existingColumns = null;// need to cache existing columns
+            List<DataColumn> existingColumns = null; // need to cache existing columns
 
             if (MissingSchemaAction.Add == _missingSchemaAction)
             {
@@ -93,7 +93,7 @@ namespace System.Data
                     }
                     else
                     {
-                        targetTable = _dataSet.Tables[sourceTable.TableName, sourceTable.Namespace];// we know that target table won't be null since MissingSchemaAction is Add , we have already added it!
+                        targetTable = _dataSet.Tables[sourceTable.TableName, sourceTable.Namespace]; // we know that target table won't be null since MissingSchemaAction is Add , we have already added it!
                     }
 
                     foreach (DataColumn dc in sourceTable.Columns)
index 9d03eb4..0dd2400 100644 (file)
@@ -930,7 +930,7 @@ namespace System.Data.SqlTypes
                                                                      //the decimal digits, from the
                                                                      //lowest significant to highest significant
 
-            int iDigits = 0;//Number of significant digits
+            int iDigits = 0; //Number of significant digits
             uint ulRem; //Remainder of a division by x_ulBase10, i.e.,least significant digit
 
             // Build the final numeric string by inserting the sign, reversing
@@ -1445,7 +1445,7 @@ namespace System.Data.SqlTypes
 
             lScaleAdjust = ResScale - ActualScale;
 
-            fResPositive = (x.IsPositive == y.IsPositive);//positive if both signs same.
+            fResPositive = (x.IsPositive == y.IsPositive); //positive if both signs same.
 
             // II) Perform multiplication
 
@@ -1484,7 +1484,7 @@ namespace System.Data.SqlTypes
                         dwlNextAccum = 0;
 
                     // Update result and accum
-                    rgulRes[idRes++] = unchecked((uint)dwlAccum);// & x_ulInt32BaseForMod); // equiv to mod x_lInt32Base
+                    rgulRes[idRes++] = unchecked((uint)dwlAccum); // & x_ulInt32BaseForMod); // equiv to mod x_lInt32Base
                     dwlAccum = (dwlAccum >> 32) + dwlNextAccum; // equiv to div BaseUI4 + dwlNAccum
 
                     // dwlNextAccum can't overflow next iteration
@@ -1654,7 +1654,7 @@ namespace System.Data.SqlTypes
                 throw new DivideByZeroException(SQLResource.DivideByZeroMessage);
 
             // 1) Figure out result prec,scale,sign..
-            fResSignPos = (x.IsPositive == y.IsPositive);//sign of result
+            fResSignPos = (x.IsPositive == y.IsPositive); //sign of result
 
             //scale = max(s1 + p2 + 1, x_cNumeDivScaleMin);
             //precision = max(s1 + p2 + 1, x_cNumeDivScaleMin) + p1 + p2 + 1;
@@ -2354,7 +2354,7 @@ namespace System.Data.SqlTypes
 
             SqlDecimal ret = n;
 
-            int lScaleAdjust = scale - ret._bScale;//Adjustment to scale
+            int lScaleAdjust = scale - ret._bScale; //Adjustment to scale
 
             //Adjust scale
             ret.AdjustScale(lScaleAdjust, true);
index a9e8a36..5c273d1 100644 (file)
@@ -351,7 +351,7 @@ namespace System.Data
                             if (_candidateColumns[i] != null)
                             {
                                 ndxFields[j++] = new IndexField(_table.Columns[i], isDescending: false);
-                                _candidateColumns[i].flag = false;// this means it is processed
+                                _candidateColumns[i].flag = false; // this means it is processed
                             }
                         }
                         for (i = 0; i < lenIndexDesc; i++)
@@ -371,7 +371,7 @@ namespace System.Data
                         {
                             if (_candidateColumns[i] != null)
                             {
-                                _candidateColumns[i].flag = false;// same as before, it is false when it returns
+                                _candidateColumns[i].flag = false; // same as before, it is false when it returns
                             }
                         }
 
@@ -433,7 +433,7 @@ namespace System.Data
                         {
                             if (_candidateColumns[i] != null)
                             {
-                                _candidateColumns[i].flag = false;// same as before, it is false when it returns
+                                _candidateColumns[i].flag = false; // same as before, it is false when it returns
                             }
                         }
                     }
index 61d4d99..90d130f 100644 (file)
@@ -74,7 +74,7 @@ namespace System.Data
 
                 if (_baseSimpleType != null && _baseSimpleType.Name != null && _baseSimpleType.Name.Length > 0)
                 {
-                    _xmlBaseType = _baseSimpleType.XmlBaseType;//  SimpleTypeQualifiedName;
+                    _xmlBaseType = _baseSimpleType.XmlBaseType; //  SimpleTypeQualifiedName;
                 }
                 else
                 {
index 8d4b4ee..38b84a2 100644 (file)
@@ -280,7 +280,7 @@ namespace System.Data
             }
             else
             {
-                iDest = destination.Tables.IndexOf(Table.TableName, Table.Namespace, false);// pass false for last param to be backward compatable
+                iDest = destination.Tables.IndexOf(Table.TableName, Table.Namespace, false); // pass false for last param to be backward compatable
             }
 
             if (iDest < 0)
index 2e6a627..d45e90a 100644 (file)
@@ -374,7 +374,7 @@ namespace System.Data
                             row.Read(); // consume the current node
                         row.Read(); // now points to the next column
                         //SkipWhitespaces(row); seems no need, just in case if we see other issue , this will be here as hint
-                        continue;// add a read here!
+                        continue; // add a read here!
                     }
 
                     if (column.IsCustomType)
index 6ee2c62..e88572c 100644 (file)
@@ -532,7 +532,7 @@ namespace System.Data
             if (items == null)
                 return false; // empty element, threat it as table
 
-            bool isChoice = FromInference && (pt is XmlSchemaChoice);// currently we add this support for choice, just for inference
+            bool isChoice = FromInference && (pt is XmlSchemaChoice); // currently we add this support for choice, just for inference
 
 
             foreach (XmlSchemaAnnotated el in items)
@@ -952,7 +952,7 @@ namespace System.Data
 
                         if (relation == null)
                         {
-                            tableChildren.Add(child);// how about prefix for this?
+                            tableChildren.Add(child); // how about prefix for this?
                             if (FromInference && table.UKColumnPositionForInference == -1)
                             { // this is done for Inference
                                 int ukColumnPosition = -1;
@@ -1709,7 +1709,7 @@ namespace System.Data
                 DataColumn parentKey;
                 if (FromInference)
                 {
-                    int position = table.UKColumnPositionForInference;// we keep posiotion of unique key column here, for inference
+                    int position = table.UKColumnPositionForInference; // we keep posiotion of unique key column here, for inference
                     if (position == -1)
                         foreach (DataColumn dc in table.Columns)
                         {
@@ -2203,7 +2203,7 @@ namespace System.Data
                 {
                     // this means UDSimpleType
                     strType = node.QualifiedName.ToString(); // use qualifed name
-                    type = ParseDataType(node.QualifiedName.ToString());// search with QName
+                    type = ParseDataType(node.QualifiedName.ToString()); // search with QName
                 }
                 else
                 {
@@ -2435,7 +2435,7 @@ namespace System.Data
                     {
                         return; // backward compatability
                     }
-                    column = new DataColumn(columnName, type, null, MappingType.Element);// this is to fix issue with Exception we used to throw for old inference engine if column
+                    column = new DataColumn(columnName, type, null, MappingType.Element); // this is to fix issue with Exception we used to throw for old inference engine if column
                     //exists with different namespace; while adding it to columncollection
                     isToAdd = true;
                 }
index a39a1b4..59c8672 100644 (file)
@@ -927,7 +927,7 @@ namespace System.Data
             {
                 xmlWriter.Flush();
             }
-            return;// rootSchema;
+            return; // rootSchema;
         }
 
         internal XmlElement SchemaTree(XmlDocument xd, DataTable dt)
index 7d9e03a..2a3da7a 100644 (file)
@@ -19,7 +19,7 @@ namespace System.Data.Common
 
         private NameValuePermission[] _tree; // with branches
 
-        internal static readonly NameValuePermission Default = null;// = new NameValuePermission(String.Empty, new string[] { "File Name" }, KeyRestrictionBehavior.AllowOnly);
+        internal static readonly NameValuePermission Default = null; // = new NameValuePermission(String.Empty, new string[] { "File Name" }, KeyRestrictionBehavior.AllowOnly);
 
         internal NameValuePermission()
         { // root node
index ac6842e..4ecf414 100644 (file)
@@ -322,7 +322,7 @@ namespace System.Data.ProviderBase
             // new stack to old stack.
             if (_waitHandles.PoolSemaphore.WaitOne(0))
             {
-                for (;;)
+                while (true)
                 {
                     DbConnectionInternal obj;
 
index ac1b2ed..acf49eb 100644 (file)
@@ -73,7 +73,7 @@ namespace System.Data.Common
         private static readonly Regex ConnectionStringRegexOdbc = new Regex(ConnectionStringPatternOdbc, RegexOptions.ExplicitCapture | RegexOptions.Compiled);
         private static readonly Regex ConnectionStringValidValueRegex = new Regex("^[^\u0000]*$", RegexOptions.Compiled); // value not allowed to contain embedded null
 #endif
-        private static readonly Regex ConnectionStringValidKeyRegex = new Regex("^(?![;\\s])[^\\p{Cc}]+(?<!\\s)$", RegexOptions.Compiled);// key not allowed to start with semi-colon or space or contain non-visible characters or end with space
+        private static readonly Regex ConnectionStringValidKeyRegex = new Regex("^(?![;\\s])[^\\p{Cc}]+(?<!\\s)$", RegexOptions.Compiled); // key not allowed to start with semi-colon or space or contain non-visible characters or end with space
 
         internal const string DataDirectory = "|datadirectory|";
 
index a505a43..1359e81 100644 (file)
@@ -1337,7 +1337,7 @@ namespace System.Data.OleDb
                 DisposeOpenResults();
                 _hasRows = false;
 
-                for (; ; )
+                while (true)
                 {
                     Debug.Assert(null == _irow, "NextResult: row loop check");
                     Debug.Assert(null == _irowset, "NextResult: rowset loop check");
index 836f1d7..d0a8669 100644 (file)
@@ -594,7 +594,7 @@ namespace System.Data.ProviderBase
             // new stack to old stack.
             if (_waitHandles.PoolSemaphore.WaitOne(0, false) /* != WAIT_TIMEOUT */)
             {
-                for (; ; )
+                while (true)
                 {
                     DbConnectionInternal obj;
 
index 7e56c2e..99bd083 100644 (file)
@@ -81,7 +81,7 @@ namespace Microsoft.SqlServer.Server
             }
             else
             {
-                Debug.Assert(null == _warnings || 0 != _warnings.Count, "empty warning collection?");// must be something in the collection
+                Debug.Assert(null == _warnings || 0 != _warnings.Count, "empty warning collection?"); // must be something in the collection
 
                 if (!ignoreWarnings)
                 {
index 6946ac1..33bbfc5 100644 (file)
@@ -88,28 +88,28 @@ namespace Microsoft.SqlServer.Server
         internal static readonly SmiMetaData DefaultBigInt = new SmiMetaData(SqlDbType.BigInt, 8, 19, 0, SqlCompareOptions.None);     // SqlDbType.BigInt
         internal static readonly SmiMetaData DefaultBinary = new SmiMetaData(SqlDbType.Binary, 1, 0, 0, SqlCompareOptions.None);     // SqlDbType.Binary
         internal static readonly SmiMetaData DefaultBit = new SmiMetaData(SqlDbType.Bit, 1, 1, 0, SqlCompareOptions.None);     // SqlDbType.Bit
-        internal static readonly SmiMetaData DefaultChar_NoCollation = new SmiMetaData(SqlDbType.Char, 1, 0, 0, DefaultStringCompareOptions);// SqlDbType.Char
+        internal static readonly SmiMetaData DefaultChar_NoCollation = new SmiMetaData(SqlDbType.Char, 1, 0, 0, DefaultStringCompareOptions); // SqlDbType.Char
         internal static readonly SmiMetaData DefaultDateTime = new SmiMetaData(SqlDbType.DateTime, 8, 23, 3, SqlCompareOptions.None);     // SqlDbType.DateTime
         internal static readonly SmiMetaData DefaultDecimal = new SmiMetaData(SqlDbType.Decimal, 9, 18, 0, SqlCompareOptions.None);     // SqlDbType.Decimal
         internal static readonly SmiMetaData DefaultFloat = new SmiMetaData(SqlDbType.Float, 8, 53, 0, SqlCompareOptions.None);     // SqlDbType.Float
         internal static readonly SmiMetaData DefaultImage = new SmiMetaData(SqlDbType.Image, UnlimitedMaxLengthIndicator, 0, 0, SqlCompareOptions.None);     // SqlDbType.Image
         internal static readonly SmiMetaData DefaultInt = new SmiMetaData(SqlDbType.Int, 4, 10, 0, SqlCompareOptions.None);     // SqlDbType.Int
         internal static readonly SmiMetaData DefaultMoney = new SmiMetaData(SqlDbType.Money, 8, 19, 4, SqlCompareOptions.None);     // SqlDbType.Money
-        internal static readonly SmiMetaData DefaultNChar_NoCollation = new SmiMetaData(SqlDbType.NChar, 1, 0, 0, DefaultStringCompareOptions);// SqlDbType.NChar
-        internal static readonly SmiMetaData DefaultNText_NoCollation = new SmiMetaData(SqlDbType.NText, UnlimitedMaxLengthIndicator, 0, 0, DefaultStringCompareOptions);// SqlDbType.NText
-        internal static readonly SmiMetaData DefaultNVarChar_NoCollation = new SmiMetaData(SqlDbType.NVarChar, MaxUnicodeCharacters, 0, 0, DefaultStringCompareOptions);// SqlDbType.NVarChar
+        internal static readonly SmiMetaData DefaultNChar_NoCollation = new SmiMetaData(SqlDbType.NChar, 1, 0, 0, DefaultStringCompareOptions); // SqlDbType.NChar
+        internal static readonly SmiMetaData DefaultNText_NoCollation = new SmiMetaData(SqlDbType.NText, UnlimitedMaxLengthIndicator, 0, 0, DefaultStringCompareOptions); // SqlDbType.NText
+        internal static readonly SmiMetaData DefaultNVarChar_NoCollation = new SmiMetaData(SqlDbType.NVarChar, MaxUnicodeCharacters, 0, 0, DefaultStringCompareOptions); // SqlDbType.NVarChar
         internal static readonly SmiMetaData DefaultReal = new SmiMetaData(SqlDbType.Real, 4, 24, 0, SqlCompareOptions.None);     // SqlDbType.Real
         internal static readonly SmiMetaData DefaultUniqueIdentifier = new SmiMetaData(SqlDbType.UniqueIdentifier, 16, 0, 0, SqlCompareOptions.None);     // SqlDbType.UniqueIdentifier
         internal static readonly SmiMetaData DefaultSmallDateTime = new SmiMetaData(SqlDbType.SmallDateTime, 4, 16, 0, SqlCompareOptions.None);     // SqlDbType.SmallDateTime
         internal static readonly SmiMetaData DefaultSmallInt = new SmiMetaData(SqlDbType.SmallInt, 2, 5, 0, SqlCompareOptions.None);     // SqlDbType.SmallInt
         internal static readonly SmiMetaData DefaultSmallMoney = new SmiMetaData(SqlDbType.SmallMoney, 4, 10, 4, SqlCompareOptions.None);     // SqlDbType.SmallMoney
-        internal static readonly SmiMetaData DefaultText_NoCollation = new SmiMetaData(SqlDbType.Text, UnlimitedMaxLengthIndicator, 0, 0, DefaultStringCompareOptions);// SqlDbType.Text
+        internal static readonly SmiMetaData DefaultText_NoCollation = new SmiMetaData(SqlDbType.Text, UnlimitedMaxLengthIndicator, 0, 0, DefaultStringCompareOptions); // SqlDbType.Text
         internal static readonly SmiMetaData DefaultTimestamp = new SmiMetaData(SqlDbType.Timestamp, 8, 0, 0, SqlCompareOptions.None);     // SqlDbType.Timestamp
         internal static readonly SmiMetaData DefaultTinyInt = new SmiMetaData(SqlDbType.TinyInt, 1, 3, 0, SqlCompareOptions.None);     // SqlDbType.TinyInt
         internal static readonly SmiMetaData DefaultVarBinary = new SmiMetaData(SqlDbType.VarBinary, MaxBinaryLength, 0, 0, SqlCompareOptions.None);     // SqlDbType.VarBinary
-        internal static readonly SmiMetaData DefaultVarChar_NoCollation = new SmiMetaData(SqlDbType.VarChar, MaxANSICharacters, 0, 0, DefaultStringCompareOptions);// SqlDbType.VarChar
+        internal static readonly SmiMetaData DefaultVarChar_NoCollation = new SmiMetaData(SqlDbType.VarChar, MaxANSICharacters, 0, 0, DefaultStringCompareOptions); // SqlDbType.VarChar
         internal static readonly SmiMetaData DefaultVariant = new SmiMetaData(SqlDbType.Variant, 8016, 0, 0, SqlCompareOptions.None);     // SqlDbType.Variant
-        internal static readonly SmiMetaData DefaultXml = new SmiMetaData(SqlDbType.Xml, UnlimitedMaxLengthIndicator, 0, 0, DefaultStringCompareOptions);// SqlDbType.Xml
+        internal static readonly SmiMetaData DefaultXml = new SmiMetaData(SqlDbType.Xml, UnlimitedMaxLengthIndicator, 0, 0, DefaultStringCompareOptions); // SqlDbType.Xml
         internal static readonly SmiMetaData DefaultUdt_NoType = new SmiMetaData(SqlDbType.Udt, 0, 0, 0, SqlCompareOptions.None);     // SqlDbType.Udt
         internal static readonly SmiMetaData DefaultStructured = new SmiMetaData(SqlDbType.Structured, 0, 0, 0, SqlCompareOptions.None);     // SqlDbType.Structured
         internal static readonly SmiMetaData DefaultDate = new SmiMetaData(SqlDbType.Date, 3, 10, 0, SqlCompareOptions.None);     // SqlDbType.Date
index 0c7e5d9..876cec1 100644 (file)
@@ -604,7 +604,7 @@ namespace System.Data.ProviderBase
             // new stack to old stack.
             if (_waitHandles.PoolSemaphore.WaitOne(0))
             {
-                for (; ;)
+                while (true)
                 {
                     DbConnectionInternal obj;
 
index dd70021..b58bdd3 100644 (file)
@@ -52,8 +52,8 @@ namespace System.Data
         private static readonly object s_dllLock = new object();
 
 
-        private const uint const_LOCALDB_TRUNCATE_ERR_MESSAGE = 1;// flag for LocalDBFormatMessage that indicates that message can be truncated if it does not fit in the buffer
-        private const int const_ErrorMessageBufferSize = 1024;      // Buffer size for Local DB error message 1K will be enough for all messages
+        private const uint const_LOCALDB_TRUNCATE_ERR_MESSAGE = 1; // flag for LocalDBFormatMessage that indicates that message can be truncated if it does not fit in the buffer
+        private const int const_ErrorMessageBufferSize = 1024;     // Buffer size for Local DB error message 1K will be enough for all messages
 
 
         internal static string GetLocalDBMessage(int hrCode)
index 1360a12..be54c89 100644 (file)
@@ -7548,7 +7548,7 @@ namespace System.Data.SqlClient
                     {
                         WriteUnsignedLong(TdsEnums.SQL_PLP_NULL, stateObj); // PLP Null.
                     }
-                    return null;//continue; // End of UDT - continue to next parameter.
+                    return null; //continue; // End of UDT - continue to next parameter.
                 }
                 else if (mt.IsPlp)
                 {
index 81a8931..50b782c 100644 (file)
@@ -26,7 +26,7 @@ namespace System.Data.SqlClient
         private readonly TdsParserStateObject _stateObj;      // target to write to
         private readonly SmiMetaData _metaData;      // metadata describing value
         private readonly bool _isPlp;         // should this column be sent in PLP format?
-        private bool _plpUnknownSent;// did we send initial UNKNOWN_LENGTH marker?
+        private bool _plpUnknownSent; // did we send initial UNKNOWN_LENGTH marker?
         private Encoder _encoder;       // required for chunking character type data
         private SmiMetaData _variantType;   // required for sql_variant
 #if DEBUG
index 4f5a03c..2022b1a 100644 (file)
@@ -297,7 +297,7 @@ namespace System.Diagnostics
             public void Dispose()
             {
                 // TO keep this lock free and easy to analyze, the linked list is READ ONLY.   Thus we copy
-                for (; ; )
+                while (true)
                 {
                     DiagnosticSubscription subscriptions = Owner._subscriptions;
                     DiagnosticSubscription newSubscriptions = Remove(subscriptions, this);    // Make a new list, with myself removed.
index 4864bea..c00e350 100644 (file)
@@ -440,7 +440,7 @@ namespace System.Diagnostics
 
                 // Points just beyond the last point in the string that has yet to be parsed.   Thus we start with the whole string.
                 int endIdx = filterAndPayloadSpecs.Length;
-                for (;;)
+                while (true)
                 {
                     // Skip trailing whitespace.
                     while (0 < endIdx && char.IsWhiteSpace(filterAndPayloadSpecs[endIdx - 1]))
@@ -536,7 +536,7 @@ namespace System.Diagnostics
                 // Parse all the explicit transforms, if present
                 if (startTransformIdx < endIdx)
                 {
-                    for (;;)
+                    while (true)
                     {
                         int specStartIdx = startTransformIdx;
                         int semiColonIdx = filterAndPayloadSpec.LastIndexOf(';', endIdx - 1, endIdx - startTransformIdx);
index c220cc6..8d9e452 100644 (file)
@@ -901,7 +901,7 @@ namespace System.Diagnostics
             CategoryEntry* currentCategoryPointer = firstCategoryPointer;
             CategoryEntry* previousCategoryPointer = firstCategoryPointer;
 
-            for (; ; )
+            while (true)
             {
                 if (currentCategoryPointer->IsConsistent == 0)
                     Verify(currentCategoryPointer);
@@ -930,7 +930,7 @@ namespace System.Diagnostics
         {
             CounterEntry* currentCounterPointer = (CounterEntry*)(ResolveOffset(instancePointer->FirstCounterOffset, s_counterEntrySize));
             CounterEntry* previousCounterPointer = currentCounterPointer;
-            for (; ; )
+            while (true)
             {
                 if (currentCounterPointer->CounterNameHashCode == counterNameHashCode)
                 {
@@ -1006,7 +1006,7 @@ namespace System.Diagnostics
 
             try
             {
-                for (; ; )
+                while (true)
                 {
                     bool verifiedLifetimeOfThisInstance = false;
                     if (verifyLifeTime && (currentInstancePointer->RefCount != 0))
@@ -1116,7 +1116,7 @@ namespace System.Diagnostics
             // 2nd pass find a free instance slot
             InstanceEntry* currentInstancePointer = (InstanceEntry*)(ResolveOffset(categoryPointer->FirstInstanceOffset, s_instanceEntrySize));
             InstanceEntry* previousInstancePointer = currentInstancePointer;
-            for (; ; )
+            while (true)
             {
                 if (currentInstancePointer->RefCount == 0)
                 {
@@ -1404,7 +1404,7 @@ namespace System.Diagnostics
             try
             {
                 NetFrameworkUtils.EnterMutexWithoutGlobal(_categoryData.MutexName, ref mutex);
-                for (; ; )
+                while (true)
                 {
                     RemoveOneInstance(instancePointer, true);
 
index 80a72c8..3080a20 100644 (file)
@@ -79,7 +79,7 @@ namespace System.Diagnostics
                 IntPtr[] moduleHandles = new IntPtr[64];
                 GCHandle moduleHandlesArrayHandle = new GCHandle();
                 int moduleCount = 0;
-                for (;;)
+                while (true)
                 {
                     bool enumResult = false;
                     try
index 48b9df4..18d31b8 100644 (file)
@@ -280,7 +280,7 @@ namespace System.Diagnostics
         {
             int[] processIds = new int[256];
             int size;
-            for (; ; )
+            while (true)
             {
                 if (!Interop.Kernel32.EnumProcesses(processIds, processIds.Length * 4, out size))
                     throw new Win32Exception();
index 73d52dd..1fcfd4c 100644 (file)
@@ -259,7 +259,7 @@ namespace BasicEventSourceTests
         private static void Sleep(int minMSec)
         {
             var startTime = DateTime.UtcNow;
-            for (; ; )
+            while (true)
             {
                 DateTime endTime = DateTime.UtcNow;
                 double delta = (endTime - startTime).TotalMilliseconds;
index 05db925..62ef80c 100644 (file)
@@ -1941,7 +1941,7 @@ namespace System.DirectoryServices.ActiveDirectory
                 if (serverName.EndsWith("]"))
                 {
                     //[IPv6]
-                    serverName = serverName.Substring(1, serverName.Length - 2);//2 for []
+                    serverName = serverName.Substring(1, serverName.Length - 2); //2 for []
                     return serverName;
                 }
                 int closingBrace = serverName.LastIndexOf("]:");
index 281d1f0..6bc6cbe 100644 (file)
@@ -1391,8 +1391,8 @@ namespace System.Drawing
             // dealing with function *'s and what not - so we make explicit calls
             // to gdi+ after the fact, via the GdiplusNotificationHook and
             // GdiplusNotificationUnhook methods.
-            public IntPtr hook;//not used
-            public IntPtr unhook;//not used.
+            public IntPtr hook; //not used
+            public IntPtr unhook; //not used.
         }
     }
 }
index 59b5654..892bbde 100644 (file)
@@ -75,7 +75,7 @@ namespace System.Drawing.Internal
 
             // Loop invariant: everything to the left of "left" is a valid reference,
             // and anything to the right of "right" is broken.
-            for (;;)
+            while (true)
             {
                 while (left < length && list[left].Target != null)
                     left++;
index bba4cf9..505a0d2 100644 (file)
@@ -32,7 +32,7 @@ namespace System.Drawing
         [StructLayout(LayoutKind.Sequential)]
         internal struct BITMAPINFO_FLAT
         {
-            public int bmiHeader_biSize;// = Marshal.SizeOf(typeof(BITMAPINFOHEADER));
+            public int bmiHeader_biSize; // = Marshal.SizeOf(typeof(BITMAPINFOHEADER));
             public int bmiHeader_biWidth;
             public int bmiHeader_biHeight;
             public short bmiHeader_biPlanes;
index f2ed4fa..2780d94 100644 (file)
@@ -152,7 +152,7 @@ namespace System.Drawing.Printing
         private bool PrintLoop(PrintDocument document)
         {
             QueryPageSettingsEventArgs queryEvent = new QueryPageSettingsEventArgs((PageSettings)document.DefaultPageSettings.Clone());
-            for (;;)
+            while (true)
             {
                 document._OnQueryPageSettings(queryEvent);
                 if (queryEvent.Cancel)
@@ -194,7 +194,7 @@ namespace System.Drawing.Printing
             PrintPageEventArgs pageEvent = null;
             PageSettings documentPageSettings = (PageSettings)document.DefaultPageSettings.Clone();
             QueryPageSettingsEventArgs queryEvent = new QueryPageSettingsEventArgs(documentPageSettings);
-            for (;;)
+            while (true)
             {
                 queryEvent.PageSettingsChanged = false;
                 document._OnQueryPageSettings(queryEvent);
index 6c961bf..8a5ed38 100644 (file)
@@ -707,7 +707,7 @@ namespace System.IO
                 cancellationToken.ThrowIfCancellationRequested();
                 buffer = ArrayPool<char>.Shared.Rent(sr.CurrentEncoding.GetMaxCharCount(DefaultBufferSize));
                 StringBuilder sb = new StringBuilder();
-                for (;;)
+                while (true)
                 {
 #if MS_IO_REDIST
                     int read = await sr.ReadAsync(buffer, 0, buffer.Length).ConfigureAwait(false);
index a102acf..1d02d67 100644 (file)
@@ -213,7 +213,7 @@ namespace System.Dynamic
                 // left most node each iteration.
                 var stack = new Stack<BindingRestrictions>();
                 BindingRestrictions top = this;
-                for (;;)
+                while (true)
                 {
                     var m = top as MergedRestriction;
                     if (m != null)
@@ -370,7 +370,7 @@ namespace System.Dynamic
                     // left most node each iteration.
                     var stack = new Stack<BindingRestrictions>();
                     BindingRestrictions top = _node;
-                    for (;;)
+                    while (true)
                     {
                         var m = top as MergedRestriction;
                         if (m != null)
index 8f158b2..60b5067 100644 (file)
@@ -111,7 +111,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -257,7 +257,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -403,7 +403,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -549,7 +549,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2, arg3 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -695,7 +695,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2, arg3, arg4 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -841,7 +841,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2, arg3, arg4, arg5 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -987,7 +987,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2, arg3, arg4, arg5, arg6 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -1133,7 +1133,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -1279,7 +1279,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -1425,7 +1425,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -1570,7 +1570,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -1715,7 +1715,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -1860,7 +1860,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -2005,7 +2005,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2, arg3 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -2150,7 +2150,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2, arg3, arg4 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -2295,7 +2295,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2, arg3, arg4, arg5 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -2440,7 +2440,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2, arg3, arg4, arg5, arg6 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -2585,7 +2585,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -2730,7 +2730,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
@@ -2875,7 +2875,7 @@ namespace System.Dynamic
             rule = null;
             var args = new object[] { arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9 };
 
-            for (; ; )
+            while (true)
             {
                 @this.Target = originalRule;
                 rule = @this.Target = @this.Binder.BindCore(@this, args);
index 72ba219..2857243 100644 (file)
@@ -296,7 +296,7 @@ namespace System.Dynamic.Utils
             // This method catches the cases that were incorrectly disallowed, but when it needs to
             // examine possible conversions of element or type parameters it applies stricter rules.
 
-            for (;;)
+            while (true)
             {
                 if (!skipNonArray) // Skip if we just came from HasReferenceConversionTo and have just tested these
                 {
index f2f8d7f..cab97eb 100644 (file)
@@ -529,7 +529,7 @@ namespace System.Linq.Expressions.Compiler
 
         private void EmitSwitchBuckets(SwitchInfo info, List<List<SwitchLabel>> buckets, int first, int last)
         {
-            for (;;)
+            while (true)
             {
                 if (first == last)
                 {
index 44df241..e2b091a 100644 (file)
@@ -170,7 +170,7 @@ namespace System.Dynamic.Tests
             Assert.Equal(ExpressionType.AndAlso, vExp.NodeType);
 
             Stack<Expression> toSplit = new Stack<Expression>();
-            for (;;)
+            while (true)
             {
                 if (vExp.NodeType == ExpressionType.AndAlso)
                 {
index b2f7c78..34bf64e 100644 (file)
@@ -491,7 +491,7 @@ namespace System.Linq.Expressions.Tests
 
         bool ParseOptionalCustomModsOrConstraint()
         {
-            for (;;)
+            while (true)
             {
                 if (pbCur >= pbEnd)
                     return true;
@@ -517,7 +517,7 @@ namespace System.Linq.Expressions.Tests
 
         bool ParseOptionalCustomMods()
         {
-            for (;;)
+            while (true)
             {
                 if (pbCur >= pbEnd)
                     return true;
index 0c60d9c..583b85c 100644 (file)
@@ -138,7 +138,7 @@ namespace System.Management
                 ppQualSet = null;
             else
                 ppQualSet = new IWbemQualifierSetFreeThreaded(pQualSet);
-            GC.KeepAlive ( this ) ;
+            GC.KeepAlive(this);
             return hResult;
         }
         public int Get_(string wszName, int lFlags, ref object pVal, ref int pType, ref int plFlavor)
@@ -160,7 +160,7 @@ namespace System.Management
                     pVal = DBNull.Value;
                 }
             }
-            GC.KeepAlive ( this ) ;
+            GC.KeepAlive(this);
             return hr;
         }
         public int Put_(string wszName, int lFlags, ref object pVal, int Type)
@@ -168,24 +168,24 @@ namespace System.Management
             if (pWbemClassObject == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.Put_f(5, pWbemClassObject, wszName, lFlags, ref pVal, Type);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int Delete_(string wszName)
         {
             if (pWbemClassObject == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.Delete_f(6, pWbemClassObject, wszName);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int GetNames_(string wszQualifierName, int lFlags, ref object pQualifierVal, out string[] pNames)
         {
             if (pWbemClassObject == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.GetNames_f(7, pWbemClassObject, wszQualifierName, lFlags, ref pQualifierVal, out pNames);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
 
         }
         public int BeginEnumeration_(int lEnumFlags)
@@ -193,8 +193,8 @@ namespace System.Management
             if (pWbemClassObject == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.BeginEnumeration_f(8, pWbemClassObject, lEnumFlags);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int Next_(int lFlags, ref string strName, ref object pVal, ref int pType, ref int plFlavor)
         {
@@ -203,16 +203,16 @@ namespace System.Management
             pVal = null;
             strName = null;
             int res = WmiNetUtilsHelper.Next_f(9, pWbemClassObject, lFlags, ref strName, ref pVal, ref pType, ref plFlavor);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int EndEnumeration_()
         {
             if (pWbemClassObject == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.EndEnumeration_f(10, pWbemClassObject);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int GetPropertyQualifierSet_(string wszProperty, out IWbemQualifierSetFreeThreaded ppQualSet)
         {
@@ -225,7 +225,7 @@ namespace System.Management
             else
                 ppQualSet = new IWbemQualifierSetFreeThreaded(pQualSet);
 
-            GC.KeepAlive ( this ) ;
+            GC.KeepAlive(this);
             return hResult;
         }
         public int Clone_(out IWbemClassObjectFreeThreaded ppCopy)
@@ -239,7 +239,7 @@ namespace System.Management
             else
                 ppCopy = new IWbemClassObjectFreeThreaded(pWbemClassObjectNew);
 
-            GC.KeepAlive ( this ) ;
+            GC.KeepAlive(this);
             return hResult;
         }
         public int GetObjectText_(int lFlags, out string pstrObjectText)
@@ -247,8 +247,8 @@ namespace System.Management
             if (pWbemClassObject == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.GetObjectText_f(13, pWbemClassObject, lFlags, out pstrObjectText);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int SpawnDerivedClass_(int lFlags, out IWbemClassObjectFreeThreaded ppNewClass)
         {
@@ -261,7 +261,7 @@ namespace System.Management
             else
                 ppNewClass = new IWbemClassObjectFreeThreaded(pWbemClassObjectNew);
 
-            GC.KeepAlive ( this ) ;
+            GC.KeepAlive(this);
             return hResult;
         }
         public int SpawnInstance_(int lFlags, out IWbemClassObjectFreeThreaded ppNewInstance)
@@ -275,7 +275,7 @@ namespace System.Management
             else
                 ppNewInstance = new IWbemClassObjectFreeThreaded(pWbemClassObjectNew);
 
-            GC.KeepAlive ( this ) ;
+            GC.KeepAlive(this);
             return hResult;
         }
         public int CompareTo_(int lFlags, IWbemClassObjectFreeThreaded pCompareTo)
@@ -283,24 +283,24 @@ namespace System.Management
             if (pWbemClassObject == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.CompareTo_f(16, pWbemClassObject, lFlags, pCompareTo.pWbemClassObject);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int GetPropertyOrigin_(string wszName, out string pstrClassName)
         {
             if (pWbemClassObject == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.GetPropertyOrigin_f(17, pWbemClassObject, wszName, out pstrClassName);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int InheritsFrom_(string strAncestor)
         {
             if (pWbemClassObject == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.InheritsFrom_f(18, pWbemClassObject, strAncestor);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int GetMethod_(string wszName, int lFlags, out IWbemClassObjectFreeThreaded ppInSignature, out IWbemClassObjectFreeThreaded ppOutSignature)
         {
@@ -320,7 +320,7 @@ namespace System.Management
                     ppOutSignature = new IWbemClassObjectFreeThreaded(pOutSignature);
             }
 
-            GC.KeepAlive ( this ) ;
+            GC.KeepAlive(this);
             return hResult;
         }
         public int PutMethod_(string wszName, int lFlags, IWbemClassObjectFreeThreaded pInSignature, IWbemClassObjectFreeThreaded pOutSignature)
@@ -328,24 +328,24 @@ namespace System.Management
             if (pWbemClassObject == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.PutMethod_f(20, pWbemClassObject, wszName, lFlags, pInSignature, pOutSignature);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int DeleteMethod_(string wszName)
         {
             if (pWbemClassObject == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.DeleteMethod_f(21, pWbemClassObject, wszName);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int BeginMethodEnumeration_(int lEnumFlags)
         {
             if (pWbemClassObject == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res =  WmiNetUtilsHelper.BeginMethodEnumeration_f(22, pWbemClassObject, lEnumFlags);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int NextMethod_(int lFlags, out string pstrName, out IWbemClassObjectFreeThreaded ppInSignature, out IWbemClassObjectFreeThreaded ppOutSignature)
         {
@@ -365,7 +365,7 @@ namespace System.Management
                 if (pOutSignature != IntPtr.Zero)
                     ppOutSignature = new IWbemClassObjectFreeThreaded(pOutSignature);
             }
-            GC.KeepAlive ( this ) ;
+            GC.KeepAlive(this);
             return hResult;
         }
         public int EndMethodEnumeration_()
@@ -373,8 +373,8 @@ namespace System.Management
             if (pWbemClassObject == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.EndMethodEnumeration_f(24, pWbemClassObject);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int GetMethodQualifierSet_(string wszMethod, out IWbemQualifierSetFreeThreaded ppQualSet)
         {
@@ -386,7 +386,7 @@ namespace System.Management
                 ppQualSet = null;
             else
                 ppQualSet = new IWbemQualifierSetFreeThreaded(pQualSet);
-            GC.KeepAlive ( this ) ;
+            GC.KeepAlive(this);
             return hResult;
         }
         public int GetMethodOrigin_(string wszMethodName, out string pstrClassName)
@@ -394,8 +394,8 @@ namespace System.Management
             if (pWbemClassObject == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.GetMethodOrigin_f(26, pWbemClassObject, wszMethodName, out pstrClassName);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
 
         private enum STATFLAG
@@ -435,7 +435,7 @@ namespace System.Management
 
         public void Dispose()
         {
-            Dispose_(false) ;
+            Dispose_(false);
         }
 
         private void Dispose_( bool finalization )
@@ -463,8 +463,8 @@ namespace System.Management
             if (pWbemQualifierSet == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.QualifierGet_f(3, pWbemQualifierSet, wszName, lFlags, ref pVal, ref plFlavor);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
 
         }
         public int Put_(string wszName, ref object pVal, int lFlavor)
@@ -472,48 +472,48 @@ namespace System.Management
             if (pWbemQualifierSet == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res =  WmiNetUtilsHelper.QualifierPut_f(4, pWbemQualifierSet, wszName, ref pVal, lFlavor);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int Delete_(string wszName)
         {
             if (pWbemQualifierSet == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.QualifierDelete_f(5, pWbemQualifierSet, wszName);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int GetNames_(int lFlags, out string[] pNames)
         {
             if (pWbemQualifierSet == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.QualifierGetNames_f(6, pWbemQualifierSet, lFlags, out pNames);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int BeginEnumeration_(int lFlags)
         {
             if (pWbemQualifierSet == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.QualifierBeginEnumeration_f(7, pWbemQualifierSet, lFlags);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int Next_(int lFlags, out string pstrName, out object pVal, out int plFlavor)
         {
             if (pWbemQualifierSet == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.QualifierNext_f(8, pWbemQualifierSet, lFlags, out pstrName, out pVal, out plFlavor);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
         public int EndEnumeration_()
         {
             if (pWbemQualifierSet == IntPtr.Zero)
                 throw new ObjectDisposedException(name);
             int res = WmiNetUtilsHelper.QualifierEndEnumeration_f(9, pWbemQualifierSet);
-            GC.KeepAlive ( this ) ;
-            return res ;
+            GC.KeepAlive(this);
+            return res;
         }
     }
 
@@ -1648,16 +1648,16 @@ namespace System.Management
     internal class ThreadDispatch
     {
         #region Private fields
-        private     Thread                                  thread ;
-        private     Exception                               exception ;                                 // Exception thrown from worker method (if any). Exposed as property.
-        private     ThreadWorkerMethodWithReturn            threadWorkerMethodWithReturn ;              // Delegate to be called for worker method with return value
-        private     ThreadWorkerMethodWithReturnAndParam    threadWorkerMethodWithReturnAndParam ;      // Delegate to be called for worker method with return value and parameter
-        private     ThreadWorkerMethod                      threadWorkerMethod ;                        // Delegate to be called for worker method
-        private     ThreadWorkerMethodWithParam             threadWorkerMethodWithParam ;               // Delegate to be called for worker method with parameter
-        private     object                                  threadReturn ;                              // Return data from worker method.
-        private     object                                  threadParams ;                              // Parameters to be passed to worker method
-        private     bool                                    backgroundThread ;                          // Is this a background thread?
-        private     ApartmentState                          apartmentType ;                             // Apartment type of thread
+        private     Thread                                  thread;
+        private     Exception                               exception;                                 // Exception thrown from worker method (if any). Exposed as property.
+        private     ThreadWorkerMethodWithReturn            threadWorkerMethodWithReturn;              // Delegate to be called for worker method with return value
+        private     ThreadWorkerMethodWithReturnAndParam    threadWorkerMethodWithReturnAndParam;      // Delegate to be called for worker method with return value and parameter
+        private     ThreadWorkerMethod                      threadWorkerMethod;                        // Delegate to be called for worker method
+        private     ThreadWorkerMethodWithParam             threadWorkerMethodWithParam;               // Delegate to be called for worker method with parameter
+        private     object                                  threadReturn;                              // Return data from worker method.
+        private     object                                  threadParams;                              // Parameters to be passed to worker method
+        private     bool                                    backgroundThread;                          // Is this a background thread?
+        private     ApartmentState                          apartmentType;                             // Apartment type of thread
         #endregion
 
         #region Properties
@@ -1669,7 +1669,7 @@ namespace System.Management
         {
             get
             {
-                return this.exception ;
+                return this.exception;
             }
         }
 
@@ -1680,11 +1680,11 @@ namespace System.Management
         {
             get
             {
-                return this.threadParams ;
+                return this.threadParams;
             }
             set
             {
-                this.threadParams = value ;
+                this.threadParams = value;
             }
         }
 
@@ -1695,11 +1695,11 @@ namespace System.Management
         {
             get
             {
-                return this.backgroundThread ;
+                return this.backgroundThread;
             }
             set
             {
-                this.backgroundThread = value ;
+                this.backgroundThread = value;
             }
         }
 
@@ -1710,7 +1710,7 @@ namespace System.Management
         {
             get
             {
-                return this.threadReturn ;
+                return this.threadReturn;
             }
         }
 
@@ -1722,11 +1722,11 @@ namespace System.Management
         {
             get
             {
-                return this.apartmentType ;
+                return this.apartmentType;
             }
             set
             {
-                this.apartmentType = value ;
+                this.apartmentType = value;
             }
         }
         #endregion
@@ -1735,22 +1735,22 @@ namespace System.Management
         /// <summary>
         /// Delegate declaration representing signature of worker method with return value.
         /// </summary>
-        public delegate object  ThreadWorkerMethodWithReturn (  ) ;
+        public delegate object  ThreadWorkerMethodWithReturn (  );
 
         /// <summary>
         /// Delegate declaration representing signature of worker method with return value and parameter.
         /// </summary>
-        public delegate object  ThreadWorkerMethodWithReturnAndParam ( object param ) ;
+        public delegate object  ThreadWorkerMethodWithReturnAndParam ( object param );
 
         /// <summary>
         /// Delegate declaration representing signature of worker method with no return value and no parameter
         /// </summary>
-        public delegate void    ThreadWorkerMethod (  ) ;
+        public delegate void    ThreadWorkerMethod (  );
 
         /// <summary>
         /// Delegate declaration representing signature of worker method with parameter.
         /// </summary>
-        public delegate void    ThreadWorkerMethodWithParam ( object param ) ;
+        public delegate void    ThreadWorkerMethodWithParam ( object param );
         #endregion
 
         #region Public methods
@@ -1764,7 +1764,7 @@ namespace System.Management
         /// <param name="workerMethod">Delegate to be called to perform the work</param>
         public ThreadDispatch ( ThreadWorkerMethodWithReturn workerMethod ) : this ( )
         {
-            InitializeThreadState ( null, workerMethod, ApartmentState.MTA, false ) ;
+            InitializeThreadState ( null, workerMethod, ApartmentState.MTA, false );
         }
 
         /// <summary>
@@ -1777,7 +1777,7 @@ namespace System.Management
         /// <param name="workerMethod">Delegate to be called to perform the work</param>
         public ThreadDispatch ( ThreadWorkerMethodWithReturnAndParam workerMethod ) : this ( )
         {
-            InitializeThreadState ( null, workerMethod, ApartmentState.MTA, false ) ;
+            InitializeThreadState ( null, workerMethod, ApartmentState.MTA, false );
         }
 
         /// <summary>
@@ -1790,7 +1790,7 @@ namespace System.Management
         /// <param name="workerMethod">Delegate to be called to perform the work</param>
         public ThreadDispatch ( ThreadWorkerMethodWithParam workerMethod ) : this ( )
         {
-            InitializeThreadState ( null, workerMethod, ApartmentState.MTA, false ) ;
+            InitializeThreadState ( null, workerMethod, ApartmentState.MTA, false );
         }
 
         /// <summary>
@@ -1803,7 +1803,7 @@ namespace System.Management
         /// <param name="workerMethod">Delegate to be called to perform the work</param>
         public ThreadDispatch ( ThreadWorkerMethod workerMethod ) : this ( )
         {
-            InitializeThreadState ( null, workerMethod, ApartmentState.MTA, false ) ;
+            InitializeThreadState ( null, workerMethod, ApartmentState.MTA, false );
         }
 
         /// <summary>
@@ -1812,11 +1812,11 @@ namespace System.Management
         /// </summary>
         public void Start ( )
         {
-            this.exception = null ;
-            DispatchThread ( ) ;
+            this.exception = null;
+            DispatchThread();
             if ( this.Exception != null )
             {
-                throw this.Exception ;
+                throw this.Exception;
             }
         }
         #endregion
@@ -1828,16 +1828,16 @@ namespace System.Management
         /// </summary>
         private ThreadDispatch ( )
         {
-            this.thread                                 = null ;
-            this.exception                              = null ;
-            this.threadParams                           = null ;
-            this.threadWorkerMethodWithReturn           = null ;
-            this.threadWorkerMethodWithReturnAndParam   = null ;
-            this.threadWorkerMethod                     = null ;
-            this.threadWorkerMethodWithParam            = null;
-            this.threadReturn                           = null ;
-            this.backgroundThread                       = false ;
-            this.apartmentType                          = ApartmentState.MTA ;
+            this.thread                               = null;
+            this.exception                            = null;
+            this.threadParams                         = null;
+            this.threadWorkerMethodWithReturn         = null;
+            this.threadWorkerMethodWithReturnAndParam = null;
+            this.threadWorkerMethod                   = null;
+            this.threadWorkerMethodWithParam          = null;
+            this.threadReturn                         = null;
+            this.backgroundThread                     = false;
+            this.apartmentType                        = ApartmentState.MTA;
         }
 
         /// <summary>
@@ -1849,11 +1849,11 @@ namespace System.Management
         /// <param name="background">Thread is created as a background or not</param>
         private void InitializeThreadState ( object threadParams, ThreadWorkerMethodWithReturn workerMethod, ApartmentState aptState, bool background )
         {
-            this.threadParams = threadParams ;
-            this.threadWorkerMethodWithReturn  = workerMethod ;
-            this.thread = new Thread ( new ThreadStart ( ThreadEntryPointMethodWithReturn ) ) ;
-            this.thread.SetApartmentState(aptState) ;
-            this.backgroundThread = background ;
+            this.threadParams = threadParams;
+            this.threadWorkerMethodWithReturn  = workerMethod;
+            this.thread = new Thread ( new ThreadStart ( ThreadEntryPointMethodWithReturn ) );
+            this.thread.SetApartmentState(aptState);
+            this.backgroundThread = background;
         }
 
         /// <summary>
@@ -1865,11 +1865,11 @@ namespace System.Management
         /// <param name="background">Thread is created as a background or not</param>
         private void InitializeThreadState ( object threadParams, ThreadWorkerMethodWithReturnAndParam workerMethod, ApartmentState aptState, bool background )
         {
-            this.threadParams = threadParams ;
-            this.threadWorkerMethodWithReturnAndParam = workerMethod ;
-            this.thread = new Thread ( new ThreadStart ( ThreadEntryPointMethodWithReturnAndParam ) ) ;
+            this.threadParams = threadParams;
+            this.threadWorkerMethodWithReturnAndParam = workerMethod;
+            this.thread = new Thread ( new ThreadStart ( ThreadEntryPointMethodWithReturnAndParam ) );
             this.thread.SetApartmentState(aptState);
-            this.backgroundThread = background ;
+            this.backgroundThread = background;
         }
 
         /// <summary>
@@ -1881,11 +1881,11 @@ namespace System.Management
         /// <param name="background">Thread is created as a background or not</param>
         private void InitializeThreadState ( object threadParams, ThreadWorkerMethod workerMethod, ApartmentState aptState, bool background )
         {
-            this.threadParams = threadParams ;
-            this.threadWorkerMethod  = workerMethod ;
-            this.thread = new Thread ( new ThreadStart ( ThreadEntryPoint ) ) ;
+            this.threadParams = threadParams;
+            this.threadWorkerMethod  = workerMethod;
+            this.thread = new Thread ( new ThreadStart ( ThreadEntryPoint ) );
             this.thread.SetApartmentState(aptState );
-            this.backgroundThread = background ;
+            this.backgroundThread = background;
         }
 
         /// <summary>
@@ -1897,11 +1897,11 @@ namespace System.Management
         /// <param name="background">Thread is created as a background or not</param>
         private void InitializeThreadState ( object threadParams, ThreadWorkerMethodWithParam workerMethod, ApartmentState aptState, bool background )
         {
-            this.threadParams = threadParams ;
-            this.threadWorkerMethodWithParam = workerMethod ;
-            this.thread = new Thread ( new ThreadStart ( ThreadEntryPointMethodWithParam ) ) ;
+            this.threadParams = threadParams;
+            this.threadWorkerMethodWithParam = workerMethod;
+            this.thread = new Thread ( new ThreadStart ( ThreadEntryPointMethodWithParam ) );
             this.thread.SetApartmentState( aptState );
-            this.backgroundThread = background ;
+            this.backgroundThread = background;
         }
 
 
@@ -1910,8 +1910,8 @@ namespace System.Management
         /// </summary>
         private void DispatchThread ( )
         {
-            this.thread.Start ( ) ;
-            this.thread.Join ( ) ;
+            this.thread.Start();
+            this.thread.Join();
         }
 
         /// <summary>
@@ -1923,11 +1923,11 @@ namespace System.Management
         {
             try
             {
-                this.threadWorkerMethod ( ) ;
+                this.threadWorkerMethod();
             }
-            catch ( Exception e )
+            catch (Exception e)
             {
-                this.exception = e ;
+                this.exception = e;
             }
         }
 
@@ -1941,11 +1941,11 @@ namespace System.Management
         {
             try
             {
-                this.threadWorkerMethodWithParam ( this.threadParams ) ;
+                this.threadWorkerMethodWithParam ( this.threadParams );
             }
-            catch ( Exception e )
+            catch (Exception e)
             {
-                this.exception = e ;
+                this.exception = e;
             }
         }
 
@@ -1959,11 +1959,11 @@ namespace System.Management
         {
             try
             {
-                this.threadReturn = this.threadWorkerMethodWithReturn ( ) ;
+                this.threadReturn = this.threadWorkerMethodWithReturn();
             }
-            catch ( Exception e )
+            catch (Exception e)
             {
-                this.exception = e ;
+                this.exception = e;
             }
         }
 
@@ -1977,11 +1977,11 @@ namespace System.Management
         {
             try
             {
-                this.threadReturn = this.threadWorkerMethodWithReturnAndParam ( this.threadParams) ;
+                this.threadReturn = this.threadWorkerMethodWithReturnAndParam(this.threadParams);
             }
-            catch ( Exception e )
+            catch (Exception e)
             {
-                this.exception = e ;
+                this.exception = e;
             }
         }
         #endregion
index 8048043..24b1530 100644 (file)
@@ -213,7 +213,7 @@ namespace System.Management
             }
         }
 
-        internal IWbemClassObjectFreeThreaded _wbemObject ;
+        internal IWbemClassObjectFreeThreaded _wbemObject;
 
         private PropertyDataCollection properties;
         private PropertyDataCollection systemProperties;
@@ -342,7 +342,7 @@ namespace System.Management
         {
             get
             {
-                Initialize ( true ) ;
+                Initialize ( true );
 
                 if (properties == null)
                     properties = new PropertyDataCollection(this, false);
@@ -364,7 +364,7 @@ namespace System.Management
         {
             get
             {
-                Initialize ( false ) ;
+                Initialize ( false );
 
                 if (systemProperties == null)
                     systemProperties = new PropertyDataCollection(this, true);
@@ -387,7 +387,7 @@ namespace System.Management
         {
             get
             {
-                Initialize ( true ) ;
+                Initialize ( true );
 
                 if (qualifiers == null)
                     qualifiers = new QualifierDataCollection(this);
@@ -479,7 +479,7 @@ namespace System.Management
             get { return GetPropertyValue(propertyName); }
             set
             {
-                Initialize ( true ) ;
+                Initialize ( true );
                 try
                 {
                     SetPropertyValue (propertyName, value);
index e775c90..5380fad 100644 (file)
@@ -382,7 +382,7 @@ namespace System.Management
         {
             get
             {
-                Initialize ( true ) ;
+                Initialize ( true );
 
                 if (methods == null)
                     methods = new MethodDataCollection(this);
@@ -585,7 +585,7 @@ namespace System.Management
             if ((null == Path) || (null == Path.Path) || (0 == Path.Path.Length))
                 throw new InvalidOperationException();
 
-            Initialize ( false ) ;
+            Initialize ( false );
 
             EnumerationOptions o = (null == options) ? new EnumerationOptions() : (EnumerationOptions)options.Clone();
 
@@ -682,7 +682,7 @@ namespace System.Management
             if (null == Path)
                 throw new InvalidOperationException();
 
-            Initialize ( false ) ;
+            Initialize ( false );
             IEnumWbemClassObject enumWbem = null;
 
             EnumerationOptions o = (null == options) ? new EnumerationOptions() : (EnumerationOptions)options.Clone();
@@ -743,7 +743,7 @@ namespace System.Management
             if (null == Path)
                 throw new InvalidOperationException();
 
-            Initialize ( false ) ;
+            Initialize ( false );
 
             EnumerationOptions o = (null == options) ? new EnumerationOptions() :
                                       (EnumerationOptions)options.Clone();
@@ -1032,7 +1032,7 @@ namespace System.Management
             if ((null == Path) || (null == Path.Path) || (0 == Path.Path.Length))
                 throw new InvalidOperationException();
 
-            Initialize ( false ) ;
+            Initialize ( false );
 
             IEnumWbemClassObject enumWbem = null;
 
@@ -1130,7 +1130,7 @@ namespace System.Management
             if ((null == Path) || (null == Path.Path) || (0 == Path.Path.Length))
                 throw new InvalidOperationException();
 
-            Initialize ( true ) ;
+            Initialize ( true );
 
             if (null == watcher)
                 throw new ArgumentNullException(nameof(watcher));
@@ -1241,7 +1241,7 @@ namespace System.Management
             if ((null == Path) || (null == Path.Path) || (0 == Path.Path.Length))
                 throw new InvalidOperationException();
 
-            Initialize ( false ) ;
+            Initialize ( false );
 
             IEnumWbemClassObject enumWbem = null;
 
@@ -1334,7 +1334,7 @@ namespace System.Management
                 throw new ArgumentNullException(nameof(watcher));
             else
             {
-                Initialize ( true ) ;
+                Initialize ( true );
 
                 EnumerationOptions o =
                         (null != options) ? (EnumerationOptions)options.Clone() : new EnumerationOptions();
index 313571d..3c5618f 100644 (file)
@@ -614,7 +614,7 @@ namespace System.Management
         private int status;
         private readonly bool isLocal;
 
-        public int Status {get {return status;} set {status=value;}}
+        public int Status {get {return status; } set {status=value; }}
 
         public SinkForEventQuery (ManagementEventWatcher eventWatcher,
             object context,
@@ -640,16 +640,16 @@ namespace System.Management
                 //
                 // Ensure we are able to trap exceptions from worker thread.
                 //
-                ThreadDispatch disp = new ThreadDispatch ( new ThreadDispatch.ThreadWorkerMethodWithParam ( HackToCreateStubInMTA ) ) ;
-                disp.Parameter = this ;
-                disp.Start ( ) ;
+                ThreadDispatch disp = new ThreadDispatch ( new ThreadDispatch.ThreadWorkerMethodWithParam ( HackToCreateStubInMTA ) );
+                disp.Parameter = this;
+                disp.Start ( );
             }
 
         }
 
         private void HackToCreateStubInMTA(object param)
         {
-            SinkForEventQuery obj = (SinkForEventQuery) param ;
+            SinkForEventQuery obj = (SinkForEventQuery) param;
             object dmuxStub = null;
             obj.Status = WmiNetUtilsHelper.GetDemultiplexedStub_f (obj, obj.isLocal, out dmuxStub);
             obj.stub = (IWbemObjectSink) dmuxStub;
index ccf9950..adf603d 100644 (file)
@@ -772,7 +772,7 @@ namespace System.Management
         {
             IWbemClassObjectFreeThreaded tempObj = null;
 
-            Initialize ( false ) ; // this may throw
+            Initialize ( false ); // this may throw
 
             if ((null == path) || (path.Path.Length==0))
                 throw new InvalidOperationException();
@@ -894,7 +894,7 @@ namespace System.Management
         /// </example>
         public void Get(ManagementOperationObserver watcher)
         {
-            Initialize ( false ) ;
+            Initialize ( false );
 
             if ((null == path) || (path.Path.Length==0))
                 throw new InvalidOperationException();
@@ -1035,7 +1035,7 @@ namespace System.Management
             if ((null == path) || (path.Path.Length==0))
                 throw new InvalidOperationException();
 
-            Initialize ( false ) ;
+            Initialize ( false );
 
             IEnumWbemClassObject enumWbem = null;
             EnumerationOptions o = (null != options) ? options : new EnumerationOptions();
@@ -1152,7 +1152,7 @@ namespace System.Management
             if ((null == path) || (path.Path.Length==0))
                 throw new InvalidOperationException();
 
-            Initialize ( true ) ;
+            Initialize ( true );
 
             if (null == watcher)
                 throw new ArgumentNullException(nameof(watcher));
@@ -1273,7 +1273,7 @@ namespace System.Management
             if ((null == path) || (path.Path.Length==0))
                 throw new InvalidOperationException();
 
-            Initialize ( false ) ;
+            Initialize ( false );
 
             IEnumWbemClassObject enumWbem = null;
             EnumerationOptions o =
@@ -1384,7 +1384,7 @@ namespace System.Management
                 throw new ArgumentNullException(nameof(watcher));
             else
             {
-                Initialize ( false ) ;
+                Initialize ( false );
 
                 // Ensure we switch off ReturnImmediately as this is invalid for async calls
                 EnumerationOptions o =
@@ -1464,7 +1464,7 @@ namespace System.Management
         public ManagementPath Put(PutOptions options)
         {
             ManagementPath newPath = null;
-            Initialize ( true ) ;
+            Initialize ( true );
             PutOptions o = (null != options) ? options : new PutOptions();
 
             IWbemServices wbemServices = scope.GetIWbemServices();
@@ -1627,7 +1627,7 @@ namespace System.Management
                 throw new ArgumentNullException(nameof(watcher));
             else
             {
-                Initialize ( false ) ;
+                Initialize ( false );
 
                 PutOptions o = (null == options) ?
                     new PutOptions() : (PutOptions)options.Clone();
@@ -1753,7 +1753,7 @@ namespace System.Management
         /// </returns>
         public ManagementPath CopyTo(ManagementPath path, PutOptions options)
         {
-            Initialize ( false ) ;
+            Initialize ( false );
 
             ManagementScope destinationScope = null;
 
@@ -1888,7 +1888,7 @@ namespace System.Management
                 throw new ArgumentNullException(nameof(watcher));
             else
             {
-                Initialize ( false ) ;
+                Initialize ( false );
                 ManagementScope destinationScope = null;
 
                 destinationScope = new ManagementScope(path, scope);
@@ -1965,7 +1965,7 @@ namespace System.Management
             if ((null == path) || (path.Path.Length==0))
                 throw new InvalidOperationException();
 
-            Initialize ( false ) ;
+            Initialize ( false );
             DeleteOptions o = (null != options) ? options : new DeleteOptions();
             IWbemServices wbemServices = scope.GetIWbemServices();
 
@@ -2032,7 +2032,7 @@ namespace System.Management
                 throw new ArgumentNullException(nameof(watcher));
             else
             {
-                Initialize ( false ) ;
+                Initialize ( false );
                 DeleteOptions o = (null != options) ? (DeleteOptions) options.Clone() : new DeleteOptions();
 
                 // If someone has registered for progress, make sure we flag it
@@ -2156,7 +2156,7 @@ namespace System.Management
                 throw new ArgumentNullException(nameof(methodName));
             else
             {
-                Initialize ( false ) ;
+                Initialize ( false );
 
                 // Map args into a inparams structure
                 ManagementBaseObject inParameters;
@@ -2203,7 +2203,7 @@ namespace System.Management
                 throw new ArgumentNullException(nameof(methodName));
             else
             {
-                Initialize ( false ) ;
+                Initialize ( false );
 
                 // Map args into a inparams structure
                 ManagementBaseObject inParameters;
@@ -2302,7 +2302,7 @@ namespace System.Management
                 throw new ArgumentNullException(nameof(methodName));
             else
             {
-                Initialize ( false ) ;
+                Initialize ( false );
                 InvokeMethodOptions o = (null != options) ? options : new InvokeMethodOptions();
                 IWbemServices wbemServices = scope.GetIWbemServices();
 
@@ -2372,7 +2372,7 @@ namespace System.Management
                 throw new ArgumentNullException(nameof(methodName));
             else
             {
-                Initialize ( false ) ;
+                Initialize ( false );
                 InvokeMethodOptions o = (null != options) ?
                     (InvokeMethodOptions) options.Clone() : new InvokeMethodOptions();
 
@@ -2454,7 +2454,7 @@ namespace System.Management
                 throw new ArgumentNullException(nameof(methodName));
             else
             {
-                Initialize ( false ) ;
+                Initialize ( false );
 
                 // Do we have the class?
                 if (null == wmiClass)
index caafa9d..b6a5967 100644 (file)
@@ -102,7 +102,7 @@ namespace System.Management
         {
             if (!isDisposed)
             {
-                Dispose ( true ) ;
+                Dispose ( true );
             }
         }
 
@@ -145,12 +145,12 @@ namespace System.Management
                 //
                 int count = 0;
 
-                IEnumerator enumCol = this.GetEnumerator ( ) ;
+                IEnumerator enumCol = this.GetEnumerator ( );
                 while ( enumCol.MoveNext() == true )
                 {
-                    count++ ;
+                    count++;
                 }
-                return count ;
+                return count;
             }
         }
 
index a3bec52..834cad1 100644 (file)
@@ -427,7 +427,7 @@ namespace System.Management
             { return (((Flags & (int)tag_WBEM_GENERIC_FLAG_TYPE.WBEM_FLAG_ENSURE_LOCATABLE) != 0) ? true : false); }
             set
             { Flags = (value == true) ? (Flags | (int)tag_WBEM_GENERIC_FLAG_TYPE.WBEM_FLAG_ENSURE_LOCATABLE) :
-                      (Flags & (int)~tag_WBEM_GENERIC_FLAG_TYPE.WBEM_FLAG_ENSURE_LOCATABLE) ; }
+                      (Flags & (int)~tag_WBEM_GENERIC_FLAG_TYPE.WBEM_FLAG_ENSURE_LOCATABLE); }
         }
 
 
@@ -448,7 +448,7 @@ namespace System.Management
             { return (((Flags & (int)tag_WBEM_QUERY_FLAG_TYPE.WBEM_FLAG_PROTOTYPE) != 0) ? true : false); }
             set
             { Flags = (value == true) ? (Flags | (int)tag_WBEM_QUERY_FLAG_TYPE.WBEM_FLAG_PROTOTYPE) :
-                      (Flags & (int)~tag_WBEM_QUERY_FLAG_TYPE.WBEM_FLAG_PROTOTYPE) ; }
+                      (Flags & (int)~tag_WBEM_QUERY_FLAG_TYPE.WBEM_FLAG_PROTOTYPE); }
         }
 
         /// <summary>
@@ -467,7 +467,7 @@ namespace System.Management
             { return (((Flags & (int)tag_WBEM_GENERIC_FLAG_TYPE.WBEM_FLAG_DIRECT_READ) != 0) ? true : false); }
             set
             { Flags = (value == true) ? (Flags | (int)tag_WBEM_GENERIC_FLAG_TYPE.WBEM_FLAG_DIRECT_READ) :
-                      (Flags & (int)~tag_WBEM_GENERIC_FLAG_TYPE.WBEM_FLAG_DIRECT_READ) ; }
+                      (Flags & (int)~tag_WBEM_GENERIC_FLAG_TYPE.WBEM_FLAG_DIRECT_READ); }
         }
 
 
@@ -1330,7 +1330,7 @@ namespace System.Management
                     if (securePassword == null)
                     {
                         securePassword = new SecureString();
-                        for ( int i=0; i <value.Length;i++)
+                        for ( int i=0; i <value.Length; i++)
                         {
                             securePassword.AppendChar(value[i]);
                         }
@@ -1338,7 +1338,7 @@ namespace System.Management
                     else
                     {
                         SecureString tempStr = new SecureString();
-                        for ( int i=0; i <value.Length;i++)
+                        for ( int i=0; i <value.Length; i++)
                         {
                             tempStr.AppendChar(value[i]);
                         }
@@ -1561,7 +1561,7 @@ namespace System.Management
             if (password != null)
             {
                 this.securePassword = new SecureString();
-                for ( int i=0; i <password.Length;i++)
+                for ( int i=0; i <password.Length; i++)
                 {
                     securePassword.AppendChar(password[i]);
                 }
index 05c7840..42d81a1 100644 (file)
@@ -249,7 +249,7 @@ namespace System.Management
 
         private IWbemPath CreateWbemPath(string path)
         {
-            IWbemPath wbemPath = (IWbemPath)MTAHelper.CreateInMTA(typeof(WbemDefPath));//new WbemDefPath();
+            IWbemPath wbemPath = (IWbemPath)MTAHelper.CreateInMTA(typeof(WbemDefPath)); //new WbemDefPath();
             SetWbemPath(wbemPath, path);
             return wbemPath;
         }
@@ -388,7 +388,7 @@ namespace System.Management
         {
             get
             {
-                return (Path.Length == 0 ) ;
+                return (Path.Length == 0 );
             }
         }
 
@@ -638,7 +638,7 @@ namespace System.Management
                 if (0 != string.Compare(oldValue, value, StringComparison.OrdinalIgnoreCase))
                 {
                     if (null == wmiPath)
-                        wmiPath = (IWbemPath)MTAHelper.CreateInMTA(typeof(WbemDefPath));//new WbemDefPath ();
+                        wmiPath = (IWbemPath)MTAHelper.CreateInMTA(typeof(WbemDefPath)); //new WbemDefPath ();
                     else if (isWbemPathShared)
                     {
                         // Check if this IWbemPath is shared among multiple managed objects.
@@ -727,7 +727,7 @@ namespace System.Management
                     }
                 }
             }
-            else {;}    // Continue on. Could have different server name, same ns specified.
+            else {; }    // Continue on. Could have different server name, same ns specified.
 
             //
             // Update Server property if specified in the namespace.
@@ -928,7 +928,7 @@ namespace System.Management
                 int status = (int)ManagementStatus.NoError;
 
                 if (wmiPath == null)
-                    wmiPath = (IWbemPath)MTAHelper.CreateInMTA(typeof(WbemDefPath));//new WbemDefPath();
+                    wmiPath = (IWbemPath)MTAHelper.CreateInMTA(typeof(WbemDefPath)); //new WbemDefPath();
                 else if (isWbemPathShared)
                 {
                     // Check if this IWbemPath is shared among multiple managed objects.
index 21790fb..55b327f 100644 (file)
@@ -75,7 +75,7 @@ namespace System.Management
         /// </value>
         public virtual string QueryString
         {
-            get {return (null != queryString) ? queryString : string.Empty;}
+            get {return (null != queryString) ? queryString : string.Empty; }
             set {
                 if (queryString != value) {
                     ParseQuery (value); // this may throw
@@ -95,7 +95,7 @@ namespace System.Management
         /// </value>
         public virtual string QueryLanguage
         {
-            get {return (null != queryLanguage) ? queryLanguage : string.Empty;}
+            get {return (null != queryLanguage) ? queryLanguage : string.Empty; }
             set {
                 if (queryLanguage != value) {
                     queryLanguage = value;
@@ -538,7 +538,7 @@ namespace System.Management
         public override string QueryLanguage
         {
             get
-            {return base.QueryLanguage;}
+            {return base.QueryLanguage; }
         }
 
         //ICloneable
@@ -782,7 +782,7 @@ namespace System.Management
                 // We need to force a rebuild as we may not have detected
                 // a change to selected properties
                 BuildQuery ();
-                return base.QueryString;}
+                return base.QueryString; }
             set {
                 base.QueryString = value;
             }
@@ -2699,7 +2699,7 @@ namespace System.Management
         public override string QueryLanguage
         {
             get
-            {return base.QueryLanguage;}
+            {return base.QueryLanguage; }
         }
 
         /// <summary>
index 1d4eea1..bc7bcd2 100644 (file)
@@ -957,9 +957,9 @@ namespace System.Management
                             //
                             // Ensure we are able to trap exceptions from worker thread.
                             //
-                            ThreadDispatch disp = new ThreadDispatch ( new ThreadDispatch.ThreadWorkerMethodWithParam ( InitializeGuts ) ) ;
-                            disp.Parameter = this ;
-                            disp.Start ( ) ;
+                            ThreadDispatch disp = new ThreadDispatch ( new ThreadDispatch.ThreadWorkerMethodWithParam ( InitializeGuts ) );
+                            disp.Parameter = this;
+                            disp.Start ( );
                         }
                         else
                             InitializeGuts(this);
@@ -970,7 +970,7 @@ namespace System.Management
 
         private void InitializeGuts(object o)
         {
-            ManagementScope threadParam = (ManagementScope) o ;
+            ManagementScope threadParam = (ManagementScope) o;
             IWbemLocator loc = (IWbemLocator) new WbemLocator();
             IntPtr punk = IntPtr.Zero;
 
index a2eb4f3..cf34ccb 100644 (file)
@@ -191,7 +191,7 @@ namespace System.Management
         {
             get {
                 RefreshPropertyInfo();
-                return ((propertyFlavor & (int)tag_WBEM_FLAVOR_TYPE.WBEM_FLAVOR_ORIGIN_PROPAGATED) != 0) ? false : true ; }
+                return ((propertyFlavor & (int)tag_WBEM_FLAVOR_TYPE.WBEM_FLAVOR_ORIGIN_PROPAGATED) != 0) ? false : true; }
         }
 
         /// <summary>
@@ -204,7 +204,7 @@ namespace System.Management
         {
             get {
                 RefreshPropertyInfo();
-                return ((propertyType & (int)tag_CIMTYPE_ENUMERATION.CIM_FLAG_ARRAY) != 0);}
+                return ((propertyType & (int)tag_CIMTYPE_ENUMERATION.CIM_FLAG_ARRAY) != 0); }
         }
 
         /// <summary>
index 799ebc1..dd0b5ce 100644 (file)
@@ -560,7 +560,7 @@ namespace System.Management
                     bool bStart = false;
                     int Len = OriginalNamespace.Length;
                     OriginalNamespace = string.Empty;
-                    for (int i = 2 ; i < Len ; i++)
+                    for (int i = 2; i < Len; i++)
                     {
                         if (bStart == true)
                         {
@@ -931,7 +931,7 @@ namespace System.Management
         {
             cmp = new CodeMemberProperty ();
             cmp.Name = propName;
-            cmp.Attributes = MemberAttributes.Public | MemberAttributes.Final ;
+            cmp.Attributes = MemberAttributes.Public | MemberAttributes.Final;
             cmp.Type = new CodeTypeReference(propType);
 
             caa = new CodeAttributeArgument();
@@ -1100,7 +1100,7 @@ namespace System.Management
             SysPropsClass.Members.Add(cctor);
 
             caa = new CodeAttributeArgument();
-            caa.Value = new CodeTypeOfExpression (typeof(System.ComponentModel.ExpandableObjectConverter)) ;
+            caa.Value = new CodeTypeOfExpression (typeof(System.ComponentModel.ExpandableObjectConverter));
             cad = new CodeAttributeDeclaration();
             cad.Name = PublicNamesUsed["TypeConverter"].ToString();
             cad.Arguments.Add(caa);
@@ -1124,7 +1124,7 @@ namespace System.Management
 
                 //Now we will have to find the occurrence of the first character and trim all the characters before that
                 strPropTemp = prop.Name.ToCharArray();
-                for (i=0;i < strPropTemp.Length;i++)
+                for (i=0; i < strPropTemp.Length; i++)
                 {
                     if (char.IsLetterOrDigit(strPropTemp[i]) == true)
                     {
@@ -1136,7 +1136,7 @@ namespace System.Management
                     i = 0;
                 }
                 strPropName = new char[strPropTemp.Length - i];
-                for (int j=i;j < strPropTemp.Length;j++)
+                for (int j=i; j < strPropTemp.Length; j++)
                 {
                     strPropName[j - i] = strPropTemp[j];
                 }
@@ -1155,7 +1155,7 @@ namespace System.Management
             //private WmiObject _privObject
             cf = new CodeMemberField();
             cf.Name = PrivateNamesUsed["LateBoundObject"].ToString();
-            cf.Attributes = MemberAttributes.Private | MemberAttributes.Final ;
+            cf.Attributes = MemberAttributes.Private | MemberAttributes.Final;
             cf.Type = new CodeTypeReference(PublicNamesUsed["BaseObjClass"].ToString());
             SysPropsClass.Members.Add(cf);
 
@@ -1179,7 +1179,7 @@ namespace System.Management
             string IsValidPropName = string.Empty;
             bool bDateIsTimeInterval = false;
 
-            for (int i=0;i< PublicProperties.Count;i++)
+            for (int i=0; i< PublicProperties.Count; i++)
             {
                 bDateIsTimeInterval = false;
                 PropertyData prop = classobj.Properties[PublicProperties.GetKey(i).ToString()];
@@ -1307,7 +1307,7 @@ namespace System.Management
 
                         // Adding TypeConverter Attribute
                         caa = new CodeAttributeArgument();
-                        caa.Value = new CodeTypeOfExpression (PrivateNamesUsed["ConverterClass"].ToString()) ;
+                        caa.Value = new CodeTypeOfExpression (PrivateNamesUsed["ConverterClass"].ToString());
                         cad = new CodeAttributeDeclaration();
                         cad.Name = PublicNamesUsed["TypeConverter"].ToString();
                         cad.Arguments.Add(caa);
@@ -1645,7 +1645,7 @@ namespace System.Management
                             if (q.Value != null)
                             {
                                 string [] strArray = (string [])q.Value;
-                                for (int i=0;i < strArray.Length ;i++)
+                                for (int i=0; i < strArray.Length; i++)
                                 {
                                     try
                                     {
@@ -1681,7 +1681,7 @@ namespace System.Management
                             {
                                 ArrayList arTemp = new ArrayList(5);
                                 string [] strArray = (string[])q.Value;
-                                for (int i=0;i < strArray.Length;i++)
+                                for (int i=0; i < strArray.Length; i++)
                                 {
                                     if (strArray[i].Length == 0)
                                     {
@@ -1713,7 +1713,7 @@ namespace System.Management
                             if (q.Value != null)
                             {
                                 string [] strArray = (string [])q.Value;
-                                for (int i=0;i < strArray.Length;i++)
+                                for (int i=0; i < strArray.Length; i++)
                                 {
                                     BitMap.Add(ConvertBitMapValueToInt32(strArray[i]));
                                 }
@@ -1743,7 +1743,7 @@ namespace System.Management
                             {
                                 ArrayList arTemp = new ArrayList(5);
                                 string [] strArray = (string [])q.Value;
-                                for (int i=0;i < strArray.Length;i++)
+                                for (int i=0; i < strArray.Length; i++)
                                 {
                                     if (strArray[i].Length == 0)
                                     {
@@ -2039,7 +2039,7 @@ namespace System.Management
             cmm.Attributes = MemberAttributes.Private | MemberAttributes.Static | MemberAttributes.Final;
             cmm.ReturnType = new CodeTypeReference("System.String");
 
-            for (int i=0; i < arrKeys.Count;i++)
+            for (int i=0; i < arrKeys.Count; i++)
             {
                 strType = ((CodeTypeReference)arrKeyType[i]).BaseType;
                 cmm.Parameters.Add(new CodeParameterDeclarationExpression(strType,
@@ -2059,7 +2059,7 @@ namespace System.Management
                 cmm.Statements.Add(new CodeVariableDeclarationStatement("System.String", strPathObject, new CodePrimitiveExpression(strPath)));
                 CodeMethodInvokeExpression cmietoAdd;
 
-                for (int i=0; i < arrKeys.Count;i++)
+                for (int i=0; i < arrKeys.Count; i++)
                 {
                     if (((CodeTypeReference)arrKeyType[i]).BaseType == "System.String")
                     {
@@ -2147,7 +2147,7 @@ namespace System.Management
                 cmieInit.Method.MethodName = PrivateNamesUsed["InitialObjectFunc"].ToString();
                 cmieInit.Method.TargetObject = new CodeThisReferenceExpression();
 
-                for (int i=0; i < arrKeys.Count;i++)
+                for (int i=0; i < arrKeys.Count; i++)
                 {
                     cpde = new CodeParameterDeclarationExpression();
                     cpde.Type = new CodeTypeReference(((CodeTypeReference)arrKeyType[i]).BaseType);
@@ -2172,7 +2172,7 @@ namespace System.Management
                 cmie.Method.TargetObject = new CodeTypeReferenceExpression(PrivateNamesUsed["GeneratedClassName"].ToString());
                 cmie.Method.MethodName = PublicNamesUsed["ConstructPathFunction"].ToString();
 
-                for (int i=0; i < arrKeys.Count;i++)
+                for (int i=0; i < arrKeys.Count; i++)
                 {
                     cmie.Parameters.Add(new CodeVariableReferenceExpression("key"+arrKeys[i]));
                 }
@@ -2206,7 +2206,7 @@ namespace System.Management
 
             if (arrKeyType.Count > 0)
             {
-                for (int i=0; i < arrKeys.Count;i++)
+                for (int i=0; i < arrKeys.Count; i++)
                 {
                     cpde = new CodeParameterDeclarationExpression();
                     cpde.Type = new CodeTypeReference(((CodeTypeReference)arrKeyType[i]).BaseType);
@@ -2233,7 +2233,7 @@ namespace System.Management
                 cmie.Method.TargetObject = new CodeTypeReferenceExpression(PrivateNamesUsed["GeneratedClassName"].ToString());
                 cmie.Method.MethodName = PublicNamesUsed["ConstructPathFunction"].ToString();
 
-                for (int i=0; i < arrKeys.Count;i++)
+                for (int i=0; i < arrKeys.Count; i++)
                 {
                     cmie.Parameters.Add(new CodeVariableReferenceExpression("key"+arrKeys[i]));
                 }
@@ -2789,7 +2789,7 @@ namespace System.Management
             ArrayList outParamsName = new ArrayList(5);
             ArrayList inoutParams = new ArrayList(5);
             ArrayList inoutParamsType = new ArrayList(5);
-            for (int k=0;k< PublicMethods.Count;k++)
+            for (int k=0; k< PublicMethods.Count; k++)
             {
 
                 bStatic = false;
@@ -2929,7 +2929,7 @@ namespace System.Management
                             }
 
                             //Find out whether it is a in/out Parameter
-                            for (int i=0; i < outParamsName.Count;i++)
+                            for (int i=0; i < outParamsName.Count; i++)
                             {
                                 if (string.Equals(prop.Name, outParamsName[i].ToString(), StringComparison.OrdinalIgnoreCase))
                                 {
@@ -3017,7 +3017,7 @@ namespace System.Management
                             }
 
                             bInOut = false;
-                            for (int i=0; i < inoutParams.Count;i++)
+                            for (int i=0; i < inoutParams.Count; i++)
                             {
                                 if (string.Equals(prop.Name, inoutParams[i].ToString(), StringComparison.OrdinalIgnoreCase))
                                 {
@@ -3167,7 +3167,7 @@ namespace System.Management
 
                 //Now for each in/out params generate the statement
                 //    <inoutParam> = outParams.Properties["<inoutParam>"];
-                for (int i=0;i < inoutParams.Count;i++)
+                for (int i=0; i < inoutParams.Count; i++)
                 {
                     cpre = new CodePropertyReferenceExpression(new CodeVariableReferenceExpression(strOutParams), "Properties");
                     cie = new CodeIndexerExpression(cpre, new CodePrimitiveExpression(inoutParams[i].ToString()));
@@ -3278,7 +3278,7 @@ namespace System.Management
         {
             cmm = new CodeMemberMethod();
 
-            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static ;
+            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static;
             cmm.Name = PublicNamesUsed["FilterFunction"].ToString();
             cmm.ReturnType = new CodeTypeReference(PrivateNamesUsed["CollectionClass"].ToString());
 
@@ -3308,7 +3308,7 @@ namespace System.Management
             string strCondition = "condition";
             cmm = new CodeMemberMethod();
 
-            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static ;
+            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static;
             cmm.Name = PublicNamesUsed["FilterFunction"].ToString();
             cmm.ReturnType = new CodeTypeReference(PrivateNamesUsed["CollectionClass"].ToString());
             cmm.Parameters.Add(new CodeParameterDeclarationExpression("System.String", strCondition));
@@ -3339,7 +3339,7 @@ namespace System.Management
             string strSelectedProperties = "selectedProperties";
             cmm = new CodeMemberMethod();
 
-            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static ;
+            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static;
             cmm.Name = PublicNamesUsed["FilterFunction"].ToString();
             cmm.ReturnType = new CodeTypeReference(PrivateNamesUsed["CollectionClass"].ToString());
             cmm.Parameters.Add(new CodeParameterDeclarationExpression("System.String []", strSelectedProperties));
@@ -3370,7 +3370,7 @@ namespace System.Management
             string strCondition = "condition";
             cmm = new CodeMemberMethod();
 
-            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static ;
+            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static;
             cmm.Name = PublicNamesUsed["FilterFunction"].ToString();
             cmm.ReturnType = new CodeTypeReference(PrivateNamesUsed["CollectionClass"].ToString());
             cmm.Parameters.Add(new CodeParameterDeclarationExpression("System.String", strCondition));
@@ -3417,7 +3417,7 @@ namespace System.Management
         {
             cmm = new CodeMemberMethod();
 
-            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static ;
+            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static;
             cmm.Name = PublicNamesUsed["FilterFunction"].ToString();
             cmm.ReturnType = new CodeTypeReference(PrivateNamesUsed["CollectionClass"].ToString());
             cmm.Parameters.Add(new CodeParameterDeclarationExpression(new CodeTypeReference(PublicNamesUsed["ScopeClass"].ToString()), PrivateNamesUsed["ScopeParam"].ToString()));
@@ -3528,7 +3528,7 @@ namespace System.Management
             string strCondition = "condition";
             cmm = new CodeMemberMethod();
 
-            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static ;
+            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static;
             cmm.Name = PublicNamesUsed["FilterFunction"].ToString();
             cmm.ReturnType = new CodeTypeReference(PrivateNamesUsed["CollectionClass"].ToString());
             cmm.Parameters.Add(new CodeParameterDeclarationExpression(new CodeTypeReference(PublicNamesUsed["ScopeClass"].ToString()), PrivateNamesUsed["ScopeParam"].ToString()));
@@ -3559,7 +3559,7 @@ namespace System.Management
             string strSelectedProperties = "selectedProperties";
             cmm = new CodeMemberMethod();
 
-            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static ;
+            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static;
             cmm.Name = PublicNamesUsed["FilterFunction"].ToString();
             cmm.ReturnType = new CodeTypeReference(PrivateNamesUsed["CollectionClass"].ToString());
             cmm.Parameters.Add(new CodeParameterDeclarationExpression(PublicNamesUsed["ScopeClass"].ToString(), PrivateNamesUsed["ScopeParam"].ToString()));
@@ -3600,7 +3600,7 @@ namespace System.Management
             string strObjectSearcher = "ObjectSearcher";
 
             cmm = new CodeMemberMethod();
-            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static ;
+            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static;
             cmm.Name = PublicNamesUsed["FilterFunction"].ToString();
             cmm.ReturnType = new CodeTypeReference(PrivateNamesUsed["CollectionClass"].ToString());
 
@@ -3699,7 +3699,7 @@ namespace System.Management
         {
             cf = new CodeMemberField();
             cf.Name = memberName;
-            cf.Attributes = MemberAttributes.Private | MemberAttributes.Final ;
+            cf.Attributes = MemberAttributes.Private | MemberAttributes.Final;
             if (isStatic == true)
             {
                 cf.Attributes = cf.Attributes | MemberAttributes.Static;
@@ -3751,14 +3751,14 @@ namespace System.Management
             */
             cf = new CodeMemberField();
             cf.Name = baseTypeMemberVariable;
-            cf.Attributes = MemberAttributes.Private | MemberAttributes.Final ;
+            cf.Attributes = MemberAttributes.Private | MemberAttributes.Final;
             cf.Type = new CodeTypeReference(PublicNamesUsed["TypeConverter"].ToString());
 
             CodeConvertorClass.Members.Add(cf);
 
             cf = new CodeMemberField();
             cf.Name = typeMemberVariable;
-            cf.Attributes = MemberAttributes.Private | MemberAttributes.Final ;
+            cf.Attributes = MemberAttributes.Private | MemberAttributes.Final;
             cf.Type = new CodeTypeReference(PublicNamesUsed["Type"].ToString());
 
             CodeConvertorClass.Members.Add(cf);
@@ -3771,7 +3771,7 @@ namespace System.Management
                 }
             */
             cctor = new CodeConstructor();
-            cctor.Attributes = MemberAttributes.Public ;
+            cctor.Attributes = MemberAttributes.Public;
             cpde = new CodeParameterDeclarationExpression();
             cpde.Name = baseTypeParam;
             cpde.Type = new CodeTypeReference("System.Type");
@@ -4247,7 +4247,7 @@ namespace System.Management
 
             ccc.BaseTypes.Add("System.Object");
             ccc.BaseTypes.Add("ICollection");
-            ccc.TypeAttributes =TypeAttributes.NestedPublic ;
+            ccc.TypeAttributes =TypeAttributes.NestedPublic;
 
             cf = new CodeMemberField();
             cf.Name = strObjectCollection;
@@ -4431,7 +4431,7 @@ namespace System.Management
             //private ManagementObjectCollection.ManagementObjectEnumerator ObjectEnumerator;
             cf = new CodeMemberField();
             cf.Name = strObjectEnumerator;
-            cf.Attributes = MemberAttributes.Private | MemberAttributes.Final ;
+            cf.Attributes = MemberAttributes.Private | MemberAttributes.Final;
             cf.Type = new CodeTypeReference(strManagementObjectCollectionType+"."+
                 strManagementObjectEnumeratorType);
             ecc.Members.Add(cf);
@@ -4738,7 +4738,7 @@ namespace System.Management
                 strToAdd = "l";
             }
 
-            for (int i=0;i < str.Length;i++)
+            for (int i=0; i < str.Length; i++)
             {
                 bAdd = true;
                 if (char.IsLetterOrDigit(arrString[i]) == false)
@@ -4778,7 +4778,7 @@ namespace System.Management
             string strToAdd = string.Empty;
             IFormatProvider formatProv = (IFormatProvider)CultureInfo.InvariantCulture.GetFormat(typeof(int));
 
-            for ( int i = 0 ; i < arrIn.Count ; i++)
+            for ( int i = 0; i < arrIn.Count; i++)
             {
                 strToAdd = arrIn[i].ToString();
                 strToAdd = ResolveCollision(strToAdd, true);
@@ -4842,7 +4842,7 @@ namespace System.Management
 
                     case CodeLanguage.CSharp:
                         strProvider = "C#.";
-                        cp= new CSharpCodeProvider() ;
+                        cp= new CSharpCodeProvider();
                         break;
 
                     case CodeLanguage.VJSharp:
@@ -5011,7 +5011,7 @@ namespace System.Management
                 strTemp = string.Empty;
                 char[] arrString = bitMap.ToCharArray();
                 int Len = bitMap.Length;
-                for (int i = 2 ; i < Len ; i++)
+                for (int i = 2; i < Len; i++)
                 {
                     strTemp = strTemp + arrString[i];
                 }
@@ -5317,7 +5317,7 @@ namespace System.Management
             string strRetVar = "strRet";
             cmp = new CodeMemberProperty ();
             cmp.Name = PublicNamesUsed["ClassNameProperty"].ToString();
-            cmp.Attributes = MemberAttributes.Public | MemberAttributes.Final ;
+            cmp.Attributes = MemberAttributes.Public | MemberAttributes.Final;
             cmp.Type = new CodeTypeReference("System.String");
 
             caa = new CodeAttributeArgument();
@@ -5403,7 +5403,7 @@ namespace System.Management
 
             cmm = new CodeMemberMethod ();
             cmm.Name = PrivateNamesUsed["ClassNameCheckFunc"].ToString();
-            cmm.Attributes = MemberAttributes.Private | MemberAttributes.Final ;
+            cmm.Attributes = MemberAttributes.Private | MemberAttributes.Final;
             cmm.ReturnType = new CodeTypeReference("System.Boolean");
 
             cmm.Parameters.Add(new CodeParameterDeclarationExpression(new CodeTypeReference(PublicNamesUsed["ScopeClass"].ToString()), PrivateNamesUsed["ScopeParam"].ToString()));
@@ -5475,7 +5475,7 @@ namespace System.Management
 
             cmm = new CodeMemberMethod ();
             cmm.Name = PrivateNamesUsed["ClassNameCheckFunc"].ToString();
-            cmm.Attributes = MemberAttributes.Private | MemberAttributes.Final ;
+            cmm.Attributes = MemberAttributes.Private | MemberAttributes.Final;
             cmm.ReturnType = new CodeTypeReference("System.Boolean");
 
             cmm.Parameters.Add(new CodeParameterDeclarationExpression(new CodeTypeReference(PublicNamesUsed["BaseObjClass"].ToString()), strTempObj));
@@ -6185,7 +6185,7 @@ namespace System.Management
             string strScope = "mgmtScope";
             string strPath = "mgmtPath";
 
-            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static ;
+            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final | MemberAttributes.Static;
             cmm.Name = PublicNamesUsed["CreateInst"].ToString();
             cmm.ReturnType = new CodeTypeReference(PrivateNamesUsed["GeneratedClassName"].ToString());
 
@@ -6265,7 +6265,7 @@ namespace System.Management
         {
             cmm = new CodeMemberMethod();
 
-            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final ;
+            cmm.Attributes = MemberAttributes.Public | MemberAttributes.Final;
             cmm.Name = PublicNamesUsed["DeleteInst"].ToString();
 
             caa = new CodeAttributeArgument();
index bb0ff75..aa90f04 100644 (file)
@@ -49,8 +49,8 @@ internal class WmiEventSink : IWmiEventSource
         //
         // Ensure we are able to trap exceptions from worker thread.
         //
-        ThreadDispatch disp = new ThreadDispatch ( new ThreadDispatch.ThreadWorkerMethod ( HackToCreateWmiEventSink ) ) ;
-        disp.Start ( ) ;
+        ThreadDispatch disp = new ThreadDispatch ( new ThreadDispatch.ThreadWorkerMethod ( HackToCreateWmiEventSink ) );
+        disp.Start ( );
 
         return wmiEventSinkNew;
     }
@@ -163,7 +163,7 @@ internal class WmiEventSink : IWmiEventSource
                 }
 
                 // Fire Completed event
-                CompletedEventArgs args2 = null ;
+                CompletedEventArgs args2 = null;
                 if ( errObj != null )
                     {
                         args2 = new CompletedEventArgs (context, hResult,
@@ -246,8 +246,8 @@ internal class WmiGetEventSink : WmiEventSink
         //
         // Ensure we are able to trap exceptions from worker thread.
         //
-        ThreadDispatch disp = new ThreadDispatch ( new ThreadDispatch.ThreadWorkerMethod ( HackToCreateWmiGetEventSink ) ) ;
-        disp.Start ( ) ;
+        ThreadDispatch disp = new ThreadDispatch ( new ThreadDispatch.ThreadWorkerMethod ( HackToCreateWmiGetEventSink ) );
+        disp.Start ( );
 
         return wmiGetEventSinkNew;
     }
index 59154c3..d5b0217 100644 (file)
@@ -96,9 +96,9 @@ namespace System.Net.Http
         private const string EnvNoProxyUC = "NO_PROXY";
         private const string EnvCGI = "GATEWAY_INTERFACE"; // Running in a CGI environment.
 
-        private readonly Uri _httpProxyUri;      // String URI for HTTP requests
-        private readonly Uri _httpsProxyUri;     // String URI for HTTPS requests
-        private readonly string[] _bypass = null;// list of domains not to proxy
+        private readonly Uri _httpProxyUri;       // String URI for HTTP requests
+        private readonly Uri _httpsProxyUri;      // String URI for HTTPS requests
+        private readonly string[] _bypass = null; // list of domains not to proxy
         private readonly ICredentials _credentials;
 
         private HttpEnvironmentProxy(Uri httpProxy, Uri httpsProxy, string bypassList)
index 3576c20..f091e8b 100644 (file)
@@ -577,9 +577,9 @@ namespace System.Net
                 uint size = 4096;
                 ulong requestId = 0;
                 memoryBlob = new SyncRequestContext((int)size);
-                for (;;)
+                while (true)
                 {
-                    for (;;)
+                    while (true)
                     {
                         if (NetEventSource.IsEnabled) NetEventSource.Info(this, $"Calling Interop.HttpApi.HttpReceiveHttpRequest RequestId: {requestId}");
                         uint bytesTransferred = 0;
index 497fa5b..0e0bdc8 100644 (file)
@@ -350,7 +350,7 @@ namespace System.Net
             if (offset + count > buffer.Length)
                 throw new ArgumentOutOfRangeException(nameof(count));
 
-            for (;;)
+            while (true)
             {
                 // read data from the underlying stream
                 int read = base.Read(buffer, offset, count);
@@ -392,7 +392,7 @@ namespace System.Net
 
             // do not append a space when writing from a stream since this means
             // it's writing the email body
-            for (;;)
+            while (true)
             {
                 written += EncodeBytes(buffer, offset + written, count - written, false, false);
                 if (written < count)
@@ -451,7 +451,7 @@ namespace System.Net
 
             internal void Read()
             {
-                for (;;)
+                while (true)
                 {
                     IAsyncResult result = _parent.BaseStream.BeginRead(_buffer, _offset, _count, s_onRead, this);
                     if (!result.CompletedSynchronously || CompleteRead(result))
@@ -512,7 +512,7 @@ namespace System.Net
 
             internal void Write()
             {
-                for (;;)
+                while (true)
                 {
                     // do not append a space when writing from a stream since this means
                     // it's writing the email body
index 6fcc186..d1699e1 100644 (file)
@@ -820,7 +820,7 @@ namespace System.Net.Mail
 
             private bool AuthenticateContinue()
             {
-                for (;;)
+                while (true)
                 {
                     // We don't need credential on the continued auth assuming they were captured on the first call.
                     // That should always work, otherwise what if a new credential has been returned?
index 4f011ba..1257173 100644 (file)
@@ -298,7 +298,7 @@ namespace System.Net.Mime
             }
 
             int written = 0;
-            for (;;)
+            while (true)
             {
                 written += EncodeBytes(buffer, offset + written, count - written);
                 if (written < count)
@@ -370,7 +370,7 @@ namespace System.Net.Mime
 
             internal void Write()
             {
-                for (;;)
+                while (true)
                 {
                     _written += _parent.EncodeBytes(_buffer, _offset + _written, _count - _written);
                     if (_written < _count)
index f4df531..dfc4e83 100644 (file)
@@ -347,7 +347,7 @@ namespace System.Net.Mime
             }
 
             int written = 0;
-            for (;;)
+            while (true)
             {
                 written += EncodeBytes(buffer, offset + written, count - written);
                 if (written < count)
@@ -416,7 +416,7 @@ namespace System.Net.Mime
 
             internal void Write()
             {
-                for (;;)
+                while (true)
                 {
                     _written += _parent.EncodeBytes(_buffer, _offset + _written, _count - _written);
                     if (_written < _count)
index 1c75c68..d39b712 100644 (file)
@@ -230,7 +230,7 @@ namespace System.Net.Sockets
             // Return pending and we will continue in the completion port callback.
             if (_singleBufferHandleState == SingleBufferHandleState.InProcess)
             {
-                RegisterToCancelPendingIO(overlapped, cancellationToken);// must happen before we change state to Set to avoid race conditions
+                RegisterToCancelPendingIO(overlapped, cancellationToken); // must happen before we change state to Set to avoid race conditions
                 _singleBufferHandle = _buffer.Pin();
                 _singleBufferHandleState = SingleBufferHandleState.Set;
             }
index f550dcc..b9392eb 100644 (file)
@@ -703,7 +703,7 @@ namespace System.Net.Sockets
         public static bool TryCompleteSendTo(SafeSocketHandle socket, ReadOnlySpan<byte> buffer, IList<ArraySegment<byte>> buffers, ref int bufferIndex, ref int offset, ref int count, SocketFlags flags, byte[] socketAddress, int socketAddressLen, ref int bytesSent, out SocketError errorCode)
         {
             bool successfulSend = false;
-            for (;;)
+            while (true)
             {
                 int sent;
                 Interop.Error errno;
@@ -748,7 +748,7 @@ namespace System.Net.Sockets
 
         public static bool TryCompleteSendFile(SafeSocketHandle socket, SafeFileHandle handle, ref long offset, ref long count, ref long bytesSent, out SocketError errorCode)
         {
-            for (;;)
+            while (true)
             {
                 long sent;
                 Interop.Error errno;
index a31f3e5..26371fc 100644 (file)
@@ -141,7 +141,7 @@ namespace System.Net.Sockets.Tests
                     using (remote)
                     {
                         var recvBuffer = new byte[256];
-                        for (; ; )
+                        while (true)
                         {
                             int received = remote.Receive(recvBuffer, 0, recvBuffer.Length, SocketFlags.None);
                             if (received == 0)
index 596c9a9..c1b59ef 100644 (file)
@@ -147,7 +147,7 @@ namespace System.Net.Sockets.Tests
                         if (!useMultipleBuffers)
                         {
                             var recvBuffer = new byte[256];
-                            for (; ; )
+                            while (true)
                             {
                                 int received = await ReceiveAsync(remote, new ArraySegment<byte>(recvBuffer));
                                 if (received == 0)
@@ -166,7 +166,7 @@ namespace System.Net.Sockets.Tests
                                 new ArraySegment<byte>(new byte[256], 2, 100),
                                 new ArraySegment<byte>(new byte[1], 0, 0),
                                 new ArraySegment<byte>(new byte[64], 9, 33)};
-                            for (; ; )
+                            while (true)
                             {
                                 int received = await ReceiveAsync(remote, recvBuffers);
                                 if (received == 0)
@@ -1488,7 +1488,7 @@ namespace System.Net.Sockets.Tests
                 using (NetworkStream stream = remote.GetStream())
                 {
                     var recvBuffer = new byte[256];
-                    for (; ; )
+                    while (true)
                     {
                         int received = await stream.ReadAsync(recvBuffer, 0, recvBuffer.Length);
                         if (received == 0)
index df924de..6d6238a 100644 (file)
@@ -2207,7 +2207,7 @@ namespace System.Runtime.Serialization
     internal class GenericNameProvider : IGenericNameProvider
     {
         private readonly string _genericTypeName;
-        private readonly object[] _genericParams;//Type or DataContract
+        private readonly object[] _genericParams; //Type or DataContract
         private readonly IList<int> _nestedParamCounts;
         internal GenericNameProvider(Type type)
             : this(DataContract.GetClrTypeFullName(type.GetGenericTypeDefinition()), type.GetGenericArguments())
index 7e45030..157cc9b 100644 (file)
@@ -614,7 +614,7 @@ namespace System.Runtime.Serialization
                 {
                     if (isNullableOfT)
                     {
-                        memberValue = UnwrapNullableObject(memberValue);//Leaves !HasValue on stack
+                        memberValue = UnwrapNullableObject(memberValue); //Leaves !HasValue on stack
                         memberType = memberValue.LocalType;
                     }
                     else
@@ -703,7 +703,7 @@ namespace System.Runtime.Serialization
                 _ilg.Pop();
                 _ilg.Call(XmlFormatGeneratorStatics.GetDefaultValueMethod.MakeGenericMethod(memberType));
                 _ilg.Stloc(memberValue);
-                _ilg.Load(true);//isNull
+                _ilg.Load(true); //isNull
                 _ilg.MarkLabel(end);
                 return memberValue;
             }
index 0c6a947..b6a6848 100644 (file)
@@ -4076,7 +4076,7 @@ namespace System
 
                 if (hasUnicode && iriParsing && hostNotUnicodeNormalized)
                 {
-                    flags |= Flags.HostUnicodeNormalized;// no host
+                    flags |= Flags.HostUnicodeNormalized; // no host
                 }
 
                 return idx;
index 6f5af38..6266939 100644 (file)
@@ -527,7 +527,7 @@ namespace System
                     == (Flags.SchemeNotCanonical | Flags.AuthorityFound))
                 {
                     idx = (ushort)_syntax.SchemeName.Length;
-                    while (str[idx++] != ':') ;
+                    while (str[idx++] != ':');
                     if (idx + 1 >= _string.Length || str[idx] != '/' || str[idx + 1] != '/')
                         return false;
                 }
index bc0609a..cbb5046 100644 (file)
@@ -668,7 +668,7 @@ namespace System
         internal const string RFC3986ReservedMarks = @";/?:@&=+$,#[]!'()*";
         private const string RFC2396ReservedMarks = @";/?:@&=+$,";
         private const string RFC3986UnreservedMarks = @"-_.~";
-        private const string AdditionalUnsafeToUnescape = @"%\#";// While not specified as reserved, these are still unsafe to unescape.
+        private const string AdditionalUnsafeToUnescape = @"%\#"; // While not specified as reserved, these are still unsafe to unescape.
 
         // When unescaping in safe mode, do not unescape the RFC 3986 reserved set:
         // gen-delims  = ":" / "/" / "?" / "#" / "[" / "]" / "@"
index 6d6be90..ad4dc5d 100644 (file)
@@ -199,7 +199,7 @@ namespace System.Xml
                                                                      //the decimal digits, from the
                                                                      //lowest significant to highest significant
 
-            int iDigits = 0;//Number of significant digits
+            int iDigits = 0; //Number of significant digits
             uint ulRem; //Remainder of a division by x_ulBase10, i.e.,least significant digit
 
             // Build the final numeric string by inserting the sign, reversing
index 9c4716f..84bf039 100644 (file)
@@ -2778,7 +2778,7 @@ namespace System.Xml
 
         private void FinishCDATA()
         {
-            for (;;)
+            while (true)
             {
                 switch (PeekToken())
                 {
@@ -3503,7 +3503,7 @@ namespace System.Xml
                 if (!attr)
                 {
                     // scan if this is whitespace
-                    for (;;)
+                    while (true)
                     {
                         int posNext = pos + 2;
                         if (posNext > end)
@@ -3514,10 +3514,10 @@ namespace System.Xml
                     }
                 }
 
-                for (;;)
+                while (true)
                 {
                     char ch;
-                    for (;;)
+                    while (true)
                     {
                         int posNext = pos + 2;
                         if (posNext > end)
index 5758194..f0499ce 100644 (file)
@@ -598,7 +598,7 @@ namespace System.Xml.XPath.DataBinding
             XPathStep[] steps = new XPathStep[stepCount];
             pos = 0;
             int i = 0;
-            for (;;) {
+            while (true) {
                 if (pos >= xpath.Length)
                     throw new XmlException(SR.XmlDataBinding_XPathEnd, (string[])null);
                 if ('/' != xpath[pos])
index 2259184..d25a52e 100644 (file)
@@ -564,7 +564,7 @@ namespace System.Xml
                 char* pDst = pDstBegin + bufPos;
 
                 char ch = (char)0;
-                for (;;)
+                while (true)
                 {
                     char* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -652,7 +652,7 @@ namespace System.Xml
                 char* pDst = pDstBegin + bufPos;
 
                 char ch = (char)0;
-                for (;;)
+                while (true)
                 {
                     char* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
index e753cc0..2ba8e9c 100644 (file)
@@ -541,7 +541,7 @@ namespace System.Xml
                 byte* pDst = pDstBegin + bufPos;
 
                 char ch = (char)0;
-                for (;;)
+                while (true)
                 {
                     byte* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -629,7 +629,7 @@ namespace System.Xml
                 byte* pDst = pDstBegin + bufPos;
 
                 char ch = (char)0;
-                for (;;)
+                while (true)
                 {
                     byte* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
index eb64761..cba84e3 100644 (file)
@@ -389,12 +389,12 @@ namespace System.Xml
             }
             _decoder.SetNextOutputBuffer(buffer, index, count);
 
-            for (;;)
+            while (true)
             {
                 // use streaming ReadValueChunk if the reader supports it
                 if (_canReadValueChunk)
                 {
-                    for (;;)
+                    while (true)
                     {
                         if (_valueOffset < _valueChunkLength)
                         {
index ef91ade..0ae58d6 100644 (file)
@@ -308,12 +308,12 @@ namespace System.Xml
             }
             _decoder.SetNextOutputBuffer(buffer, index, count);
 
-            for (;;)
+            while (true)
             {
                 // use streaming ReadValueChunk if the reader supports it
                 if (_canReadValueChunk)
                 {
-                    for (;;)
+                    while (true)
                     {
                         if (_valueOffset < _valueChunkLength)
                         {
index bfedff1..94a4cf1 100644 (file)
@@ -903,7 +903,7 @@ namespace System.Xml
                 char* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     char* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1026,7 +1026,7 @@ namespace System.Xml
                 char* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     char* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1157,7 +1157,7 @@ namespace System.Xml
                 char* pSrc = pSrcBegin;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     char* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1221,7 +1221,7 @@ namespace System.Xml
                 char* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     char* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1341,7 +1341,7 @@ namespace System.Xml
                 char* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     char* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1492,7 +1492,7 @@ namespace System.Xml
                 char* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     char* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1818,7 +1818,7 @@ namespace System.Xml
             fixed (char* pSrc = s)
             {
                 char* pS = pSrc;
-                while ((*pDst++ = (char)*pS++) != 0) ;
+                while ((*pDst++ = (char)*pS++) != 0);
             }
 
             pDst[-1] = (char)';';
index aae9271..4a8de8d 100644 (file)
@@ -670,7 +670,7 @@ namespace System.Xml
                 char* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     char* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -874,7 +874,7 @@ namespace System.Xml
                 char* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     char* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1114,7 +1114,7 @@ namespace System.Xml
                 char* pSrc = pSrcBegin;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     char* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1289,7 +1289,7 @@ namespace System.Xml
                 char* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     char* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1491,7 +1491,7 @@ namespace System.Xml
                     char* pDst = pDstBegin + bufPos;
 
                     int ch = 0;
-                    for (;;)
+                    while (true)
                     {
                         char* pDstEnd = pDst + (pSrcEnd - pSrc);
                         if (pDstEnd > pDstBegin + bufLen)
@@ -1681,7 +1681,7 @@ namespace System.Xml
                     char* pDst = pDstBegin + bufPos;
 
                     int ch = 0;
-                    for (;;)
+                    while (true)
                     {
                         char* pDstEnd = pDst + (pSrcEnd - pSrc);
                         if (pDstEnd > pDstBegin + bufLen)
index 023e32d..e7c99e1 100644 (file)
@@ -140,7 +140,7 @@ namespace System.Xml
             int endPos = offset + count;
             int i = offset;
             char ch = (char)0;
-            for (;;)
+            while (true)
             {
                 int startPos = i;
                 unsafe
@@ -270,7 +270,7 @@ namespace System.Xml
             int i = 0;
             int startPos = 0;
             char ch = (char)0;
-            for (;;)
+            while (true)
             {
                 unsafe
                 {
@@ -306,7 +306,7 @@ namespace System.Xml
             }
 
             char[] helperBuffer = new char[256];
-            for (;;)
+            while (true)
             {
                 if (startPos < i)
                 {
@@ -412,7 +412,7 @@ namespace System.Xml
             int i = 0;
             char ch = (char)0;
 
-            for (;;)
+            while (true)
             {
                 unsafe
                 {
index 6f5e773..13153ea 100644 (file)
@@ -1191,7 +1191,7 @@ namespace System.Xml
                 FinishInit();
             }
 
-            for (;;)
+            while (true)
             {
                 switch (_parsingFunction)
                 {
@@ -3614,7 +3614,7 @@ namespace System.Xml
             int xmlDeclState = 0;   // <?xml (0) version='1.0' (1) encoding='__' (2) standalone='__' (3) ?>
             Encoding encoding = null;
 
-            for (;;)
+            while (true)
             {
                 int originalSbLen = sb.Length;
                 int wsCount = EatWhitespaces(xmlDeclState == 0 ? null : sb);
@@ -3906,7 +3906,7 @@ namespace System.Xml
             if (CompatibilitySwitches.IsAppEarlierThanWindowsPhone8)
                 mangoQuirks = true;
 #endif
-            for (;;)
+            while (true)
             {
                 bool needMoreChars = false;
                 int pos = _ps.charPos;
@@ -4141,7 +4141,7 @@ namespace System.Xml
         // Parses element content
         private bool ParseElementContent()
         {
-            for (;;)
+            while (true)
             {
                 int pos = _ps.charPos;
                 char[] chars = _ps.chars;
@@ -4347,7 +4347,7 @@ namespace System.Xml
             unsafe
             {
                 // parse element name
-                for (;;)
+                while (true)
                 {
                     if (_xmlCharType.IsNCNameSingleChar(chars[pos]))
                     {
@@ -4610,7 +4610,7 @@ namespace System.Xml
             LineInfo endTagLineInfo = new LineInfo(_ps.lineNo, _ps.LinePos);
 
             int pos;
-            for (;;)
+            while (true)
             {
                 pos = _ps.charPos + nameLen;
                 chars = _ps.chars;
@@ -4727,7 +4727,7 @@ namespace System.Xml
 
             Debug.Assert(_attrCount == 0);
 
-            for (;;)
+            while (true)
             {
                 // eat whitespace
                 int lineNoDelta = 0;
@@ -4848,7 +4848,7 @@ namespace System.Xml
 
                 unsafe
                 {
-                    for (;;)
+                    while (true)
                     {
                         if (_xmlCharType.IsNCNameSingleChar(tmpch2 = chars[pos]))
                         {
@@ -5179,7 +5179,7 @@ namespace System.Xml
 
             Debug.Assert(_stringBuilder.Length == 0);
 
-            for (;;)
+            while (true)
             {
                 // parse the rest of the attribute value
                 unsafe
@@ -5473,7 +5473,7 @@ namespace System.Xml
             // skip over the text if not in full parsing mode
             if (_parsingMode != ParsingMode.Full)
             {
-                while (!ParseText(out startPos, out endPos, ref orChars)) ;
+                while (!ParseText(out startPos, out endPos, ref orChars));
                 goto IgnoredNode;
             }
 
@@ -5565,7 +5565,7 @@ namespace System.Xml
                         _stringBuilder.Length = 0;
                         if (!fullValue)
                         {
-                            while (!ParseText(out startPos, out endPos, ref orChars)) ;
+                            while (!ParseText(out startPos, out endPos, ref orChars));
                         }
                         goto IgnoredNode;
                     }
@@ -5616,7 +5616,7 @@ namespace System.Xml
             int orChars = outOrChars;
             char c;
 
-            for (;;)
+            while (true)
             {
                 // parse text content
                 unsafe
@@ -5920,7 +5920,7 @@ namespace System.Xml
             int orChars = 0;
 
             _parsingFunction = _nextParsingFunction;
-            while (!ParseText(out startPos, out endPos, ref orChars)) ;
+            while (!ParseText(out startPos, out endPos, ref orChars));
         }
 
         private void FinishReadValueChunk()
@@ -5957,7 +5957,7 @@ namespace System.Xml
             }
             if (_incReadState != IncrementalReadState.ReadContentAsBinary_End)
             {
-                while (MoveToNextContentNode(true)) ;
+                while (MoveToNextContentNode(true));
             }
         }
 
@@ -6338,7 +6338,7 @@ namespace System.Xml
                 {
                     if (_ignorePIs || _parsingMode != ParsingMode.Full)
                     {
-                        while (!ParsePIValue(out startPos, out endPos)) ;
+                        while (!ParsePIValue(out startPos, out endPos));
                         return false;
                     }
                     sb = _stringBuilder;
@@ -6380,7 +6380,7 @@ namespace System.Xml
             int rcount = 0;
             int rpos = -1;
 
-            for (;;)
+            while (true)
             {
                 char tmpch;
                 unsafe
@@ -6564,7 +6564,7 @@ namespace System.Xml
             }
             else
             {
-                while (!ParseCDataOrComment(type, out startPos, out endPos)) ;
+                while (!ParseCDataOrComment(type, out startPos, out endPos));
             }
         }
 
@@ -6586,7 +6586,7 @@ namespace System.Xml
             int rpos = -1;
             char stopChar = (type == XmlNodeType.Comment) ? '-' : ']';
 
-            for (;;)
+            while (true)
             {
                 char tmpch;
                 unsafe
@@ -6935,7 +6935,7 @@ namespace System.Xml
             char[] chars = _ps.chars;
             int pos = _ps.charPos;
 
-            for (;;)
+            while (true)
             {
                 char ch;
 
@@ -7133,9 +7133,9 @@ namespace System.Xml
             int wsCount = 0;
             char[] chars = _ps.chars;
 
-            for (;;)
+            while (true)
             {
-                for (;;)
+                while (true)
                 {
                     switch (chars[pos])
                     {
@@ -7250,7 +7250,7 @@ namespace System.Xml
         //      - if (expand == true) then ps.charPos is changed to point to the replaced character
         private int ParseNumericCharRef(bool expand, StringBuilder internalSubsetBuilder, out EntityType entityType)
         {
-            for (;;)
+            while (true)
             {
                 int newPos;
                 int charCount;
@@ -7302,7 +7302,7 @@ namespace System.Xml
                     pos++;
                     digitPos = pos;
                     badDigitExceptionString = SR.Xml_BadHexEntity;
-                    for (;;)
+                    while (true)
                     {
                         char ch = chars[pos];
                         if (ch >= '0' && ch <= '9')
@@ -7418,7 +7418,7 @@ namespace System.Xml
         //      - if (expand == true) then ps.charPos is changed to point to the replaced character
         private int ParseNamedCharRef(bool expand, StringBuilder internalSubsetBuilder)
         {
-            for (;;)
+            while (true)
             {
                 int newPos;
                 switch (newPos = ParseNamedCharRefInline(_ps.charPos, expand, internalSubsetBuilder))
@@ -7626,7 +7626,7 @@ namespace System.Xml
             // parse name
             unsafe
             {
-                for (;;)
+                while (true)
                 {
                     if (_xmlCharType.IsNCNameSingleChar(chars[pos]))
                     {
@@ -8291,7 +8291,7 @@ namespace System.Xml
             int startPos = 0;
             int pos = 0;
 
-            for (;;)
+            while (true)
             {
                 switch (_incReadState)
                 {
@@ -8353,7 +8353,7 @@ namespace System.Xml
                 startPos = _ps.charPos;
                 pos = startPos;
 
-                for (;;)
+                while (true)
                 {
                     _incReadLineInfo.Set(_ps.LineNo, _ps.LinePos);
 
@@ -8451,7 +8451,7 @@ namespace System.Xml
                                     }
                                     else
                                     {
-                                        ;//Throw( );
+                                        ; //Throw( );
                                     }
                                     break;
                                 // end tag
@@ -8663,7 +8663,7 @@ namespace System.Xml
 
             Debug.Assert(_stringBuilder.Length == 0);
 
-            for (;;)
+            while (true)
             {
                 unsafe
                 {
@@ -9427,7 +9427,7 @@ namespace System.Xml
 
             _incReadDecoder.SetNextOutputBuffer(buffer, index, count);
 
-            for (;;)
+            while (true)
             {
                 // read what is already cached in curNode
                 int charsRead = 0;
index 4ae99eb..502b2be 100644 (file)
@@ -160,7 +160,7 @@ namespace System.Xml
                 return FinishInitAsync().CallBoolTaskFuncWhenFinishAsync(thisRef => thisRef.ReadAsync(), this);
             }
 
-            for (;;)
+            while (true)
             {
                 switch (_parsingFunction)
                 {
@@ -1269,7 +1269,7 @@ namespace System.Xml
             int xmlDeclState = 0;   // <?xml (0) version='1.0' (1) encoding='__' (2) standalone='__' (3) ?>
             Encoding encoding = null;
 
-            for (;;)
+            while (true)
             {
                 int originalSbLen = sb.Length;
                 int wsCount = await EatWhitespacesAsync(xmlDeclState == 0 ? null : sb).ConfigureAwait(false);
@@ -1553,7 +1553,7 @@ namespace System.Xml
         // Parses the document content, no async keyword for perf optimize
         private Task<bool> ParseDocumentContentAsync()
         {
-            for (;;)
+            while (true)
             {
                 bool needMoreChars = false;
                 int pos = _ps.charPos;
@@ -1813,7 +1813,7 @@ namespace System.Xml
         // Parses element content
         private Task<bool> ParseElementContentAsync()
         {
-            for (;;)
+            while (true)
             {
                 int pos = _ps.charPos;
                 char[] chars = _ps.chars;
@@ -1972,7 +1972,7 @@ namespace System.Xml
             unsafe
             {
                 // parse element name
-                for (;;)
+                while (true)
                 {
                     if (_xmlCharType.IsNCNameSingleChar(chars[pos]))
                     {
@@ -2285,7 +2285,7 @@ namespace System.Xml
         {
             int pos;
             char[] chars;
-            for (;;)
+            while (true)
             {
                 pos = _ps.charPos + nameLen;
                 chars = _ps.chars;
@@ -2422,7 +2422,7 @@ namespace System.Xml
 
             Debug.Assert(_attrCount == 0);
 
-            for (;;)
+            while (true)
             {
                 // eat whitespace
                 int lineNoDelta = 0;
@@ -2540,7 +2540,7 @@ namespace System.Xml
 
                 unsafe
                 {
-                    for (;;)
+                    while (true)
                     {
                         if (_xmlCharType.IsNCNameSingleChar(tmpch2 = chars[pos]))
                         {
@@ -2749,7 +2749,7 @@ namespace System.Xml
 
             Debug.Assert(_stringBuilder.Length == 0);
 
-            for (;;)
+            while (true)
             {
                 // parse the rest of the attribute value
                 while (_xmlCharType.IsAttributeValueChar(chars[pos]))
@@ -3383,7 +3383,7 @@ namespace System.Xml
 
         private Task<ValueTuple<int, int, int, bool>> ParseTextAsync(int outOrChars, char[] chars, int pos, int rcount, int rpos, int orChars, char c)
         {
-            for (;;)
+            while (true)
             {
                 // parse text content
                 while (_xmlCharType.IsTextChar(c = chars[pos]))
@@ -4179,7 +4179,7 @@ namespace System.Xml
             int rcount = 0;
             int rpos = -1;
 
-            for (;;)
+            while (true)
             {
                 char tmpch;
 
@@ -4407,7 +4407,7 @@ namespace System.Xml
             int rpos = -1;
             char stopChar = (type == XmlNodeType.Comment) ? '-' : ']';
 
-            for (;;)
+            while (true)
             {
                 char tmpch;
                 while (_xmlCharType.IsTextChar(tmpch = chars[pos]) && tmpch != stopChar)
@@ -4761,7 +4761,7 @@ namespace System.Xml
             char[] chars = _ps.chars;
             int pos = _ps.charPos;
 
-            for (;;)
+            while (true)
             {
                 char ch;
 
@@ -4956,9 +4956,9 @@ namespace System.Xml
             int wsCount = 0;
             char[] chars = _ps.chars;
 
-            for (;;)
+            while (true)
             {
-                for (;;)
+                while (true)
                 {
                     switch (chars[pos])
                     {
@@ -5061,7 +5061,7 @@ namespace System.Xml
         {
             EntityType entityType;
 
-            for (;;)
+            while (true)
             {
                 int newPos;
                 int charCount;
@@ -5094,7 +5094,7 @@ namespace System.Xml
         //      - if (expand == true) then ps.charPos is changed to point to the replaced character
         private async Task<int> ParseNamedCharRefAsync(bool expand, StringBuilder internalSubsetBuilder)
         {
-            for (;;)
+            while (true)
             {
                 int newPos;
                 switch (newPos = ParseNamedCharRefInline(_ps.charPos, expand, internalSubsetBuilder))
@@ -5184,7 +5184,7 @@ namespace System.Xml
             // parse name
             unsafe
             {
-                for (;;)
+                while (true)
                 {
                     if (_xmlCharType.IsNCNameSingleChar(chars[pos]))
                     {
@@ -5549,7 +5549,7 @@ namespace System.Xml
 
             _incReadDecoder.SetNextOutputBuffer(buffer, index, count);
 
-            for (;;)
+            while (true)
             {
                 // read what is already cached in curNode
                 int charsRead = 0;
index 98145a7..ca3cf1c 100644 (file)
@@ -270,7 +270,7 @@ namespace System.Xml
             _nsTop = -1;
             // element stack
             _stack = new TagInfo[10];
-            _top = 0;// 0 is an empty sentanial element
+            _top = 0; // 0 is an empty sentanial element
             _stack[_top].Init(-1);
             _quoteChar = '"';
 
index 6ec1264..648bc4d 100644 (file)
@@ -718,7 +718,7 @@ namespace System.Xml
                 byte* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     byte* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -840,7 +840,7 @@ namespace System.Xml
                 byte* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     byte* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -970,7 +970,7 @@ namespace System.Xml
                 char* pSrc = pSrcBegin;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     byte* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1033,7 +1033,7 @@ namespace System.Xml
                 byte* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     byte* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1152,7 +1152,7 @@ namespace System.Xml
                 byte* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     byte* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1302,7 +1302,7 @@ namespace System.Xml
                 byte* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     byte* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
index 31d6d70..526f12f 100644 (file)
@@ -560,7 +560,7 @@ namespace System.Xml
                 byte* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     byte* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -763,7 +763,7 @@ namespace System.Xml
                 byte* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     byte* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1002,7 +1002,7 @@ namespace System.Xml
                 char* pSrc = pSrcBegin;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     byte* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1176,7 +1176,7 @@ namespace System.Xml
                 byte* pDst = pDstBegin + bufPos;
 
                 int ch = 0;
-                for (;;)
+                while (true)
                 {
                     byte* pDstEnd = pDst + (pSrcEnd - pSrc);
                     if (pDstEnd > pDstBegin + bufLen)
@@ -1377,7 +1377,7 @@ namespace System.Xml
                     byte* pDst = pDstBegin + bufPos;
 
                     int ch = 0;
-                    for (;;)
+                    while (true)
                     {
                         byte* pDstEnd = pDst + (pSrcEnd - pSrc);
                         if (pDstEnd > pDstBegin + bufLen)
@@ -1566,7 +1566,7 @@ namespace System.Xml
                     byte* pDst = pDstBegin + bufPos;
 
                     int ch = 0;
-                    for (;;)
+                    while (true)
                     {
                         byte* pDstEnd = pDst + (pSrcEnd - pSrc);
                         if (pDstEnd > pDstBegin + bufLen)
index 2ffff6b..371063d 100644 (file)
@@ -954,7 +954,7 @@ namespace System.Xml
                     {
                         if (!_outerReader.IsEmptyElement)
                         {
-                            for (;;)
+                            while (true)
                             {
                                 if (!_outerReader.Read())
                                 {
index 2414e8b..1eb633b 100644 (file)
@@ -866,7 +866,7 @@ namespace System.Xml
 
         public override void MoveToRoot()
         {
-            for (;;)
+            while (true)
             {
                 XmlNode parent = _source.ParentNode;
                 if (parent == null)
@@ -1009,7 +1009,7 @@ namespace System.Xml
                 }
                 else
                 {
-                    for (;;)
+                    while (true)
                     {
                         XmlNode nextSibling = following.NextSibling;
                         if (nextSibling != null)
@@ -1098,7 +1098,7 @@ namespace System.Xml
                 }
                 else
                 {
-                    for (;;)
+                    while (true)
                     {
                         XmlNode nextSibling = following.NextSibling;
                         if (nextSibling != null)
@@ -2078,7 +2078,7 @@ namespace System.Xml
 
         internal static bool IsFollowingSibling(XmlNode left, XmlNode right)
         {
-            for (;;)
+            while (true)
             {
                 left = left.NextSibling;
                 if (left == null)
@@ -2095,7 +2095,7 @@ namespace System.Xml
 
         private static bool IsDescendant(XmlNode top, XmlNode bottom)
         {
-            for (;;)
+            while (true)
             {
                 XmlNode parent = bottom.ParentNode;
                 if (parent == null)
@@ -2236,7 +2236,7 @@ namespace System.Xml
 
         public override bool MoveNext()
         {
-            for (;;)
+            while (true)
             {
                 if (_nav.MoveToFirstChild())
                 {
index aa3c927..0e774c7 100644 (file)
@@ -530,7 +530,7 @@ namespace System.Xml
         private void ParseSubset()
         {
             int startTagEntityId;
-            for (;;)
+            while (true)
             {
                 Token token = GetToken(false);
                 startTagEntityId = _currentEntityId;
@@ -667,7 +667,7 @@ namespace System.Xml
             }
 
             SchemaAttDef attrDef = null;
-            for (;;)
+            while (true)
             {
                 switch (GetToken(false))
                 {
@@ -800,7 +800,7 @@ namespace System.Xml
                             elementDecl.ContentValidator.ContentType == XmlSchemaContentType.Empty &&
                             !ignoreErrors)
                         {
-                            SendValidationEvent(_curPos - 8, XmlSeverityType.Error, SR.Sch_NotationAttributeOnEmptyElement, elementDecl.Name.ToString());// 8 == strlen("NOTATION")
+                            SendValidationEvent(_curPos - 8, XmlSeverityType.Error, SR.Sch_NotationAttributeOnEmptyElement, elementDecl.Name.ToString()); // 8 == strlen("NOTATION")
                         }
                         elementDecl.IsNotationDeclared = true;
                     }
@@ -816,7 +816,7 @@ namespace System.Xml
                 {
                     goto UnexpectedError;
                 }
-                for (;;)
+                while (true)
                 {
                     string notationName = GetNameString();
                     if (!_schemaInfo.Notations.ContainsKey(notationName))
@@ -854,7 +854,7 @@ namespace System.Xml
                     goto UnexpectedError;
                 attrDef.AddValue(GetNameString());
 
-                for (;;)
+                while (true)
                 {
                     switch (GetToken(false))
                     {
@@ -1145,7 +1145,7 @@ namespace System.Xml
             int connectorEntityId = -1;
             int contentEntityId = _currentEntityId;
 
-            for (;;)
+            while (true)
             {
                 switch (GetToken(false))
                 {
@@ -1562,7 +1562,7 @@ namespace System.Xml
         private Token GetToken(bool needWhiteSpace)
         {
             _whitespaceSeen = false;
-            for (;;)
+            while (true)
             {
                 switch (_chars[_curPos])
                 {
@@ -1696,7 +1696,7 @@ namespace System.Xml
 
         private Token ScanSubsetContent()
         {
-            for (;;)
+            while (true)
             {
                 switch (_chars[_curPos])
                 {
@@ -1945,7 +1945,7 @@ namespace System.Xml
 
         private Token ScanElement1()
         {
-            for (;;)
+            while (true)
             {
                 switch (_chars[_curPos])
                 {
@@ -2141,7 +2141,7 @@ namespace System.Xml
 
         private Token ScanAttlist2()
         {
-            for (;;)
+            while (true)
             {
                 switch (_chars[_curPos])
                 {
@@ -2327,7 +2327,7 @@ namespace System.Xml
 
         private Token ScanAttlist6()
         {
-            for (;;)
+            while (true)
             {
                 switch (_chars[_curPos])
                 {
@@ -2422,7 +2422,7 @@ namespace System.Xml
 
             _stringBuilder.Length = 0;
 
-            for (;;)
+            while (true)
             {
                 while (_xmlCharType.IsAttributeValueChar(_chars[_curPos]) && _chars[_curPos] != '%')
                 {
@@ -2808,7 +2808,7 @@ namespace System.Xml
             }
             _curPos++;
 
-            for (;;)
+            while (true)
             {
                 if (_charsUsed - _curPos < 5)
                 {
@@ -2878,7 +2878,7 @@ namespace System.Xml
             int ignoreSectionDepth = 0;
 
             // skip ignored part
-            for (;;)
+            while (true)
             {
                 while (_xmlCharType.IsTextChar(_chars[_curPos]) && _chars[_curPos] != ']')
                 {
@@ -3005,7 +3005,7 @@ namespace System.Xml
             _tokenStartPos = _curPos;
             int colonOffset = -1;
 
-            for (;;)
+            while (true)
             {
                 unsafe
                 {
@@ -3039,7 +3039,7 @@ namespace System.Xml
 
                 unsafe
                 {
-                    for (;;)
+                    while (true)
                     {
                         if (_xmlCharType.IsNCNameSingleChar(_chars[_curPos]))
                         {
@@ -3111,11 +3111,11 @@ namespace System.Xml
         {
             _tokenStartPos = _curPos;
 
-            for (;;)
+            while (true)
             {
                 unsafe
                 {
-                    for (;;)
+                    while (true)
                     {
                         if (_xmlCharType.IsNCNameSingleChar(_chars[_curPos]) || _chars[_curPos] == ':')
                         {
@@ -3573,7 +3573,7 @@ namespace System.Xml
                 )
             { // postpone the proper surrogate checking to the loop below
                 int endPos = startPos;
-                for (;;)
+                while (true)
                 {
                     if (_xmlCharType.IsNCNameSingleChar(_chars[endPos]))
                     {
index 4a44eb1..5dde26c 100644 (file)
@@ -170,7 +170,7 @@ namespace System.Xml
         private async Task ParseSubsetAsync()
         {
             int startTagEntityId;
-            for (;;)
+            while (true)
             {
                 Token token = await GetTokenAsync(false).ConfigureAwait(false);
                 startTagEntityId = _currentEntityId;
@@ -307,7 +307,7 @@ namespace System.Xml
             }
 
             SchemaAttDef attrDef = null;
-            for (;;)
+            while (true)
             {
                 switch (await GetTokenAsync(false).ConfigureAwait(false))
                 {
@@ -440,7 +440,7 @@ namespace System.Xml
                             elementDecl.ContentValidator.ContentType == XmlSchemaContentType.Empty &&
                             !ignoreErrors)
                         {
-                            SendValidationEvent(_curPos - 8, XmlSeverityType.Error, SR.Sch_NotationAttributeOnEmptyElement, elementDecl.Name.ToString());// 8 == strlen("NOTATION")
+                            SendValidationEvent(_curPos - 8, XmlSeverityType.Error, SR.Sch_NotationAttributeOnEmptyElement, elementDecl.Name.ToString()); // 8 == strlen("NOTATION")
                         }
                         elementDecl.IsNotationDeclared = true;
                     }
@@ -456,7 +456,7 @@ namespace System.Xml
                 {
                     goto UnexpectedError;
                 }
-                for (;;)
+                while (true)
                 {
                     string notationName = GetNameString();
                     if (!_schemaInfo.Notations.ContainsKey(notationName))
@@ -494,7 +494,7 @@ namespace System.Xml
                     goto UnexpectedError;
                 attrDef.AddValue(GetNameString());
 
-                for (;;)
+                while (true)
                 {
                     switch (await GetTokenAsync(false).ConfigureAwait(false))
                     {
@@ -772,7 +772,7 @@ namespace System.Xml
             int connectorEntityId = -1;
             int contentEntityId = _currentEntityId;
 
-            for (;;)
+            while (true)
             {
                 switch (await GetTokenAsync(false).ConfigureAwait(false))
                 {
@@ -1181,7 +1181,7 @@ namespace System.Xml
         private async Task<Token> GetTokenAsync(bool needWhiteSpace)
         {
             _whitespaceSeen = false;
-            for (;;)
+            while (true)
             {
                 switch (_chars[_curPos])
                 {
@@ -1315,7 +1315,7 @@ namespace System.Xml
 
         private async Task<Token> ScanSubsetContentAsync()
         {
-            for (;;)
+            while (true)
             {
                 switch (_chars[_curPos])
                 {
@@ -1535,7 +1535,7 @@ namespace System.Xml
 
         private async Task<Token> ScanElement1Async()
         {
-            for (;;)
+            while (true)
             {
                 switch (_chars[_curPos])
                 {
@@ -1648,7 +1648,7 @@ namespace System.Xml
 
         private async Task<Token> ScanAttlist2Async()
         {
-            for (;;)
+            while (true)
             {
                 switch (_chars[_curPos])
                 {
@@ -1780,7 +1780,7 @@ namespace System.Xml
 
         private async Task<Token> ScanAttlist6Async()
         {
-            for (;;)
+            while (true)
             {
                 switch (_chars[_curPos])
                 {
@@ -1860,7 +1860,7 @@ namespace System.Xml
 
             _stringBuilder.Length = 0;
 
-            for (;;)
+            while (true)
             {
                 while (_xmlCharType.IsAttributeValueChar(_chars[_curPos]) && _chars[_curPos] != '%')
                 {
@@ -2225,7 +2225,7 @@ namespace System.Xml
             }
             _curPos++;
 
-            for (;;)
+            while (true)
             {
                 if (_charsUsed - _curPos < 5)
                 {
@@ -2284,7 +2284,7 @@ namespace System.Xml
             int ignoreSectionDepth = 0;
 
             // skip ignored part
-            for (;;)
+            while (true)
             {
                 while (_xmlCharType.IsTextChar(_chars[_curPos]) && _chars[_curPos] != ']')
                 {
@@ -2411,7 +2411,7 @@ namespace System.Xml
             _tokenStartPos = _curPos;
             int colonOffset = -1;
 
-            for (;;)
+            while (true)
             {
                 //a tmp flag, used to avoid await keyword in unsafe context.
                 bool awaitReadDataInNameAsync = false;
@@ -2451,7 +2451,7 @@ namespace System.Xml
             ContinueName:
                 unsafe
                 {
-                    for (;;)
+                    while (true)
                     {
                         if (_xmlCharType.IsNCNameSingleChar(_chars[_curPos]))
                         {
@@ -2523,11 +2523,11 @@ namespace System.Xml
         {
             _tokenStartPos = _curPos;
 
-            for (;;)
+            while (true)
             {
                 unsafe
                 {
-                    for (;;)
+                    while (true)
                     {
                         if (_xmlCharType.IsNCNameSingleChar(_chars[_curPos]) || _chars[_curPos] == ':')
                         {
index 1aa4520..281ae05 100644 (file)
@@ -850,7 +850,7 @@ namespace System.Xml.Schema
                         {
                             //more than one consecutive text nodes probably with PI in between
                             xse.SchemaTypeName = ST_string;
-                            xse.LineNumber = TF_string;// we use LineNumber to store flags of valid types
+                            xse.LineNumber = TF_string; // we use LineNumber to store flags of valid types
                         }
                         else
                         {
@@ -864,7 +864,7 @@ namespace System.Xml.Schema
                                 else
                                 {
                                     xse.SchemaTypeName = ST_string;
-                                    xse.LineNumber = TF_string;// we use LineNumber to store flags of valid types
+                                    xse.LineNumber = TF_string; // we use LineNumber to store flags of valid types
                                 }
                             else if (_xtr.NodeType == XmlNodeType.Text)
                             {
@@ -887,7 +887,7 @@ namespace System.Xml.Schema
                             else
                             {
                                 xse.SchemaTypeName = ST_string;
-                                xse.LineNumber = TF_string;// we use LineNumber to store flags of valid types
+                                xse.LineNumber = TF_string; // we use LineNumber to store flags of valid types
                             }
                         }
                     }
index 6085d31..8b8c158 100644 (file)
@@ -394,7 +394,7 @@ namespace System.Xml.Schema
                             {
                                 Parser parser = new Parser(SchemaType.XSD, NameTable, SchemaNames, EventHandler);
                                 parser.Parse(reader, null);
-                                while (reader.Read()) ;// wellformness check
+                                while (reader.Read()) ; // wellformness check
                                 includedSchema = parser.XmlSchema;
                                 include.Schema = includedSchema;
                                 _schemaLocations.Add(ruri, includedSchema);
index 7b8ca2e..c7de0d8 100644 (file)
@@ -230,7 +230,7 @@ namespace System.Xml.Schema
                         {
                             Parser parser = new Parser(SchemaType.XSD, NameTable, SchemaNames, EventHandler);
                             parser.Parse(reader, null);
-                            while (reader.Read()) ;// wellformness check
+                            while (reader.Read()) ; // wellformness check
                             include.Schema = parser.XmlSchema;
                             LoadExternals(include.Schema, xsc);
                         }
index 1077c07..531acef 100644 (file)
@@ -338,7 +338,7 @@ namespace System.Xml.Schema
                 Parser parser = new Parser(SchemaType.XDR, NameTable, SchemaNames, EventHandler);
                 parser.XmlResolver = this.XmlResolver;
                 parser.Parse(reader, uri);
-                while (reader.Read()) ;// wellformness check
+                while (reader.Read()) ; // wellformness check
                 xdrSchema = parser.XdrSchema;
             }
             catch (XmlSchemaException e)
index a985757..8ad8229 100644 (file)
@@ -107,7 +107,7 @@ namespace System.Xml.Schema
             try
             {
                 schema = Add(ns, reader, _xmlResolver);
-                while (reader.Read()) ;// wellformness check
+                while (reader.Read()) ; // wellformness check
             }
             finally
             {
index 30f90b2..8949e58 100644 (file)
@@ -303,7 +303,7 @@ namespace System.Xml.Schema
                     try
                     {
                         schema = Add(targetNamespace, ParseSchema(targetNamespace, reader));
-                        while (reader.Read()) ;// wellformness check;
+                        while (reader.Read()) ; // wellformness check;
                     }
                     finally
                     {
index cbc9f67..8a68835 100644 (file)
@@ -1858,7 +1858,7 @@ namespace System.Xml.Schema
                 readerSettings.XmlResolver = _xmlResolver;
                 Reader = XmlReader.Create(stm, readerSettings, ruri.ToString());
                 _schemaSet.Add(uri, Reader, _validatedNamespaces);
-                while (Reader.Read()) ;// wellformness check
+                while (Reader.Read()) ; // wellformness check
             }
             catch (XmlSchemaException e)
             {
index 3869c80..4fe3753 100644 (file)
@@ -586,7 +586,7 @@ namespace System.Xml.Schema
                 //Add to validator's SchemaInfo
                 SchemaInfo.Add(schemaInfo, EventHandler);
 
-                while (reader.Read()) ;// wellformness check
+                while (reader.Read()) ; // wellformness check
             }
             catch (XmlSchemaException e)
             {
index 82b6bf3..28a45a9 100644 (file)
@@ -4569,7 +4569,7 @@ namespace System.Xml.Serialization
                 memberMapping.TypeDesc = arrayMapping.TypeDesc;
                 memberMapping.ReadOnly = readOnly;
                 Member member = new Member(this, source, arrayName, 0, memberMapping, false);
-                member.IsNullable = false;//Note, sowmys: IsNullable is set to false since null condition (xsi:nil) is already handled by 'ReadNull()'
+                member.IsNullable = false; // Note, sowmys: IsNullable is set to false since null condition (xsi:nil) is already handled by 'ReadNull()'
 
                 Member[] members = new Member[] { member };
                 WriteMemberBegin(members);
index f170462..26ab809 100644 (file)
@@ -43,8 +43,8 @@ namespace MS.Internal.Xml.XPath
         {
             outputBuffer.Clear();
             count = 0;
-            return input.Evaluate(context);// This is trick. IDQuery needs this value. Otherwise we would return this.
-                                           // All subclasses should and would anyway override this method and return this.
+            return input.Evaluate(context); // This is trick. IDQuery needs this value. Otherwise we would return this.
+                                            // All subclasses should and would anyway override this method and return this.
         }
 
         public override XPathNavigator Advance()
index a296e6f..d4c1d02 100644 (file)
@@ -346,7 +346,7 @@ namespace MS.Internal.Xml.XPath
             int start = _xpathExprIndex - 1;
             int len = 0;
 
-            for (;;)
+            while (true)
             {
                 if (_xmlCharType.IsNCNameSingleChar(this.CurrentChar))
                 {
index 1c2a9e3..5a7cafb 100644 (file)
@@ -658,7 +658,7 @@ namespace System.Xml.XPath
                         else
                         {
                             XPathNavigator prev = nav.Clone();
-                            for (;;)
+                            while (true)
                             {
                                 if (!nav.MoveToNextNamespace(XPathNamespaceScope.Local))
                                 {
index 5fcbbee..0be6622 100644 (file)
@@ -1444,7 +1444,7 @@ namespace System.Xml
 
             int i = 0;
             int len = data.Length;
-            for (;;)
+            while (true)
             {
                 while (i < len && s_xmlCharType.IsCharData(data[i]))
                 {
@@ -1486,7 +1486,7 @@ namespace System.Xml
 
             int i = offset;
             int endPos = offset + len;
-            for (;;)
+            while (true)
             {
                 while (i < endPos && s_xmlCharType.IsCharData(data[i]))
                 {
index 9b076a7..456bd9d 100644 (file)
@@ -554,7 +554,7 @@ namespace System.Xml.Xsl.XPath
 #endif
                 );
             int start = _curIndex;
-            for (;;)
+            while (true)
             {
                 if (_xmlCharType.IsNCNameSingleChar(_curChar))
                 {
index 31894d3..b8bdd71 100644 (file)
@@ -365,7 +365,7 @@ namespace System.Xml.Tests
 
             bool fRetry = false;
 
-            for (; ;)
+            while (true)
             {
                 try
                 {
index eb1fd33..c445f1e 100644 (file)
@@ -95,7 +95,7 @@ namespace System.Reflection.Runtime.BindingFlagSupport
             }
             string name = member.Name;
             TypeInfo typeInfo = member.DeclaringType.GetTypeInfo();
-            for (;;)
+            while (true)
             {
                 Type baseType = typeInfo.BaseType;
                 if (baseType == null)
index 0228902..1bba3f2 100644 (file)
@@ -22,7 +22,7 @@ namespace System.Reflection.TypeLoading
         private volatile ConstructorInfo _lazyConstructorInfo;
 
         public abstract override IList<CustomAttributeTypedArgument> ConstructorArguments { get; }
-        public abstract override IList<CustomAttributeNamedArgument> NamedArguments { get;}
+        public abstract override IList<CustomAttributeNamedArgument> NamedArguments { get; }
         public sealed override string ToString() => GetType().ToString();  // Does not match NETFX output - however, doing so can prematurely
                                                                            // trigger resolve handlers. Too impactful for ToString().
     }
index dbeb13f..66dfa83 100644 (file)
@@ -164,7 +164,7 @@ namespace System.Reflection.TypeLoading
                     return true;
 
                 Type walk = fromTypeInfo;
-                for (;;)
+                while (true)
                 {
                     Type baseType = walk.BaseType;
                     if (baseType == null)
index d8bf144..272dcf3 100644 (file)
@@ -74,7 +74,7 @@ namespace System.Reflection.Tests
                 if (namedArgument.IsField)
                 {
                     // Field
-                    for (;;)
+                    while (true)
                     {
                         FieldInfo fieldInfo = walk.GetField(name, BindingFlags.Public | BindingFlags.Instance | BindingFlags.Static | BindingFlags.DeclaredOnly);
                         if (fieldInfo != null)
@@ -89,7 +89,7 @@ namespace System.Reflection.Tests
                 else
                 {
                     // Property
-                    for (;;)
+                    while (true)
                     {
                         PropertyInfo propertyInfo = walk.GetProperty(name, BindingFlags.Public | BindingFlags.Instance | BindingFlags.Static | BindingFlags.DeclaredOnly);
                         if (propertyInfo != null)
index 6adb639..0fa9630 100644 (file)
@@ -485,7 +485,7 @@ namespace System.Runtime.Caching
             int pageIndexNext;
             ExpiresEntry[] entries;
 
-            for (; ;)
+            while (true)
             {
                 pageIndexNext = (_pages[(pageIndexCurrent)]._pageNext);
 
@@ -506,7 +506,7 @@ namespace System.Runtime.Caching
                 pageIndexCurrent = pageIndexNext;
             }
 
-            for (; ;)
+            while (true)
             {
                 if (_freeEntryList._tail == -1)
                     break;
index 4d23674..a4abc08 100644 (file)
@@ -471,7 +471,7 @@ namespace System.Runtime.Caching
             int pageIndexNext;
             UsageEntry[] entries;
 
-            for (; ;)
+            while (true)
             {
                 pageIndexNext = (_pages[(pageIndexCurrent)]._pageNext);
 
@@ -490,7 +490,7 @@ namespace System.Runtime.Caching
                 pageIndexCurrent = pageIndexNext;
             }
 
-            for (; ;)
+            while (true)
             {
                 if (_freeEntryList._tail == -1)
                     break;
index 4808f2b..fb79781 100644 (file)
@@ -24,7 +24,7 @@ namespace System.Runtime.Caching
             }
             set
             {
-                for (; ;)
+                while (true)
                 {
                     int oldData = _data;
                     int newData;
@@ -48,7 +48,7 @@ namespace System.Runtime.Caching
 
         internal bool ChangeValue(int bit, bool value)
         {
-            for (; ;)
+            while (true)
             {
                 int oldData = _data;
                 int newData;
index 591cd45..62d7d40 100644 (file)
@@ -483,7 +483,7 @@ namespace System.Numerics
 
             // Try to conserve space as much as possible by checking for wasted leading uint[] entries
             // sometimes the uint[] has leading zeros from bit manipulation operations & and ^
-            for (len = value.Length; len > 0 && value[len - 1] == 0; len--) ;
+            for (len = value.Length; len > 0 && value[len - 1] == 0; len--);
 
             if (len == 0)
                 this = s_bnZeroInt;
index 4c98baa..75e2a26 100644 (file)
@@ -734,7 +734,7 @@ namespace System.Runtime.Serialization.Formatters.Binary
                 if ((pr._objectInfo != null) && pr._objectInfo._objectType != null && (pr._objectInfo._objectType.IsValueType))
                 {
                     pr._isValueTypeFixup = true; //Valuefixup
-                    ValueFixupStack.Push(new ValueFixup(objectPr._newObj, pr._name, objectPr._objectInfo));//valuefixup
+                    ValueFixupStack.Push(new ValueFixup(objectPr._newObj, pr._name, objectPr._objectInfo)); //valuefixup
                 }
                 else
                 {
index 9f7b553..a81b618 100644 (file)
@@ -1575,7 +1575,7 @@ namespace System.Runtime.Serialization
             Debug.Assert(_startingVersion == _list.Version, "[ObjectHolderListEnumerator.MoveNext]m_startingVersion==m_list.Version");
             if (_isFixupEnumerator)
             {
-                while (++_currPos < _list.Count && _list._values[_currPos].CompletelyFixed) ;
+                while (++_currPos < _list.Count && _list._values[_currPos].CompletelyFixed);
                 return _currPos != _list.Count;
             }
             else
index fcb8414..d9b391c 100644 (file)
@@ -649,19 +649,19 @@ nameof(binaryForm));
             // Important: Not all combinations of inheritance bits are valid
             //
 
-            afToPm[( int )(   0   |   0   |   0   |   0   )] = PM.F |   0   |   0   |   0   |   0   ;
-            afToPm[( int )(   0   | AF.OI |   0   |   0   )] = PM.F |   0   | PM.CO |   0   | PM.GO ;
-            afToPm[( int )(   0   | AF.OI |   0   | AF.NP )] = PM.F |   0   | PM.CO |   0   |   0   ;
-            afToPm[( int )(   0   | AF.OI | AF.IO |   0   )] =   0  |   0   | PM.CO |   0   | PM.GO ;
-            afToPm[( int )(   0   | AF.OI | AF.IO | AF.NP )] =   0  |   0   | PM.CO |   0   |   0   ;
-            afToPm[( int )( AF.CI |   0   |   0   |   0   )] = PM.F | PM.CF |   0   | PM.GF |   0   ;
-            afToPm[( int )( AF.CI |   0   |   0   | AF.NP )] = PM.F | PM.CF |   0   |   0   |   0   ;
-            afToPm[( int )( AF.CI |   0   | AF.IO |   0   )] =   0  | PM.CF |   0   | PM.GF |   0   ;
-            afToPm[( int )( AF.CI |   0   | AF.IO | AF.NP )] =   0  | PM.CF |   0   |   0   |   0   ;
-            afToPm[( int )( AF.CI | AF.OI |   0   |   0   )] = PM.F | PM.CF | PM.CO | PM.GF | PM.GO ;
-            afToPm[( int )( AF.CI | AF.OI |   0   | AF.NP )] = PM.F | PM.CF | PM.CO |   0   |   0   ;
-            afToPm[( int )( AF.CI | AF.OI | AF.IO |   0   )] =   0  | PM.CF | PM.CO | PM.GF | PM.GO ;
-            afToPm[( int )( AF.CI | AF.OI | AF.IO | AF.NP )] =   0  | PM.CF | PM.CO |   0   |   0   ;
+            afToPm[( int )(   0   |   0   |   0   |   0   )] = PM.F |   0   |   0   |   0   |     0;
+            afToPm[( int )(   0   | AF.OI |   0   |   0   )] = PM.F |   0   | PM.CO |   0   | PM.GO;
+            afToPm[( int )(   0   | AF.OI |   0   | AF.NP )] = PM.F |   0   | PM.CO |   0   |     0;
+            afToPm[( int )(   0   | AF.OI | AF.IO |   0   )] =   0  |   0   | PM.CO |   0   | PM.GO;
+            afToPm[( int )(   0   | AF.OI | AF.IO | AF.NP )] =   0  |   0   | PM.CO |   0   |     0;
+            afToPm[( int )( AF.CI |   0   |   0   |   0   )] = PM.F | PM.CF |   0   | PM.GF |     0;
+            afToPm[( int )( AF.CI |   0   |   0   | AF.NP )] = PM.F | PM.CF |   0   |   0   |     0;
+            afToPm[( int )( AF.CI |   0   | AF.IO |   0   )] =   0  | PM.CF |   0   | PM.GF |     0;
+            afToPm[( int )( AF.CI |   0   | AF.IO | AF.NP )] =   0  | PM.CF |   0   |   0   |     0;
+            afToPm[( int )( AF.CI | AF.OI |   0   |   0   )] = PM.F | PM.CF | PM.CO | PM.GF | PM.GO;
+            afToPm[( int )( AF.CI | AF.OI |   0   | AF.NP )] = PM.F | PM.CF | PM.CO |   0   |     0;
+            afToPm[( int )( AF.CI | AF.OI | AF.IO |   0   )] =   0  | PM.CF | PM.CO | PM.GF | PM.GO;
+            afToPm[( int )( AF.CI | AF.OI | AF.IO | AF.NP )] =   0  | PM.CF | PM.CO |   0   |     0;
 
             return afToPm;
         }
@@ -682,19 +682,19 @@ nameof(binaryForm));
             // the four ACE inheritance bits
             //
 
-            pmToAf[( int )( PM.F |   0   |   0   |   0   |   0   )] =    0   |   0   |   0   |   0   ;
-            pmToAf[( int )( PM.F |   0   | PM.CO |   0   | PM.GO )] =    0   | AF.OI |   0   |   0   ;
-            pmToAf[( int )( PM.F |   0   | PM.CO |   0   |   0   )] =    0   | AF.OI |   0   | AF.NP ;
-            pmToAf[( int )(   0  |   0   | PM.CO |   0   | PM.GO )] =    0   | AF.OI | AF.IO |   0   ;
-            pmToAf[( int )(   0  |   0   | PM.CO |   0   |   0   )] =    0   | AF.OI | AF.IO | AF.NP ;
-            pmToAf[( int )( PM.F | PM.CF |   0   | PM.GF |   0   )] =  AF.CI |   0   |   0   |   0   ;
-            pmToAf[( int )( PM.F | PM.CF |   0   |   0   |   0   )] =  AF.CI |   0   |   0   | AF.NP ;
-            pmToAf[( int )(   0  | PM.CF |   0   | PM.GF |   0   )] =  AF.CI |   0   | AF.IO |   0   ;
-            pmToAf[( int )(   0  | PM.CF |   0   |   0   |   0   )] =  AF.CI |   0   | AF.IO | AF.NP ;
-            pmToAf[( int )( PM.F | PM.CF | PM.CO | PM.GF | PM.GO )] =  AF.CI | AF.OI |   0   |   0   ;
-            pmToAf[( int )( PM.F | PM.CF | PM.CO |   0   |   0   )] =  AF.CI | AF.OI |   0   | AF.NP ;
-            pmToAf[( int )(   0  | PM.CF | PM.CO | PM.GF | PM.GO )] =  AF.CI | AF.OI | AF.IO |   0   ;
-            pmToAf[( int )(   0  | PM.CF | PM.CO |   0   |   0   )] =  AF.CI | AF.OI | AF.IO | AF.NP ;
+            pmToAf[( int )( PM.F |   0   |   0   |   0   |   0   )] =    0   |   0   |   0   |     0;
+            pmToAf[( int )( PM.F |   0   | PM.CO |   0   | PM.GO )] =    0   | AF.OI |   0   |     0;
+            pmToAf[( int )( PM.F |   0   | PM.CO |   0   |   0   )] =    0   | AF.OI |   0   | AF.NP;
+            pmToAf[( int )(   0  |   0   | PM.CO |   0   | PM.GO )] =    0   | AF.OI | AF.IO |     0;
+            pmToAf[( int )(   0  |   0   | PM.CO |   0   |   0   )] =    0   | AF.OI | AF.IO | AF.NP;
+            pmToAf[( int )( PM.F | PM.CF |   0   | PM.GF |   0   )] =  AF.CI |   0   |   0   |     0;
+            pmToAf[( int )( PM.F | PM.CF |   0   |   0   |   0   )] =  AF.CI |   0   |   0   | AF.NP;
+            pmToAf[( int )(   0  | PM.CF |   0   | PM.GF |   0   )] =  AF.CI |   0   | AF.IO |     0;
+            pmToAf[( int )(   0  | PM.CF |   0   |   0   |   0   )] =  AF.CI |   0   | AF.IO | AF.NP;
+            pmToAf[( int )( PM.F | PM.CF | PM.CO | PM.GF | PM.GO )] =  AF.CI | AF.OI |   0   |     0;
+            pmToAf[( int )( PM.F | PM.CF | PM.CO |   0   |   0   )] =  AF.CI | AF.OI |   0   | AF.NP;
+            pmToAf[( int )(   0  | PM.CF | PM.CO | PM.GF | PM.GO )] =  AF.CI | AF.OI | AF.IO |     0;
+            pmToAf[( int )(   0  | PM.CF | PM.CO |   0   |   0   )] =  AF.CI | AF.OI | AF.IO | AF.NP;
 
             return pmToAf;
         }
index 83c3ef5..9a544f1 100644 (file)
@@ -7,7 +7,7 @@ namespace System.Security.Cryptography
     public abstract class AsymmetricKeyExchangeDeformatter
     {
         protected AsymmetricKeyExchangeDeformatter() {}
-        public abstract string Parameters {get; set;}
+        public abstract string Parameters {get; set; }
         public abstract void SetKey(AsymmetricAlgorithm key);
         public abstract byte[] DecryptKeyExchange(byte[] rgb);
     }
index 3aff122..4c5bfbb 100644 (file)
@@ -8,7 +8,7 @@ namespace System.Security.Cryptography
     {
         protected AsymmetricKeyExchangeFormatter() {}
 
-        public abstract string Parameters {get;}
+        public abstract string Parameters {get; }
 
         public abstract void SetKey(AsymmetricAlgorithm key);
         public abstract byte[] CreateKeyExchange(byte[] data);
index 628ffdd..ca0f876 100644 (file)
@@ -45,7 +45,7 @@ namespace System.Security.Cryptography
 
         public override string Parameters
         {
-            get {return null;}
+            get {return null; }
         }
 
         public RandomNumberGenerator Rng {
index 7599bfd..381be95 100644 (file)
@@ -13,10 +13,10 @@ namespace Internal.NativeCrypto
     {
         private const int DSS_Q_LEN = 20;
 
-        internal const int DSS_MAGIC = 0x31535344;          // Encoding of "DSS1"
-        internal const int DSS_PRIVATE_MAGIC = 0x32535344;  // Encoding of "DSS2"
-        internal const int DSS_PUB_MAGIC_VER3 = 0x33535344; // Encoding of "DSS3"
-        internal const int DSS_PRIV_MAGIC_VER3 = 0x34535344;// Encoding of "DSS4"
+        internal const int DSS_MAGIC = 0x31535344;           // Encoding of "DSS1"
+        internal const int DSS_PRIVATE_MAGIC = 0x32535344;   // Encoding of "DSS2"
+        internal const int DSS_PUB_MAGIC_VER3 = 0x33535344;  // Encoding of "DSS3"
+        internal const int DSS_PRIV_MAGIC_VER3 = 0x34535344; // Encoding of "DSS4"
 
         /// <summary>
         /// Helper for DsaCryptoServiceProvider.ImportParameters()
index 315e94f..8112cf9 100644 (file)
@@ -129,7 +129,7 @@ namespace System.Text
             [FieldOffset(0x22)]
             internal ushort VersionMinor;   // WORD
             [FieldOffset(0x24)]
-            internal ushort VersionRevision;// WORD
+            internal ushort VersionRevision; // WORD
             [FieldOffset(0x26)]
             internal ushort VersionBuild;   // WORD
             [FieldOffset(0x28)]
index 4e4205e..bd8d590 100644 (file)
@@ -103,7 +103,7 @@ namespace System.Text.RegularExpressions
                 {
                     int prevat = 0;
 
-                    for (; ; )
+                    while (true)
                     {
                         al.Add(input.Substring(prevat, match.Index - prevat));
 
@@ -131,7 +131,7 @@ namespace System.Text.RegularExpressions
                 {
                     int prevat = input.Length;
 
-                    for (; ; )
+                    while (true)
                     {
                         al.Add(input.Substring(match.Index + match.Length, prevat - match.Index - match.Length));
 
index a2daac6..5a2b32d 100644 (file)
@@ -79,11 +79,11 @@ namespace System.Text.RegularExpressions
             int scan;
             int match;
 
-            for (; ;)
+            while (true)
             {
                 // find an internal char (examine) that matches the tail
 
-                for (; ;)
+                while (true)
                 {
                     if (examine == beforefirst)
                         goto OuterloopBreak;
@@ -97,7 +97,7 @@ namespace System.Text.RegularExpressions
 
                 // find the length of the match
 
-                for (; ;)
+                while (true)
                 {
                     if (scan == beforefirst || pattern[match] != pattern[scan])
                     {
@@ -283,7 +283,7 @@ namespace System.Text.RegularExpressions
             int advance;
             int[] unicodeLookup;
 
-            for (; ;)
+            while (true)
             {
                 if (test >= endlimit || test < beglimit)
                     return -1;
@@ -309,7 +309,7 @@ namespace System.Text.RegularExpressions
                     test2 = test;
                     match = startmatch;
 
-                    for (; ;)
+                    while (true)
                     {
                         if (match == endmatch)
                             return (RightToLeft ? test2 + 1 : test2);
index f70cfd3..283ec6f 100644 (file)
@@ -79,7 +79,7 @@ namespace System.Text.RegularExpressions
             RegexNode concatNode = null;
             int nextChild = 0;
 
-            for (; ;)
+            while (true)
             {
                 switch (curNode.NType)
                 {
@@ -160,7 +160,7 @@ namespace System.Text.RegularExpressions
 
             curNode = tree.Root;
 
-            for (; ;)
+            while (true)
             {
                 switch (curNode.NType)
                 {
@@ -312,7 +312,7 @@ namespace System.Text.RegularExpressions
             RegexNode curNode = tree.Root;
             int curChild = 0;
 
-            for (; ;)
+            while (true)
             {
                 if (curNode.Children == null)
                 {
index 4e85054..08da600 100644 (file)
@@ -451,7 +451,7 @@ namespace System.Text.RegularExpressions
             Goto(0);
 
             int advance = -1;
-            for (; ;)
+            while (true)
             {
                 if (advance >= 0)
                 {
index 5e5f76f..357a4d3 100644 (file)
@@ -246,7 +246,7 @@ namespace System.Text.RegularExpressions
             int min = M;
             int max = N;
 
-            for (; ;)
+            while (true)
             {
                 if (u.ChildCount() == 0)
                     break;
@@ -337,7 +337,7 @@ namespace System.Text.RegularExpressions
                 if (j < i)
                     Children[j] = at;
 
-                for (; ;)
+                while (true)
                 {
                     if (at.NType == Alternate)
                     {
@@ -649,7 +649,7 @@ namespace System.Text.RegularExpressions
 
             Debug.WriteLine(CurNode.Description());
 
-            for (; ;)
+            while (true)
             {
                 if (CurNode.Children != null && CurChild < CurNode.Children.Count)
                 {
index a972693..3b22b77 100644 (file)
@@ -490,7 +490,7 @@ namespace System.Text.RegularExpressions
         {
             _concatenation = new RegexNode(RegexNode.Concatenate, _options);
 
-            for (; ;)
+            while (true)
             {
                 int c = CharsRight();
                 if (c == 0)
@@ -716,7 +716,7 @@ namespace System.Text.RegularExpressions
 
             MoveRight();
 
-            for (; ;)
+            while (true)
             {
                 if (CharsRight() == 0)
                     break;
@@ -958,7 +958,7 @@ namespace System.Text.RegularExpressions
         {
             if (UseOptionX())
             {
-                for (; ;)
+                while (true)
                 {
                     while (CharsRight() > 0 && IsSpace(RightChar()))
                         MoveRight();
@@ -986,7 +986,7 @@ namespace System.Text.RegularExpressions
             }
             else
             {
-                for (; ;)
+                while (true)
                 {
                     if (CharsRight() < 3 || RightChar(2) != '#' ||
                         RightChar(1) != '?' || RightChar() != '(')
@@ -1993,7 +1993,7 @@ namespace System.Text.RegularExpressions
 
             int pos = startpos;
             int nChars = CharsRight();
-            while (--nChars > 0 && (ch = CharAt(++pos)) >= '0' && ch <= '9') ;
+            while (--nChars > 0 && (ch = CharAt(++pos)) >= '0' && ch <= '9');
 
             if (nChars == 0 || pos - startpos == 1)
                 return false;
@@ -2004,7 +2004,7 @@ namespace System.Text.RegularExpressions
             if (ch != ',')
                 return false;
 
-            while (--nChars > 0 && (ch = CharAt(++pos)) >= '0' && ch <= '9') ;
+            while (--nChars > 0 && (ch = CharAt(++pos)) >= '0' && ch <= '9');
 
             return nChars > 0 && ch == '}';
         }
index 7fd53e5..11c86a0 100644 (file)
@@ -127,7 +127,7 @@ namespace System.Text.RegularExpressions
 
             StartTimeoutWatch();
 
-            for (; ;)
+            while (true)
             {
 #if DEBUG
                 if (runregex.Debug)
index df2236c..eda301d 100644 (file)
@@ -103,7 +103,7 @@ namespace System.Text.RegularExpressions
 
             Emit(RegexCode.Lazybranch, 0);
 
-            for (; ; )
+            while (true)
             {
                 if (curNode.Children == null)
                 {
index 5a7498e..6772ead 100644 (file)
@@ -638,7 +638,7 @@ namespace System.Threading.Tasks.Dataflow.Internal
 
             // We'll bail out of this loop either when we have reserved a message (true)
             // or when we have exhausted the list of postponed messages (false)
-            for (; ;)
+            while (true)
             {
                 // Try to reserve the popped message
                 if (next.Key.ReserveMessage(next.Value, this))