示例#1
0
 static void ReadStatement()
 {
     if (la.kind == read_Sym)
     {
         Get();
         Expect(lparen_Sym);
         ReadList();
         Expect(rparen_Sym);
     }
     else if (la.kind == readLine_Sym)
     {
         Get();
         Expect(lparen_Sym);
         if (la.kind == identifier_Sym || la.kind == stringLit_Sym)
         {
             ReadList();
         }
         Expect(rparen_Sym);
         CodeGen.ReadLine();
     }
     else
     {
         SynErr(49);
     }
     ExpectWeak(semicolon_Sym, 6);
 }