shithub: scc

Download patch

ref: d44b54b7da692ae72927eba4b12f22ce0779d82b
parent: 6bd855db77a9449f75562fd3fe5775143e498a2f
author: Roberto E. Vargas Caballero <k0ga@shike2.com>
date: Sun Apr 20 19:24:08 EDT 2014

Avoid initial assignment in typeconv()

This initial assignment was not needed since the result of
promote was assigned again.

--- a/expr.c
+++ b/expr.c
@@ -41,11 +41,11 @@
 typeconv(Node **p1, Node **p2)
 {
 	Type *tp1, *tp2;
-	Node *np1 = *p1, *np2 = *p2;
+	Node *np1, *np2;
 	uint8_t n;
 
-	np1 = promote(np1);
-	np2 = promote(np2);
+	np1 = promote(*p1);
+	np2 = promote(*p2);
 
 	tp1 = np1->utype;
 	tp2 = np2->utype;
--