lib/sod.[ch] (sod_convert): Make the instance argument be `const void *'.
authorMark Wooding <mdw@distorted.org.uk>
Tue, 25 Aug 2015 09:23:50 +0000 (10:23 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Tue, 25 Aug 2015 09:23:50 +0000 (10:23 +0100)
The documentation says that it should be, and I agree.

lib/sod.c
lib/sod.h

index bd600f9..bcaf6f6 100644 (file)
--- a/lib/sod.c
+++ b/lib/sod.c
@@ -108,7 +108,7 @@ int sod_subclassp(const SodClass *sub, const SodClass *super)
  *             to know what C or S actually are.
  */
 
-void *sod_convert(const SodClass *cls, void *p)
+void *sod_convert(const SodClass *cls, const void *p)
 {
   const struct sod_instance *inst = p;
   const struct sod_vtable *vt = inst->_vt;
index 6a444e9..7f18f35 100644 (file)
--- a/lib/sod.h
+++ b/lib/sod.h
@@ -188,7 +188,7 @@ extern int sod_subclassp(const SodClass */*sub*/, const SodClass */*super*/);
  *             to know what either C or S actually are.
  */
 
-extern void *sod_convert(const SodClass */*cls*/, void */*p*/);
+extern void *sod_convert(const SodClass */*cls*/, const void */*p*/);
 
 /*----- That's all, folks -------------------------------------------------*/