At this point some choices need to be made about lvalue stuff. In principle the idea is:
a) a var is actually a pointer b) mutation including assignment requires a pointer c) offset can be added to pointers to support mutation of sub components The question is what 'x' means given var x = 1; At present x means '1', that is it is an integer, and &x is allowed because x is (structurally) an lvalue. This means that as in C, X().member = 1; will never be allowed, since X() is not an lvalue. However *(expr ) is an lvalue. In this scheme there is only one lvalue requiring operation, namely &something We define x = y as *(&x) <- y to delegate the lvalue check to operator &. Similarly ++x actually means pre_incr (&x) The translations are done by the parser or early desugaring stuff (the parser is nice because the user can then invent new mutators). -- john skaller skal...@users.sourceforge.net ------------------------------------------------------------------------------ _______________________________________________ Felix-language mailing list Felix-language@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/felix-language