22 writes to Chars
dotnet-svcutil-lib (1)
FrameworkFork\Microsoft.Xml\Xml\schema\XsdDuration.cs (1)
466sb[idx] = (char)(digit + '0');
Microsoft.Build (2)
Construction\Solution\SolutionProjectGenerator.cs (1)
616builder[i] = '_';
Logging\BinaryLogger\BuildEventArgsReader.cs (1)
1962stringBuilder[i] = ch;
Microsoft.Build.Utilities.Core (1)
ToolTask.cs (1)
1755sb[i] = Path.DirectorySeparatorChar;
Microsoft.CodeAnalysis (1)
CaseInsensitiveComparison.cs (1)
398builder[i] = ToLower(builder[i]);
Microsoft.NET.Build.Containers (2)
ContainerHelpers.cs (2)
324builder[i] = char.ToLowerInvariant(current); 329builder[i] = '-';
Microsoft.TestPlatform.AdapterUtilities (2)
ManagedNameUtilities\ManagedNameHelper.Reflection.cs (2)
209methodBuilder[methodBuilder.Length - 1] = ')'; 559b[b.Length - 1] = '>';
Microsoft.VisualStudio.TestPlatform.Extensions.Trx.TestLogger (1)
Utility\TrxFileHelper.cs (1)
82result[i] = InvalidFileNameChars.Contains(fileName[i]) ? replacementChar : fileName[i];
Microsoft.Win32.Registry (2)
Microsoft\Win32\RegistryKey.cs (2)
1446path[i] = markerChar; 1465path[j] = path[i];
PresentationCore (1)
System\Windows\Media\mediaeventshelper.cs (1)
396stringBuilder[i] = (char)reader.ReadUInt16();
System.ComponentModel.TypeConverter (3)
System\ComponentModel\MaskedTextProvider.cs (3)
718_testString[position] = _promptChar; 1938_testString[testPosition] = _promptChar; 2071_testString[position] = input;
System.Private.CoreLib (2)
System\Reflection\Runtime\General\MetadataReaderExtensions.NativeFormat.cs (2)
618builder[front] = builder[back]; 619builder[back] = temp;
System.Private.Xml (4)
System\Xml\Xsl\QIL\QilXmlWriter.cs (4)
383_name[_len] = _start; 386_name[i] = _start; 394_name[i]++; 397_name[_len] = ++c;
124 references to Chars
aspire (9)
Utils\Markdown\MarkdownToSpectreConverter.cs (8)
86while (builder.Length > contentStart && char.IsWhiteSpace(builder[builder.Length - 1])) 92while (builder.Length > contentStart && char.IsWhiteSpace(builder[contentStart])) 110if (builder[index] == '\n') 131if (builder[index] != '\n') 137if (nextIndex < builder.Length && builder[nextIndex] != '\n') 153if (builder[contentStart] != '\n') 160if (builder[index] != '\n') 166if (nextIndex < builder.Length && builder[nextIndex] != '\n')
Utils\Markdown\MarkdownToSpectreConverter.Markup.cs (1)
248while (builder.Length > start && builder[builder.Length - 1] == '\n')
dotnet-svcutil-lib (4)
FrameworkFork\Microsoft.Xml\Xml\schema\XsdDuration.cs (2)
481if (sb[sb.Length - 1] == 'P') 487if (sb[sb.Length - 1] == 'P')
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\CodeExporter.cs (2)
1451if (builder[builder.Length - 1] == '.') 1479|| (builder.Length > 1 && builder[builder.Length - 1] != '.')))
Microsoft.AspNetCore.InternalTesting (1)
TestFileOutputContext.cs (1)
131if (sb.Length > 0 && sb[sb.Length - 1] != '_')
Microsoft.AspNetCore.Razor.Utilities.Shared (2)
src\roslyn\src\Razor\src\Shared\Microsoft.AspNetCore.Razor.SharedUtilities\StringBuilderExtensions.cs (2)
25while (start < builder.Length && char.IsWhiteSpace(builder[start])) 31while (end >= start && char.IsWhiteSpace(builder[end]))
Microsoft.AspNetCore.Routing (1)
UriBuildingContext.cs (1)
253if (AppendTrailingSlash && _path[_path.Length - 1] != '/')
Microsoft.Build (1)
Construction\Solution\SolutionProjectGenerator.cs (1)
614if (!XmlUtilities.IsValidSubsequentElementNameCharacter(builder[i]))
Microsoft.Build.Tasks.CodeAnalysis (1)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\CommandLineUtilities.cs (1)
145if (quoteCount == 2 && builder[0] == '"' && builder[builder.Length - 1] == '"')
Microsoft.Build.Tasks.Core (3)
CreateManifestResourceName.cs (1)
372if ((builder.Length - length) == 1 && builder[length] == '_')
GenerateResource.cs (1)
3709if (name[name.Length - 1] == ' ')
ManifestUtil\Util.cs (1)
96if (sb[i] < ' ')
Microsoft.Build.Utilities.Core (3)
CommandLineBuilder.cs (1)
222else if (CommandLine[CommandLine.Length - 1] != ' ')
ToolTask.cs (2)
1753if (sb[i] == '\\' && (i == length - 1 || sb[i + 1] != '"'))
Microsoft.CodeAnalysis (7)
CaseInsensitiveComparison.cs (1)
398builder[i] = ToLower(builder[i]);
InternalUtilities\CommandLineUtilities.cs (1)
145if (quoteCount == 2 && builder[0] == '"' && builder[builder.Length - 1] == '"')
Syntax\SyntaxDiffer.cs (4)
801if (oldText[commonLeadingCount] != newText[commonLeadingCount]) 813if (oldText[oldText.Length - commonTrailingCount - 1] != newText[newText.Length - commonTrailingCount - 1])
Text\StringBuilderText.cs (1)
70return _builder[position];
Microsoft.CodeAnalysis.Analyzers (2)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\Hash.cs (1)
340hashCode = unchecked((hashCode ^ text[i]) * Hash.FnvPrime);
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\StringTable.cs (1)
519if (array[i] != text[i])
Microsoft.CodeAnalysis.AnalyzerUtilities (2)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\Hash.cs (1)
340hashCode = unchecked((hashCode ^ text[i]) * Hash.FnvPrime);
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\StringTable.cs (1)
519if (array[i] != text[i])
Microsoft.CodeAnalysis.CodeStyle (2)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\Hash.cs (1)
340hashCode = unchecked((hashCode ^ text[i]) * Hash.FnvPrime);
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\StringTable.cs (1)
519if (array[i] != text[i])
Microsoft.CodeAnalysis.CSharp (1)
Symbols\Source\SourceNamedTypeSymbol_Extension.cs (1)
103if (builder[builder.Length - 1] == ' ')
Microsoft.CodeAnalysis.CSharp.Features (2)
ConvertToRawString\ConvertInterpolatedStringToRawStringCodeRefactoringProvider.cs (2)
619while (SyntaxFacts.IsNewLine(builder[beforeNewLines - 1])) 623while (SyntaxFacts.IsWhitespace(builder[beforeSpaces - 1]))
Microsoft.CodeAnalysis.Extensions.Package (1)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\Hash.cs (1)
340hashCode = unchecked((hashCode ^ text[i]) * Hash.FnvPrime);
Microsoft.CodeAnalysis.ResxSourceGenerator (2)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\Hash.cs (1)
340hashCode = unchecked((hashCode ^ text[i]) * Hash.FnvPrime);
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\StringTable.cs (1)
519if (array[i] != text[i])
Microsoft.Extensions.FileProviders.Embedded (1)
EmbeddedFileProvider.cs (1)
279if ((builder.Length - length) == 1 && builder[length] == '_')
Microsoft.Extensions.Telemetry (1)
Http\HttpRouteFormatter.cs (1)
164if (formattedHttpPath[index] == ForwardSlashSymbol)
Microsoft.Maui.Controls (1)
Shapes\PathFigureCollectionConverter.cs (1)
668 if (sb[sb.Length - 1] == ' ')
Microsoft.Maui.Controls.Xaml (1)
MarkupExpressionParser.cs (1)
228 while (piece.Length > 0 && char.IsWhiteSpace(piece[piece.Length - 1]))
Microsoft.ML.Core (7)
CommandLine\CmdLexer.cs (4)
335if (sb[ich] == '{') 357if (sb[ichSrc] != sb[ichSrc + cch]) 453if (sb[ichDst + ichSrc] != str[ichSrc])
Utilities\Hashing.cs (2)
293uint ch = toUpper ? char.ToUpperInvariant(data[ich]) : data[ich];
Utilities\NormStr.cs (1)
190if (value.Span[ich] != sb[ich])
Microsoft.ML.Data (1)
DataLoadSave\Text\TextSaver.cs (1)
639if (sb[ich] != def[ich])
Microsoft.ML.Transforms (1)
Expression\Lexer.cs (1)
349u = checked(u * 10 + (ulong)LexCharUtils.GetDecVal(_sb[ich]));
Microsoft.TemplateEngine.Orchestrator.RunnableProjects (1)
ValueForms\DefaultSafeNamespaceValueFormFactory.cs (1)
35bool isFirstCharacterOfIdentifier = safeValueStr.Length == 0 || safeValueStr[safeValueStr.Length - 1] == '.';
Microsoft.TestPlatform.CommunicationUtilities (1)
Json\Jsonite\Jsonite.cs (1)
795intNumber = intNumber * 10 + (builder[i] - '0');
Microsoft.VisualBasic.Core (1)
Microsoft\VisualBasic\CompilerServices\Utils.LateBinder.vb (1)
173sb.Chars(iIndex) = chPeriod ' change decimal separator to "."
Microsoft.Win32.Registry (5)
Microsoft\Win32\RegistryKey.cs (5)
1422if (temp >= 0 && sb[temp] == '\\') // Remove trailing slash 1441if (path[i] == '\\') 1444while (i < length && path[i] == '\\') 1460if (path[i] == markerChar) 1465path[j] = path[i];
PresentationBuildTasks (3)
src\wpf\src\Microsoft.DotNet.Wpf\src\PresentationFramework\System\Windows\Markup\MarkupExtensionParser.cs (1)
1185while(Char.IsWhiteSpace(sb[i]))
src\wpf\src\Microsoft.DotNet.Wpf\src\PresentationFramework\System\Windows\Markup\XamlReaderHelper.cs (2)
1263if (!IsWhiteSpace(textValueStringBuilder[i])) 1280char lastChar = textValueStringBuilder[textValueStringBuilder.Length - 1];
PresentationCore (1)
System\Windows\Media\GlyphsSerializer.cs (1)
143if (sb[trailingCharIndex] != trailingCharacter)
PresentationFramework (3)
System\Windows\Documents\RtfToXamlReader.cs (2)
8444if (sb[uriIndex] == '\\' && uriIndex + 1 < sb.Length && sb[uriIndex + 1] == '\\')
System\Windows\Markup\MarkupExtensionParser.cs (1)
1185while(Char.IsWhiteSpace(sb[i]))
ReachFramework (2)
MS\Internal\Printing\Configuration\COMPSTUISRID.cs (2)
44if (resString[i] == '&') 46char next = resString[i + 1];
Roslyn.Diagnostics.Analyzers (2)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\Hash.cs (1)
340hashCode = unchecked((hashCode ^ text[i]) * Hash.FnvPrime);
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\StringTable.cs (1)
519if (array[i] != text[i])
System.ComponentModel.TypeConverter (13)
System\ComponentModel\MaskedTextProvider.cs (13)
496clonedProvider.Replace(_testString[position], position); 797return _testString[index]; 1315if (!TestChar(_testString[srcPos], dstPos, out tempHint)) 1353SetChar(_testString[srcPos], dstPos); 1591char srcCh = _testString[srcPos]; 1631char srcCh = _testString[srcPos]; 1888if (!TestChar(_testString[srcPos], dstPos, out tempHint)) 1914SetChar(_testString[srcPos], dstPos); 2178if (SkipLiterals && (input == _testString[position])) 2330if (input == _testString[position] && charDex.IsAssigned) // setting char would not make any difference 2358return SkipLiterals && input == _testString[position]; 2494st.Append(IsEditPosition(chDex) && chDex.IsAssigned ? _passwordChar : _testString[position]); 2624char ch = _testString[index];
System.Data.Common (4)
src\runtime\src\libraries\Common\src\System\Data\Common\DbConnectionOptions.Common.cs (3)
152while ((0 < count) && char.IsWhiteSpace(buffer[count - 1])) 165while ((index < count) && char.IsWhiteSpace(buffer[index])) 169while ((0 < count) && char.IsWhiteSpace(buffer[count - 1]))
System\Data\Common\DbConnectionOptions.cs (1)
69if ((0 < builder.Length) && (';' != builder[builder.Length - 1]))
System.Data.Odbc (4)
Common\System\Data\Common\DbConnectionOptions.cs (1)
131if ((0 < builder.Length) && (';' != builder[builder.Length - 1]))
src\runtime\src\libraries\Common\src\System\Data\Common\DbConnectionOptions.Common.cs (3)
152while ((0 < count) && char.IsWhiteSpace(buffer[count - 1])) 165while ((index < count) && char.IsWhiteSpace(buffer[index])) 169while ((0 < count) && char.IsWhiteSpace(buffer[count - 1]))
System.Data.OleDb (4)
DbConnectionOptions.cs (4)
196if ((0 < builder.Length) && (';' != builder[builder.Length - 1])) 505while ((0 < count) && char.IsWhiteSpace(buffer[count - 1])) 518while ((index < count) && char.IsWhiteSpace(buffer[index])) 522while ((0 < count) && char.IsWhiteSpace(buffer[count - 1]))
System.Diagnostics.Process (3)
System\Diagnostics\AsyncStreamReader.cs (3)
166char ch = _sb[currentIndex]; 174if ((ch == '\r') && (lineStart < len) && (_sb[lineStart] == '\n')) 187if ((len > 0) && _sb[len - 1] == '\r')
System.DirectoryServices.AccountManagement (1)
System\DirectoryServices\AccountManagement\AD\ADUtils.cs (1)
129if (sb[sb.Length - 1] == ' ')
System.IO.Ports (1)
System\IO\Ports\SerialPort.cs (1)
1115if (value[value.Length - i] != currentLine[currentLine.Length - i])
System.Net.Primitives (1)
System\Net\Cookie.cs (1)
700if (afterLength == (1 + beforeLength) && sb[beforeLength] == '=')
System.Private.CoreLib (9)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\CharUnicodeInfo.cs (2)
63int c = (int)s[index]; 69int temp2 = (int)s[index + 1] - LOW_SURROGATE_START; // temp2 = 000000xxxxxxxxxx
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\IdnMapping.cs (2)
880if (char.IsSurrogate(output[iUseInsertLocation])) 916if (char.IsLowSurrogate(output[iTest]))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\StringBuilder.cs (3)
2919? [this[index], this[index + 1]] 2920: [this[index]];
System\Reflection\Runtime\General\MetadataReaderExtensions.NativeFormat.cs (2)
617char temp = builder[front]; 618builder[front] = builder[back];
System.Private.Xml (2)
System\Xml\Xsl\QIL\QilXmlWriter.cs (2)
380char c = _name[_len]; 385for (; i-- > _zero && _name[i] == _end;)
System.Runtime.Serialization.Schema (2)
System\Runtime\Serialization\Schema\CodeExporter.cs (2)
1565if (builder[builder.Length - 1] == '.') 1593|| (builder.Length > 1 && builder[builder.Length - 1] != '.')))
System.Security.Cryptography.Xml (1)
System\Security\Cryptography\Xml\Utils.cs (1)
164if (sb[i] == oldChar)
System.ServiceModel.Syndication (1)
System\ServiceModel\Syndication\DateTimeHelper.cs (1)
81for (timeZoneStartIndex = dateTimeStringBuilder.Length - 1; dateTimeStringBuilder[timeZoneStartIndex] != ' '; timeZoneStartIndex--)
System.Speech (1)
Result\RecognizedPhrase.cs (1)
118while (sb.Length > 0 && sb[sb.Length - 1] == ' ')
System.Xaml (1)
System\Xaml\Parser\XamlText.cs (1)
134if (IsWhitespaceChar(_sb[_sb.Length-1]))