Well, there IS only one date, but two pointers to it... On 11/03/06, Jeffrey Martin <[EMAIL PROTECTED]> wrote: > > I had to deal with this last year and found it surprising and > unpleasant. While I now understand that it only creates one new date > instance and is designed that way, to me it is not logical that this > happen. > > Some have stated that since there is one NEW listed that only one > instance is created. On that logic, there is only one DATE as well > and only one date variable should be created as well. If I were > writing a language, if it had NEW in it, an instance for each date > would be created, not just one. > > Perhaps a compiler error would clear up the ambiguity of what is > happening the way this NEW is currently implemented. > > Regards, > Jeffrey > > > On Mar 10, 2006, at 23:44, realbasic-nug- > [EMAIL PROTECTED] wrote: > > > I just found something I did not expect to work like this: > > > > dim d1, d2 as new Date > > > > I did expect that this would create TWO new Date instances, one for > > d1, and one for d2. > > > > Instead, there's only one instance which gets assigned to both d1 > > and d2. > > > > _______________________________________________ > Unsubscribe or switch delivery mode: > <http://www.realsoftware.com/support/listmanager/> > > Search the archives of this list here: > <http://support.realsoftware.com/listarchives/lists.html> > > _______________________________________________ Unsubscribe or switch delivery mode: <http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here: <http://support.realsoftware.com/listarchives/lists.html>
