diff options
| author | Tim Foley <tim.foley.is@gmail.com> | 2017-08-09 11:20:09 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-08-09 11:20:09 -0700 |
| commit | 6e4830f4d74adef0a47c6503d84dc114240fafa3 (patch) | |
| tree | 4f549da8c05be186f12442565389d9f3df44c6d7 /source/slang/lexer.cpp | |
| parent | 8e4c0c35d6c2d0fd754b713441c2eee8f13f87b2 (diff) | |
| parent | 695c2700de54a5fec72ce7214c137a1dc3a02d7b (diff) | |
Merge pull request #155 from tfoleyNV/renaming
Major naming overhaul:
Diffstat (limited to 'source/slang/lexer.cpp')
| -rw-r--r-- | source/slang/lexer.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/source/slang/lexer.cpp b/source/slang/lexer.cpp index 49856c1c9..84b34c9a9 100644 --- a/source/slang/lexer.cpp +++ b/source/slang/lexer.cpp @@ -18,7 +18,7 @@ namespace Slang Token* TokenList::end() const { SLANG_ASSERT(mTokens.Count()); - SLANG_ASSERT(mTokens[mTokens.Count()-1].Type == TokenType::EndOfFile); + SLANG_ASSERT(mTokens[mTokens.Count()-1].type == TokenType::EndOfFile); return &mTokens[mTokens.Count() - 1]; } @@ -40,7 +40,7 @@ namespace Slang Token token = *mCursor; if (mCursor == mEnd) - token.Type = TokenType::EndOfFile; + token.type = TokenType::EndOfFile; return token; } @@ -49,7 +49,7 @@ namespace Slang if (mCursor == mEnd) return TokenType::EndOfFile; SLANG_ASSERT(mCursor); - return mCursor->Type; + return mCursor->type; } CodePosition TokenReader::PeekLoc() const @@ -67,7 +67,7 @@ namespace Slang Token token = *mCursor; if (mCursor == mEnd) - token.Type = TokenType::EndOfFile; + token.type = TokenType::EndOfFile; else mCursor++; return token; @@ -774,8 +774,8 @@ namespace Slang String getStringLiteralTokenValue(Token const& token) { - SLANG_ASSERT(token.Type == TokenType::StringLiteral - || token.Type == TokenType::CharLiteral); + SLANG_ASSERT(token.type == TokenType::StringLiteral + || token.type == TokenType::CharLiteral); char const* cursor = token.Content.begin(); char const* end = token.Content.end(); @@ -1244,7 +1244,7 @@ namespace Slang break; } - token.Type = tokenType; + token.type = tokenType; char const* textEnd = cursor; @@ -1303,7 +1303,7 @@ namespace Slang Token token = lexToken(); tokenList.mTokens.Add(token); - if(token.Type == TokenType::EndOfFile) + if(token.type == TokenType::EndOfFile) return tokenList; } } |
