Feature Requests item #1578582, was opened at 2006-10-17 01:43 Message generated for change (Comment added) made by mhoenicka You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=512948&aid=1578582&group_id=65979
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None Status: Open Priority: 5 Submitted By: Peter MacDonald (pcmacdon) Assigned to: Nobody/Anonymous (nobody) Summary: void * disables typechecking. Initial Comment: Using void* for dbi_driver, etc makes debugging more difficult than it needs to be. One workaround is to use something like the following in dbi.h #if ((!defined(DBI_DRIVER_DIR)) ||(defined(DBI_NO_VOIDPTRS))) typedef struct { int unused; } *dbi_driver; typedef struct { int unused; } *dbi_conn; typedef struct { int unused; } *dbi_result; #else /* opaque type definitions */ typedef void * dbi_driver; typedef void * dbi_conn; typedef void * dbi_result; #endif ---------------------------------------------------------------------- >Comment By: Markus Hoenicka (mhoenicka) Date: 2006-10-17 14:55 Message: Logged In: YES user_id=85809 Frankly, I don't know why the original libdbi authors used void* pointers for drivers, connections, and such. As far as debugging is concerned, I don't see a disadvantage though as most libdbi functions using one of these as an argument perform a typecast to a struct* anyway. The structure members are then available through the pointer on the stack. How in particular would your suggested change simplify debugging? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=512948&aid=1578582&group_id=65979 ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Libdbi-drivers-devel mailing list Libdbi-drivers-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libdbi-drivers-devel