diff options
Diffstat (limited to 'bootstrap/cgen.c')
| -rw-r--r-- | bootstrap/cgen.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/bootstrap/cgen.c b/bootstrap/cgen.c index 15fab93..0887ca7 100644 --- a/bootstrap/cgen.c +++ b/bootstrap/cgen.c @@ -288,7 +288,10 @@ genexpr(struct expr *ex) { ++id; break; case Elen: - pri("%e.len", ex->child); + pri("%e%slen", ex->child, ex->child->ty->t == TYptr ? "->" : "."); + break; + case Eptr: + pri("%e%sptr", ex->child, ex->child->ty->t == TYptr ? "->" : "."); break; case Eeutag: pri("%e%st", ex->child, ex->child->ty->t == TYptr ? "->" : "."); @@ -518,7 +521,7 @@ liftnestedex(struct expr *ex) { case Eblock: liftnested(blocktostmt(ex->block)); break; - case Eas: case Elen: case Eeutag: + case Eas: case Elen: case Eeutag: case Eptr: liftnestedex(ex->child); break; case Eini: |