소스 검색

Print error in case of non-integer in arithmetic operation

pull/5/head
mtardy 4 년 전
부모
커밋
2128d6abf9
1개의 변경된 파일4개의 추가작업 그리고 0개의 파일을 삭제
  1. +4
    -0
      object.c

+ 4
- 0
object.c 파일 보기

@ -177,6 +177,10 @@ void println(oop ast);
int getInteger(oop obj)
{
if (!isInteger(obj)) {
fprintf(stderr, "\nNon-integer in arithmetic expression\n");
exit(1);
}
#if (USE_TAG)
return (intptr_t)obj >> 1;
#else

불러오는 중...
취소
저장