rafsun42 commented on code in PR #1123:
URL: https://github.com/apache/age/pull/1123#discussion_r1287696564


##########
src/backend/parser/cypher_gram.y:
##########
@@ -2008,29 +2010,37 @@ static Node *do_negate(Node *n, int location)
         // report the constant's location as that of the '-' sign
         c->location = location;
 
-        if (c->val.type == T_Integer)
+        if (c->val.ival.type == T_Integer)
         {
-            c->val.val.ival = -c->val.val.ival;
+            c->val.ival.ival = -c->val.ival.ival;
             return n;
         }
-        else if (c->val.type == T_Float)
+        else if (c->val.fval.type == T_Float)
         {
-            do_negate_float(&c->val);
+            do_negate_float(&c->val.fval);
             return n;
         }
     }
 
     return (Node *)makeSimpleA_Expr(AEXPR_OP, "-", NULL, n, location);
 }
 
-static void do_negate_float(Value *v)
+static void do_negate_float(Float *v)
 {
-    Assert(IsA(v, Float));

Review Comment:
   Is removal of `Assert` intentional?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to