silence compiler warnings about unused arguments and variables and alike
This commit is contained in:
@ -33,7 +33,8 @@ enum{SCALAR,VECTOR,ARRAY};
|
|||||||
|
|
||||||
ComputeSnap::ComputeSnap(LAMMPS *lmp, int narg, char **arg) :
|
ComputeSnap::ComputeSnap(LAMMPS *lmp, int narg, char **arg) :
|
||||||
Compute(lmp, narg, arg), cutsq(NULL), list(NULL), snap(NULL),
|
Compute(lmp, narg, arg), cutsq(NULL), list(NULL), snap(NULL),
|
||||||
radelem(NULL), wjelem(NULL), snap_peratom(NULL), snapall(NULL)
|
snapall(NULL), snap_peratom(NULL), radelem(NULL), wjelem(NULL),
|
||||||
|
snaptr(NULL)
|
||||||
{
|
{
|
||||||
|
|
||||||
array_flag = 1;
|
array_flag = 1;
|
||||||
@ -41,9 +42,6 @@ ComputeSnap::ComputeSnap(LAMMPS *lmp, int narg, char **arg) :
|
|||||||
|
|
||||||
double rfac0, rmin0;
|
double rfac0, rmin0;
|
||||||
int twojmax, switchflag, bzeroflag;
|
int twojmax, switchflag, bzeroflag;
|
||||||
radelem = NULL;
|
|
||||||
wjelem = NULL;
|
|
||||||
|
|
||||||
int ntypes = atom->ntypes;
|
int ntypes = atom->ntypes;
|
||||||
int nargmin = 6+2*ntypes;
|
int nargmin = 6+2*ntypes;
|
||||||
|
|
||||||
@ -413,7 +411,6 @@ void ComputeSnap::compute_array()
|
|||||||
const int typeoffset_local = ndims_peratom*nperdim*itype;
|
const int typeoffset_local = ndims_peratom*nperdim*itype;
|
||||||
const int typeoffset_global = nperdim*itype;
|
const int typeoffset_global = nperdim*itype;
|
||||||
for (int icoeff = 0; icoeff < nperdim; icoeff++) {
|
for (int icoeff = 0; icoeff < nperdim; icoeff++) {
|
||||||
int irow = 1;
|
|
||||||
for (int i = 0; i < ntotal; i++) {
|
for (int i = 0; i < ntotal; i++) {
|
||||||
double *snadi = snap_peratom[i]+typeoffset_local;
|
double *snadi = snap_peratom[i]+typeoffset_local;
|
||||||
int iglobal = atom->tag[i];
|
int iglobal = atom->tag[i];
|
||||||
|
|||||||
@ -112,7 +112,6 @@ void PairOxrna2Xstk::compute(int eflag, int vflag)
|
|||||||
double theta1,t1dir[3],cost1;
|
double theta1,t1dir[3],cost1;
|
||||||
double theta2,t2dir[3],cost2;
|
double theta2,t2dir[3],cost2;
|
||||||
double theta3,t3dir[3],cost3;
|
double theta3,t3dir[3],cost3;
|
||||||
double theta4,theta4p,t4dir[3],cost4;
|
|
||||||
double theta7,theta7p,t7dir[3],cost7;
|
double theta7,theta7p,t7dir[3],cost7;
|
||||||
double theta8,theta8p,t8dir[3],cost8;
|
double theta8,theta8p,t8dir[3],cost8;
|
||||||
|
|
||||||
|
|||||||
@ -256,7 +256,7 @@ void ComputeViscosityCos::remove_bias_all() {
|
|||||||
assume remove_bias() was previously called
|
assume remove_bias() was previously called
|
||||||
------------------------------------------------------------------------- */
|
------------------------------------------------------------------------- */
|
||||||
|
|
||||||
void ComputeViscosityCos::restore_bias(int i, double *v) {
|
void ComputeViscosityCos::restore_bias(int /* i */, double *v) {
|
||||||
v[0] += vbias[0];
|
v[0] += vbias[0];
|
||||||
v[1] += vbias[1];
|
v[1] += vbias[1];
|
||||||
v[2] += vbias[2];
|
v[2] += vbias[2];
|
||||||
@ -267,7 +267,7 @@ void ComputeViscosityCos::restore_bias(int i, double *v) {
|
|||||||
assume remove_bias_thr() was previously called with the same buffer b
|
assume remove_bias_thr() was previously called with the same buffer b
|
||||||
------------------------------------------------------------------------- */
|
------------------------------------------------------------------------- */
|
||||||
|
|
||||||
void ComputeViscosityCos::restore_bias_thr(int i, double *v, double *b) {
|
void ComputeViscosityCos::restore_bias_thr(int /* i */, double *v, double *b) {
|
||||||
v[0] += b[0];
|
v[0] += b[0];
|
||||||
v[1] += b[1];
|
v[1] += b[1];
|
||||||
v[2] += b[2];
|
v[2] += b[2];
|
||||||
|
|||||||
@ -58,7 +58,7 @@ void FixAccelerateCos::setup(int vflag) {
|
|||||||
|
|
||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
|
|
||||||
void FixAccelerateCos::post_force(int vflag) {
|
void FixAccelerateCos::post_force(int /* vflag */) {
|
||||||
double **x = atom->x;
|
double **x = atom->x;
|
||||||
double **f = atom->f;
|
double **f = atom->f;
|
||||||
int *type = atom->type;
|
int *type = atom->type;
|
||||||
|
|||||||
@ -1834,7 +1834,6 @@ void AtomVec::pack_data(double **buf)
|
|||||||
void AtomVec::write_data(FILE *fp, int n, double **buf)
|
void AtomVec::write_data(FILE *fp, int n, double **buf)
|
||||||
{
|
{
|
||||||
int i,j,m,nn,datatype,cols;
|
int i,j,m,nn,datatype,cols;
|
||||||
void *pdata;
|
|
||||||
|
|
||||||
for (i = 0; i < n; i++) {
|
for (i = 0; i < n; i++) {
|
||||||
fprintf(fp,TAGINT_FORMAT,(tagint) ubuf(buf[i][0]).i);
|
fprintf(fp,TAGINT_FORMAT,(tagint) ubuf(buf[i][0]).i);
|
||||||
@ -1983,40 +1982,32 @@ void AtomVec::pack_vel(double **buf)
|
|||||||
void AtomVec::write_vel(FILE *fp, int n, double **buf)
|
void AtomVec::write_vel(FILE *fp, int n, double **buf)
|
||||||
{
|
{
|
||||||
int i,j,m,nn,datatype,cols;
|
int i,j,m,nn,datatype,cols;
|
||||||
void *pdata;
|
|
||||||
|
|
||||||
for (i = 0; i < n; i++) {
|
for (i = 0; i < n; i++) {
|
||||||
fprintf(fp,TAGINT_FORMAT,(tagint) ubuf(buf[i][0]).i);
|
fprintf(fp,TAGINT_FORMAT,(tagint) ubuf(buf[i][0]).i);
|
||||||
|
|
||||||
j = 1;
|
j = 1;
|
||||||
for (nn = 1; nn < ndata_vel; nn++) {
|
for (nn = 1; nn < ndata_vel; nn++) {
|
||||||
pdata = mdata_vel.pdata[nn];
|
|
||||||
datatype = mdata_vel.datatype[nn];
|
datatype = mdata_vel.datatype[nn];
|
||||||
cols = mdata_vel.cols[nn];
|
cols = mdata_vel.cols[nn];
|
||||||
if (datatype == DOUBLE) {
|
if (datatype == DOUBLE) {
|
||||||
if (cols == 0) {
|
if (cols == 0) {
|
||||||
double *vec = *((double **) pdata);
|
|
||||||
fprintf(fp," %-1.16e",buf[i][j++]);
|
fprintf(fp," %-1.16e",buf[i][j++]);
|
||||||
} else {
|
} else {
|
||||||
double **array = *((double ***) pdata);
|
|
||||||
for (m = 0; m < cols; m++)
|
for (m = 0; m < cols; m++)
|
||||||
fprintf(fp," %-1.16e",buf[i][j++]);
|
fprintf(fp," %-1.16e",buf[i][j++]);
|
||||||
}
|
}
|
||||||
} else if (datatype == INT) {
|
} else if (datatype == INT) {
|
||||||
if (cols == 0) {
|
if (cols == 0) {
|
||||||
int *vec = *((int **) pdata);
|
|
||||||
fprintf(fp," %d",(int) ubuf(buf[i][j++]).i);
|
fprintf(fp," %d",(int) ubuf(buf[i][j++]).i);
|
||||||
} else {
|
} else {
|
||||||
int **array = *((int ***) pdata);
|
|
||||||
for (m = 0; m < cols; m++)
|
for (m = 0; m < cols; m++)
|
||||||
fprintf(fp," %d",(int) ubuf(buf[i][j++]).i);
|
fprintf(fp," %d",(int) ubuf(buf[i][j++]).i);
|
||||||
}
|
}
|
||||||
} else if (datatype == BIGINT) {
|
} else if (datatype == BIGINT) {
|
||||||
if (cols == 0) {
|
if (cols == 0) {
|
||||||
bigint *vec = *((bigint **) pdata);
|
|
||||||
fprintf(fp," " BIGINT_FORMAT,(bigint) ubuf(buf[i][j++]).i);
|
fprintf(fp," " BIGINT_FORMAT,(bigint) ubuf(buf[i][j++]).i);
|
||||||
} else {
|
} else {
|
||||||
bigint **array = *((bigint ***) pdata);
|
|
||||||
for (m = 0; m < cols; m++)
|
for (m = 0; m < cols; m++)
|
||||||
fprintf(fp," " BIGINT_FORMAT,(bigint) ubuf(buf[i][j++]).i);
|
fprintf(fp," " BIGINT_FORMAT,(bigint) ubuf(buf[i][j++]).i);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user