vlsi commented on a change in pull request #1057: [CALCITE-2854] code gen error 
for UNARY_MINUS operator call with deci…
URL: https://github.com/apache/calcite/pull/1057#discussion_r259274565
 
 

 ##########
 File path: core/src/test/java/org/apache/calcite/test/ReflectiveSchemaTest.java
 ##########
 @@ -953,13 +974,13 @@ public IntAndString(int id, String value) {
             false, (byte) 0, (char) 0, (short) 0, 0, 0L, 0F, 0D,
             false, (byte) 0, (char) 0, (short) 0, 0, 0L, 0F, 0D,
             new java.sql.Date(0), new Time(0), new Timestamp(0),
-            new Date(0), "1"),
+            new Date(0), "1", BigDecimal.valueOf(-1)),
         new EveryType(
             true, Byte.MAX_VALUE, Character.MAX_VALUE, Short.MAX_VALUE,
             Integer.MAX_VALUE, Long.MAX_VALUE, Float.MAX_VALUE,
             Double.MAX_VALUE,
             null, null, null, null, null, null, null, null,
-            null, null, null, null, null),
+            null, null, null, null, null, BigDecimal.valueOf(1.2)),
 
 Review comment:
   Please use `new BigDecimal("1.2")`
   The thing is `double` is rarely exact, and the value of 
`BigDecimal.valueOf(double)` might be unexpected

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to