예제 #1
0
파일: repl.c 프로젝트: oguzalb/Fayton
int main(int argc, char* argv[]) {
    init_interpreter();
    if (argc == 1)
        repl_loop();
    else if (argc == 2)
        return interpret_main(argv[1]);
    else {
        printf("Takes an argument or no argument");
        return 0;
    }
    return 0;
}
예제 #2
0
파일: srepl.c 프로젝트: atomontage/sphia
static void
error (repl_session_t *sess, char *err) {
  fprintf(sess->stderr, "error: '%s'\n", err);
  repl_loop(sess);
}
예제 #3
0
파일: srepl.c 프로젝트: atomontage/sphia
static void
print (repl_session_t *sess, char *buf) {
  fprintf(sess->stdout, "%s\n", buf);
  repl_loop(sess);
}