You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Josh Pieper <jp...@andrew.cmu.edu> on 2004/04/11 00:43:38 UTC

Should svn_hash_(read|write) accept streams?

ghudson, sussman, and I were talking on IRC about how great it would
be if svn_hash_(read|write) would accept svn_stream_t's.  Then the
equivalent code could be factorized out of the dumpfile loader, and
re-used in the fs_fs code as well.  The existing API could be
trivially obtained by using svn_stream_from_aprfile, as well as handy
things like reading hashes from stringbufs.

So what are your thoughts about creating two new functions:
svn_hash_read2 and svn_hash_write2 that accept svn_stream_t as
input/output.  The originals could be removed at the next API change.

-Josh

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: Should svn_hash_(read|write) accept streams?

Posted by Greg Hudson <gh...@MIT.EDU>.
On Sat, 2004-04-10 at 20:56, Branko Čibej wrote:
> >So what are your thoughts about creating two new functions:
> >svn_hash_read2 and svn_hash_write2 that accept svn_stream_t as

> svn_hash_read_stream and svn_hash_write_stream, please. Make the
> function names mnemonic.

I think you're swimming against the tide here.  We use a "2" suffix when
we're simply revving an API; we only use a new name when we've come up
with a name which is genuinely better.  Since we don't normally tack
"_stream" onto the end of functions which operate on streams, this falls
into the first category.

> >input/output.  The originals could be removed at the next API change.

> (and the originals can't be removed until 2.0, which is not the next API
> change :-)

He meant the next incompatible API change, which is (presumably) at 2.0.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org


Re: Should svn_hash_(read|write) accept streams?

Posted by Branko Čibej <br...@xbc.nu>.
Josh Pieper wrote:

>ghudson, sussman, and I were talking on IRC about how great it would
>be if svn_hash_(read|write) would accept svn_stream_t's.  Then the
>equivalent code could be factorized out of the dumpfile loader, and
>re-used in the fs_fs code as well.  The existing API could be
>trivially obtained by using svn_stream_from_aprfile, as well as handy
>things like reading hashes from stringbufs.
>
>So what are your thoughts about creating two new functions:
>svn_hash_read2 and svn_hash_write2 that accept svn_stream_t as
>  
>
svn_hash_read_stream and svn_hash_write_stream, please. Make the
function names mnemonic.

>input/output.  The originals could be removed at the next API change.
>  
>
+1

(and the originals can't be removed until 2.0, which is not the next API
change :-)

-- 
Brane Čibej   <br...@xbc.nu>   http://www.xbc.nu/brane/

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org