예제 #1
0
파일: mono.c 프로젝트: kmizumar/Mono
void main(void){
    int addr;
    
    initcell();
    initsubr();
    int ret = setjmp(buf);
    
    /*
    addr = read();
    dump(0,20);
    printf("addr=%d\n",addr);
    print(addr);
    */
    
        
    if(ret == 0)
        while(1){
                printf("Mono> "); fflush(stdout); fflush(stdin);
            print(eval(read ()));
            printf("\n"); fflush(stdout);
        }
    else
        return;

}
예제 #2
0
파일: mlis.c 프로젝트: kzfm1024/misc
int main(void){
    printf("MonoLis Ver0.01\n");
    initcell();
    initsubr();
    int ret = setjmp(buf);
    
    repl:   
    if(ret == 0)
        while(1){
            printf("> "); fflush(stdout); fflush(stdin);
            print(eval(read ()));
            printf("\n"); fflush(stdout);
        }
    else
        if(ret == 1){
            ret = 0;
            goto repl;
        }
        else
            return 0;
}
예제 #3
0
void main(void){
	printf("educational Lisp system Mono Ver0.24 (written by sasagawa888) \n");
    initcell();
    initsubr();
    SetConsoleCtrlHandler(NULL, FALSE ); //CTRL+Cを有効にする。
    SetConsoleCtrlHandler(CtrlHandler, TRUE );
    int ret = setjmp(buf);
    
    repl:
	
    if(ret == 0)
    	while(1){
			printf("Mono> "); fflush(stdout); fflush(stdin);
            print(eval(read ()));
            printf("\n"); fflush(stdout);
        }
    else
    	if(ret == 1){
        	ret = 0;
            goto repl;
        }
        else
    		return;
}