diff --git a/source/toy_common.h b/source/toy_common.h index 67c52e4..88b2f08 100644 --- a/source/toy_common.h +++ b/source/toy_common.h @@ -5,8 +5,8 @@ #include #define TOY_VERSION_MAJOR 1 -#define TOY_VERSION_MINOR 0 -#define TOY_VERSION_PATCH 1 +#define TOY_VERSION_MINOR 1 +#define TOY_VERSION_PATCH 0 #define TOY_VERSION_BUILD __DATE__ " " __TIME__ //platform/compiler-specific instructions diff --git a/source/toy_literal.c b/source/toy_literal.c index abf17e7..28a7d67 100644 --- a/source/toy_literal.c +++ b/source/toy_literal.c @@ -241,10 +241,10 @@ bool Toy_literalsAreEqual(Toy_Literal lhs, Toy_Literal rhs) { // ints and floats are compatible if ((TOY_IS_INTEGER(lhs) || TOY_IS_FLOAT(lhs)) && (TOY_IS_INTEGER(rhs) || TOY_IS_FLOAT(rhs))) { if (TOY_IS_INTEGER(lhs)) { - return TOY_AS_INTEGER(lhs) + TOY_AS_FLOAT(rhs); + return TOY_AS_INTEGER(lhs) == TOY_AS_FLOAT(rhs); } else { - return TOY_AS_FLOAT(lhs) + TOY_AS_INTEGER(rhs); + return TOY_AS_FLOAT(lhs) == TOY_AS_INTEGER(rhs); } }