monotone-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Monotone-devel] dumb question - node::clone()


From: Timothy Brownawell
Subject: Re: [Monotone-devel] dumb question - node::clone()
Date: Sun, 24 Jun 2007 21:59:40 -0500

On Sun, 2007-06-24 at 19:37 -0700, Zack Weinberg wrote:
> On 6/24/07, Timothy Brownawell <address@hidden> wrote:
> > On Sun, 2007-06-24 at 10:30 -0700, Zack Weinberg wrote:
> > > Do the clone() methods for dir_node and file_node do anything that the
> > > respective copy constructors wouldn't do?
> >
> > They're virtual functions, which means that you can call clone() on a
> > node* (which will actually point to a dir_node or file_node), and get a
> > new dir_node or file_node as appropriate. Using a copy constructor
> > directly means that you have to know in advance what type you're trying
> > to get.
> 
> I should have been clearer.  *Other than that*, is there any difference?

Other than that, no, there shouldn't be a difference.


-- 
Timothy

Free (experimental) public monotone hosting: http://mtn-host.prjek.net





reply via email to

[Prev in Thread] Current Thread [Next in Thread]