Mercurial > hg > index.cgi
diff lwasm/lwasm.c @ 158:8dead67ba607
Make constant sections always resolve with a constant base offset of zero instead of an undefined reference
author | lost@l-w.ca |
---|---|
date | Sun, 28 Aug 2011 14:16:10 -0600 |
parents | 697bc543368c |
children | 348e2816ce32 |
line wrap: on
line diff
--- a/lwasm/lwasm.c Sun Aug 28 11:45:38 2011 -0600 +++ b/lwasm/lwasm.c Sun Aug 28 14:16:10 2011 -0600 @@ -102,6 +102,8 @@ asmstate_t *as = priv; if (as -> exportcheck && ptr == as -> csect) return lw_expr_build(lw_expr_type_int, 0); + if (((sectiontab_t *)ptr) -> flags & section_flag_constant) + return lw_expr_build(lw_expr_type_int, 0); return NULL; }