use a void* instead of a char* for anonymous `InitInfo' in src/sparse/*.c
This commit is contained in:
parent
3e95037b0e
commit
1ee29c3e96
|
|
@ -1,3 +1,9 @@
|
|||
2010-07-23 Robert Larice
|
||||
* src/include/spmatrix.h ,
|
||||
* src/maths/sparse/spbuild.c ,
|
||||
* src/maths/sparse/spdefs.h :
|
||||
use a void* instead of a char* for anonymous `InitInfo' in src/sparse/*.c
|
||||
|
||||
2010-07-23 Robert Larice
|
||||
* src/maths/sparse/sputils.c :
|
||||
convert K&R function definitions to ansi style
|
||||
|
|
|
|||
|
|
@ -266,11 +266,11 @@ extern int spFillinCount( void * );
|
|||
extern int spGetAdmittance( void *, int, int, struct spTemplate* );
|
||||
extern spREAL *spFindElement( void *eMatrix, int Row, int Col );
|
||||
extern spREAL *spGetElement( void *, int, int );
|
||||
extern char *spGetInitInfo( spREAL* );
|
||||
extern void *spGetInitInfo( spREAL* );
|
||||
extern int spGetOnes( void *, int, int, int, struct spTemplate* );
|
||||
extern int spGetQuad( void *, int, int, int, int, struct spTemplate* );
|
||||
extern int spGetSize( void *, int );
|
||||
extern int spInitialize( void *, int (*pInit)(spREAL*, char *InitInfo, int, int Col));
|
||||
extern int spInitialize( void *, int (*pInit)(spREAL*, void *InitInfo, int, int Col));
|
||||
extern void spInstallInitInfo( spREAL*, void * );
|
||||
extern spREAL spLargestElement( void * );
|
||||
extern void spMNA_Preorder( void * );
|
||||
|
|
|
|||
|
|
@ -1126,7 +1126,7 @@ ExpandTranslationArrays(MatrixPtr Matrix, int NewSize)
|
|||
*/
|
||||
|
||||
void
|
||||
spInstallInitInfo(RealNumber *pElement, char *pInitInfo)
|
||||
spInstallInitInfo(RealNumber *pElement, void *pInitInfo)
|
||||
{
|
||||
/* Begin `spInstallInitInfo'. */
|
||||
assert(pElement != NULL);
|
||||
|
|
@ -1135,18 +1135,18 @@ spInstallInitInfo(RealNumber *pElement, char *pInitInfo)
|
|||
}
|
||||
|
||||
|
||||
char *
|
||||
void *
|
||||
spGetInitInfo(RealNumber *pElement)
|
||||
{
|
||||
/* Begin `spGetInitInfo'. */
|
||||
assert(pElement != NULL);
|
||||
|
||||
return (char *)((ElementPtr)pElement)->pInitInfo;
|
||||
return ((ElementPtr)pElement)->pInitInfo;
|
||||
}
|
||||
|
||||
|
||||
int
|
||||
spInitialize(void *eMatrix, int (*pInit)(RealNumber*, char *InitInfo, int , int Col))
|
||||
spInitialize(void *eMatrix, int (*pInit)(RealNumber*, void *InitInfo, int , int Col))
|
||||
{
|
||||
MatrixPtr Matrix = (MatrixPtr)eMatrix;
|
||||
ElementPtr pElement;
|
||||
|
|
|
|||
|
|
@ -424,7 +424,7 @@ extern void * trealloc(void *, size_t);
|
|||
* NextInCol contains a pointer to the next element in the column below
|
||||
* this element. If this element is the last nonzero in the column then
|
||||
* NextInCol contains NULL.
|
||||
* pInitInfo (char *)
|
||||
* pInitInfo (void *)
|
||||
* Pointer to user data used for initialization of the matrix element.
|
||||
* Initialized to NULL.
|
||||
*
|
||||
|
|
@ -447,7 +447,7 @@ struct MatrixElement
|
|||
struct MatrixElement *NextInRow;
|
||||
struct MatrixElement *NextInCol;
|
||||
#if INITIALIZE
|
||||
char *pInitInfo;
|
||||
void *pInitInfo;
|
||||
#endif
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue