2950 {
2951 int num = 0;
2952 result = -1;
2954 {
2956 {
2957 string dayName = dtfi.GetDayName(dayOfWeek);
2958 int matchLength = dayName.Length;
2959 if ((dtfi.HasSpacesInDayNames ?
str.MatchSpecifiedWords(dayName, checkWordBoundary: false, ref matchLength) :
str.MatchSpecifiedWord(dayName)) && matchLength > num)
2960 {
2961 num = matchLength;
2962 result = (int)dayOfWeek;
2963 }
2964 }
2965 }
2966 if (result >= 0)
2967 {
2968 str.Index += num - 1;
2969 return true;
2970 }
2971 return false;
2972 }