// Token: 0x0600165C RID: 5724 RVA: 0x00046A08 File Offset: 0x00044C08 internal bool GetNextDigit() { int num = this.Index + 1; this.Index = num; return(num < this.len && DateTimeParse.IsDigit(this.Value[this.Index])); }
internal bool GetNextDigit() { if (++this.Index >= this.len) { return(false); } return(DateTimeParse.IsDigit(this.Value[this.Index])); }
internal void GetRegularToken(out TokenType tokenType, out int tokenValue, DateTimeFormatInfo dtfi) { tokenValue = 0; if (this.Index >= this.len) { tokenType = TokenType.EndOfString; } else { tokenType = TokenType.UnknownToken; while (!DateTimeParse.IsDigit(this.m_current)) { if (char.IsWhiteSpace(this.m_current)) { label_18: int num = this.Index + 1; this.Index = num; if (num < this.len) { this.m_current = this.Value[this.Index]; if (char.IsWhiteSpace(this.m_current)) { goto label_18; } } else { tokenType = TokenType.EndOfString; return; } } else { dtfi.Tokenize(TokenType.RegularTokenMask, out tokenType, out tokenValue, ref this); return; } } tokenValue = (int)this.m_current - 48; int num1 = this.Index; while (true) { int num2 = this.Index + 1; this.Index = num2; if (num2 < this.len) { this.m_current = this.Value[this.Index]; int num3 = (int)this.m_current - 48; if (num3 >= 0 && num3 <= 9) { // ISSUE: explicit reference operation // ISSUE: variable of a reference type int& local = @tokenValue; // ISSUE: explicit reference operation int num4 = ^ local * 10 + num3;
internal TokenType GetSeparatorToken(DateTimeFormatInfo dtfi, out int indexBeforeSeparator, out char charBeforeSeparator) { indexBeforeSeparator = this.Index; charBeforeSeparator = this.m_current; if (!this.SkipWhiteSpaceCurrent()) { return(TokenType.SEP_End); } if (!DateTimeParse.IsDigit(this.m_current)) { TokenType type; int num; if (!dtfi.Tokenize(TokenType.SeparatorTokenMask, out type, out num, ref this)) { type = TokenType.SEP_Space; } return(type); } return(TokenType.SEP_Space); }
internal void GetRegularToken(out TokenType tokenType, out int tokenValue, DateTimeFormatInfo dtfi) { tokenValue = 0; if (this.Index >= this.len) { tokenType = TokenType.EndOfString; return; } tokenType = TokenType.UnknownToken; IL_19: while (!DateTimeParse.IsDigit(this.m_current)) { if (char.IsWhiteSpace(this.m_current)) { for (;;) { int num = this.Index + 1; this.Index = num; if (num >= this.len) { break; } this.m_current = this.Value[this.Index]; if (!char.IsWhiteSpace(this.m_current)) { goto IL_19; } } tokenType = TokenType.EndOfString; return; } dtfi.Tokenize(TokenType.RegularTokenMask, out tokenType, out tokenValue, ref this); return; } tokenValue = (int)(this.m_current - '0'); int index = this.Index; for (;;) { int num = this.Index + 1; this.Index = num; if (num >= this.len) { break; } this.m_current = this.Value[this.Index]; int num2 = (int)(this.m_current - '0'); if (num2 < 0 || num2 > 9) { break; } tokenValue = tokenValue * 10 + num2; } if (this.Index - index > 8) { tokenType = TokenType.NumberToken; tokenValue = -1; } else if (this.Index - index < 3) { tokenType = TokenType.NumberToken; } else { tokenType = TokenType.YearNumberToken; } if (!this.m_checkDigitToken) { return; } int index2 = this.Index; char current = this.m_current; this.Index = index; this.m_current = this.Value[this.Index]; TokenType tokenType2; int num3; if (dtfi.Tokenize(TokenType.RegularTokenMask, out tokenType2, out num3, ref this)) { tokenType = tokenType2; tokenValue = num3; return; } this.Index = index2; this.m_current = current; }
internal void GetRegularToken(out TokenType tokenType, out int tokenValue, DateTimeFormatInfo dtfi) { tokenValue = 0; if (this.Index >= this.len) { tokenType = TokenType.EndOfString; return; } tokenType = TokenType.UnknownToken; Label_0019: if (!DateTimeParse.IsDigit(this.m_current)) { if (char.IsWhiteSpace(this.m_current)) { while (++this.Index < this.len) { this.m_current = this.Value[this.Index]; if (!char.IsWhiteSpace(this.m_current)) { goto Label_0019; } } tokenType = TokenType.EndOfString; return; } dtfi.Tokenize(TokenType.RegularTokenMask, out tokenType, out tokenValue, ref this); } else { tokenValue = this.m_current - '0'; int index = this.Index; while (++this.Index < this.len) { this.m_current = this.Value[this.Index]; int num = this.m_current - '0'; if ((num < 0) || (num > 9)) { break; } tokenValue = (tokenValue * 10) + num; } if ((this.Index - index) > 8) { tokenType = TokenType.NumberToken; tokenValue = -1; } else if ((this.Index - index) < 3) { tokenType = TokenType.NumberToken; } else { tokenType = TokenType.YearNumberToken; } if (this.m_checkDigitToken) { TokenType type; int num4; int num3 = this.Index; char current = this.m_current; this.Index = index; this.m_current = this.Value[this.Index]; if (dtfi.Tokenize(TokenType.RegularTokenMask, out type, out num4, ref this)) { tokenType = type; tokenValue = num4; return; } this.Index = num3; this.m_current = current; } } }