fix type annotation for comparison expressions
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
#include <stdbool.h>
|
||||
|
||||
int eq(int x, int y);
|
||||
int neq(int x, int y);
|
||||
int lt(int x, int y);
|
||||
int lte(int x, int y);
|
||||
int gt(int x, int y);
|
||||
int gte(int x, int y);
|
||||
bool eq(int x, int y);
|
||||
bool neq(int x, int y);
|
||||
bool lt(int x, int y);
|
||||
bool lte(int x, int y);
|
||||
bool gt(int x, int y);
|
||||
bool gte(int x, int y);
|
||||
|
||||
bool and(bool a, bool b);
|
||||
bool or(bool a, bool b);
|
||||
|
||||
@@ -109,27 +109,27 @@ function fac(x: int): int {
|
||||
return 1;
|
||||
}
|
||||
|
||||
function eq(x: int, y: int): int {
|
||||
function eq(x: int, y: int): bool {
|
||||
return (x == y);
|
||||
}
|
||||
|
||||
function neq(x: int, y: int): int {
|
||||
function neq(x: int, y: int): bool {
|
||||
return (x != y);
|
||||
}
|
||||
|
||||
function lt(x: int, y: int): int {
|
||||
function lt(x: int, y: int): bool {
|
||||
return (x < y);
|
||||
}
|
||||
|
||||
function lte(x: int, y: int): int {
|
||||
function lte(x: int, y: int): bool {
|
||||
return (x <= y);
|
||||
}
|
||||
|
||||
function gt(x: int, y: int): int {
|
||||
function gt(x: int, y: int): bool {
|
||||
return (x > y);
|
||||
}
|
||||
|
||||
function gte(x: int, y: int): int {
|
||||
function gte(x: int, y: int): bool {
|
||||
return (x >= y);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user