ソースを参照

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

読み込み中…
キャンセル
保存