From e036133d1be1ac87af29ce145052884c2c025ffa Mon Sep 17 00:00:00 2001 From: Daniel Kirchner Date: Mon, 5 Nov 2018 23:52:45 +0100 Subject: Fix negative denominator in ``boost::rational`` during exponentiation. --- .../syntaxTests/types/rational_negative_numerator_negative_exp.sol | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 test/libsolidity/syntaxTests/types/rational_negative_numerator_negative_exp.sol (limited to 'test') diff --git a/test/libsolidity/syntaxTests/types/rational_negative_numerator_negative_exp.sol b/test/libsolidity/syntaxTests/types/rational_negative_numerator_negative_exp.sol new file mode 100644 index 00000000..b694992c --- /dev/null +++ b/test/libsolidity/syntaxTests/types/rational_negative_numerator_negative_exp.sol @@ -0,0 +1,5 @@ +contract C { + function f() public pure returns (int) { + return (-1 / 2) ** -1; + } +} -- cgit v1.2.3