Esempio n. 1
0
void parse_ConstDeclList() {
  /* <ConstDeclList> -> <ConstDecl> <ConstDeclList> | ε */
  printf("Enter ConstDeclList\n");
  if (nextToken == T_CONST) { /* First(<ConstDecl>) */
    parse_ConstDecl();
    parse_ConstDeclList();
  }
  printf("Exit  ConstDeclList\n");
}
Esempio n. 2
0
void parse_Decl() {
  printf("Enter Decl\n");
  if (nextToken == T_CONST) {
    parse_ConstDecl();
    parse_Decl();
  } else if (nextToken == T_VAR) {
    parse_VarDecl();
    parse_Decl();
  } else if (nextToken == T_FUNC) {
    parse_FuncDecl();
    parse_Decl();
  } else {
  }
}