comparison lwlib/lw_expr.c @ 12:6b9991fb39b6

Brought forward patch to fix bug with complex external references generating invalid relocations in the object file
author lost@l-w.ca
date Sat, 22 Jan 2011 16:11:15 -0700
parents 7317fbe024af
children 18b49cf10ae9
comparison
equal deleted inserted replaced
11:a0317b794b7b 12:6b9991fb39b6
1266 1266
1267 void *lw_expr_specptr(lw_expr_t e) 1267 void *lw_expr_specptr(lw_expr_t e)
1268 { 1268 {
1269 return e -> value2; 1269 return e -> value2;
1270 } 1270 }
1271
1272 int lw_expr_operandcount(lw_expr_t e)
1273 {
1274 int count = 0;
1275 struct lw_expr_opers *o;
1276
1277 if (e -> type != lw_expr_type_oper)
1278 return 0;
1279
1280 for (o = e -> operands; o; o = o -> next)
1281 count++;
1282
1283 return count;
1284 }