예제 #1
0
파일: parser.c 프로젝트: probonopd/citron
/**
 * CTRParserStart
 *
 * Begins the parsing stage of a program.
 */
ctr_tnode *
ctr_cparse_parse (char *prg, char *pathString)
{
  ctr_tnode *program;
  ctr_clex_load (prg);
  char *oldp = ctr_cparse_current_program;
  ctr_cparse_current_program = pathString;
  program = ctr_cparse_program ();
  program->value = pathString;
  program->vlen = strlen (pathString);
  program->type = CTR_AST_NODE_PROGRAM;
  ctr_cparse_current_program = oldp;
  return program;
}
예제 #2
0
파일: parser.c 프로젝트: adamkao/citrine
/**
 * CTRParserStart
 *
 * Begins the parsing stage of a program.
 */
ctr_tnode*  ctr_dparse_parse(char* prg) {
	ctr_tnode* program;
	ctr_clex_load(prg);
	program = ctr_cparse_program();
	return program;
}