toString() public static method

public static toString ( int type ) : string
type int
return string
コード例 #1
0
ファイル: ObjDecoder.cs プロジェクト: syatanic/fantom
 /// <summary>
 /// Check that the current token matches the specified
 /// type, but do not consume it.
 /// </summary>
 private void verify(int type, string expected)
 {
     if (curt != type)
     {
         throw err(expected + ", not '" + Token.toString(curt) + "'");
     }
 }
コード例 #2
0
ファイル: ObjDecoder.cs プロジェクト: syatanic/fantom
 /// <summary>
 /// Statements can be terminated with a semicolon, end of line or } end of block.
 /// </summary>
 private void endOfStmt(int lastLine)
 {
     if (curt == Token.EOF)
     {
         return;
     }
     if (curt == Token.SEMICOLON)
     {
         consume(); return;
     }
     if (lastLine < tokenizer.m_line)
     {
         return;
     }
     if (curt == Token.RBRACE)
     {
         return;
     }
     throw err("Expected end of statement: semicolon, newline, or end of block; not '" + Token.toString(curt) + "'");
 }