Ejemplo n.º 1
0
 public TokenCollection Read(string script)
 {
     if (CurrentInterpreter != null)
     {
         StringTokenReader reader = new StringTokenReader(script);
         List <string>     rlt    = new List <string>();
         while (true)
         {
             Token token = reader.ReadNextToken();
             if (token == null)
             {
                 break;
             }
             else
             {
                 token.LineNumber = reader.LineNumber;
             }
         }
         CurrentInterpreter.tokens = reader.Tokens;
         return(reader.Tokens);
     }
     return(null);
 }
Ejemplo n.º 2
0
		public TokenCollection Read(string script)
		{
			if (CurrentInterpreter != null)
			{
				StringTokenReader reader = new StringTokenReader(script);
				List<string> rlt = new List<string>();
				while (true)
				{
					Token token = reader.ReadNextToken();
					if (token == null)
					{
						break;
					}
					else
					{
						token.LineNumber = reader.LineNumber;
					}
				}
				CurrentInterpreter.tokens = reader.Tokens;
				return reader.Tokens;
			}
			return null;
		}