Open GitBingo opened 7 years ago
InfInt numerator = 1; InfInt denominator = 2;
numerator += 2 * denominator;
The above statement crashes, the statement has to read
InfInt numerator = 1; InfInt denominator = 2; InfInt two = 2;
numerator += two * denominator;
InfInt int is implemented. So denominator 2 works. You could implement the operation as described here: https://stackoverflow.com/questions/1188566/operator-overloading-in-c-as-int-obj
InfInt numerator = 1; InfInt denominator = 2;
numerator += 2 * denominator;
The above statement crashes, the statement has to read
InfInt numerator = 1; InfInt denominator = 2; InfInt two = 2;
numerator += two * denominator;