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

◆ AreRootsEqual()

static bool System.IO.PathInternal.AreRootsEqual ( string first,
string second,
StringComparison comparisonType )
inlinestaticpackage

Definition at line 122 of file PathInternal.cs.

123 {
124 int rootLength = GetRootLength(first.AsSpan());
125 int rootLength2 = GetRootLength(second.AsSpan());
126 if (rootLength == rootLength2)
127 {
128 return string.Compare(first, 0, second, 0, rootLength, comparisonType) == 0;
129 }
130 return false;
131 }
static int GetRootLength(ReadOnlySpan< char > path)

References System.comparisonType, and System.IO.PathInternal.GetRootLength().

Referenced by System.IO.Path.GetRelativePath().