On 15 May 2012, at 8:38pm, Baruch Burstein <bmburst...@gmail.com> wrote:

>  I am working on a  C++ wrapper for sqlite. It
> is the wrapper's user's responsibility to make sure no statement objects
> still exist before the database object gets destroyed. This is just a
> precaution.

I am surprised that doing _close() without finalizing doesn't do the finalizing 
before (or instead of) generating the error code.  After all, one is unlikely 
to call _close() in error, and slowing down _close() isn't going to slow down 
most apps very much.

I'm also surprised at how strong the warning is on the page about 
sqlite3_finalize():

<http://sqlite.org/c3ref/finalize.html>

This might be the strongest warning in the whole of the API function 
documentation.  Couldn't _finalize() just put a null somewhere in the statement 
as a flag that the statement had already been finalized ?  I guess checking for 
it would slow up later calls too much.

Simon.
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to