Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ RemoveLeadingInQuoteSpaces()

void System.__DTString.RemoveLeadingInQuoteSpaces ( )
inlinepackage

Definition at line 393 of file __DTString.cs.

394 {
395 if (Length <= 2)
396 {
397 return;
398 }
399 int i = 0;
400 char c = Value[i];
401 if (c == '\'' || c == '"')
402 {
403 for (; i + 1 < Length && char.IsWhiteSpace(Value[i + 1]); i++)
404 {
405 }
406 if (i != 0)
407 {
408 Span<char> span = new char[Value.Length - i];
409 span[0] = c;
410 Value.Slice(i + 1).CopyTo(span.Slice(1));
411 Value = span;
412 }
413 }
414 }
ReadOnlySpan< T > Slice(int start)
ReadOnlySpan< char > Value
Definition __DTString.cs:8

References System.__DTString.Length, System.ReadOnlySpan< T >.Slice(), System.Span< T >.Slice(), and System.__DTString.Value.