]> git.rm.cloudns.org Git - xonotic/gmqcc.git/commitdiff
Less casts.
authorDale Weiler <killfieldengine@gmail.com>
Sat, 28 Sep 2013 10:36:00 +0000 (06:36 -0400)
committerDale Weiler <killfieldengine@gmail.com>
Sat, 28 Sep 2013 10:36:00 +0000 (06:36 -0400)
ast.c

diff --git a/ast.c b/ast.c
index 3fb27d30f917d687bbe2e43738f107e0bef976b5..ffef07990f3da24cde6f51691040958db21e2bf6 100644 (file)
--- a/ast.c
+++ b/ast.c
@@ -519,12 +519,12 @@ ast_unary* ast_unary_new(lex_ctx_t ctx, int op,
     self->operand = expr;
 
     if (ast_istype(expr, ast_unary)) {
-        ast_expression *prev = (ast_expression*)((ast_unary*)expr)->operand;
+        ast_unary *prev = (ast_unary*)((ast_unary*)expr)->operand;
         if (ast_istype(prev, ast_unary)) {
             ast_expression_delete((ast_expression*)self);
             mem_d(self);
             ++opts_optimizationcount[OPTIM_PEEPHOLE];
-            return (ast_unary*)prev;
+            return prev;
         }
     }