On Sat, 2007-12-01 at 18:09 -0800, Erick Tryzelaar wrote:
> On Dec 1, 2007 5:00 PM, skaller <[EMAIL PROTECTED]> wrote:
> > Clearly
> >
> >         x + 1
> >
> > is ambiguous .. incrementing the pointer? or the value it points to?
> 
> What if we made incrementing the pointer a separate felix function?

BTW: a problem with this whole idea is that overload resolution
uses the ability of the unification engine to 'decay' lvalues.

However lvalues are only supposed to be top level things.
Pointers can be nested in other structures. Decaying pointer
to X to X is a much more dangerous operation to put into
the unification engine, and may lead to unsound typing if
not used with care. In particular I'd hate to alias

        struct X { x:int; };
        struct Y { x:&int; };

since these would even use different amounts of store on an AMD64.


-- 
John Skaller <skaller at users dot sf dot net>
Felix, successor to C++: http://felix.sf.net

-------------------------------------------------------------------------
SF.Net email is sponsored by: The Future of Linux Business White Paper
from Novell.  From the desktop to the data center, Linux is going
mainstream.  Let it simplify your IT future.
http://altfarm.mediaplex.com/ad/ck/8857-50307-18918-4
_______________________________________________
Felix-language mailing list
Felix-language@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/felix-language

Reply via email to