From b776f0f29f8771366a44560d53e733b637e714d1 Mon Sep 17 00:00:00 2001
From: Axel Kohlmeyer <akohlmey@gmail.com>
Date: Mon, 12 Nov 2018 21:11:55 -0500
Subject: [PATCH] remove dead code and silence warnings about unused parameters

---
 src/REPLICA/fix_hyper_global.cpp | 12 +++++-------
 src/REPLICA/fix_hyper_local.cpp  | 13 ++++++-------
 src/REPLICA/hyper.cpp            |  4 ++--
 3 files changed, 13 insertions(+), 16 deletions(-)

diff --git a/src/REPLICA/fix_hyper_global.cpp b/src/REPLICA/fix_hyper_global.cpp
index 7b120c3327..d119083a3b 100644
--- a/src/REPLICA/fix_hyper_global.cpp
+++ b/src/REPLICA/fix_hyper_global.cpp
@@ -136,7 +136,7 @@ void FixHyperGlobal::init()
 
 /* ---------------------------------------------------------------------- */
 
-void FixHyperGlobal::init_list(int id, NeighList *ptr)
+void FixHyperGlobal::init_list(int /* id */, NeighList *ptr)
 {
   list = ptr;
 }
@@ -167,7 +167,7 @@ void FixHyperGlobal::setup_pre_reverse(int eflag, int vflag)
 
 void FixHyperGlobal::pre_neighbor()
 {
-  int i,m,jnum,iold,jold,ilocal,jlocal;
+  int m,iold,jold,ilocal,jlocal;
   double distsq;
 
   // reset local IDs for owned bond atoms, since atoms have migrated
@@ -200,10 +200,10 @@ void FixHyperGlobal::pre_neighbor()
 
 /* ---------------------------------------------------------------------- */
 
-void FixHyperGlobal::pre_reverse(int eflag, int vflag)
+void FixHyperGlobal::pre_reverse(int /* eflag */, int /* vflag */)
 {
   int i,j,m,imax,jmax;
-  double xtmp,ytmp,ztmp,delx,dely,delz;
+  double delx,dely,delz;
   double r,r0,estrain,rmax,r0max,emax,dt_boost;
   double vbias,fbias,fbiasr;
 
@@ -299,11 +299,9 @@ void FixHyperGlobal::pre_reverse(int eflag, int vflag)
 
 void FixHyperGlobal::build_bond_list(int natom)
 {
-  int i,j,n,ii,jj,inum,jnum;
+  int i,j,ii,jj,inum,jnum;
   double xtmp,ytmp,ztmp,delx,dely,delz,rsq;
   int *ilist,*jlist,*numneigh,**firstneigh;
-  tagint *bptr;
-  double *rptr;
 
   if (natom) {
     nevent++;
diff --git a/src/REPLICA/fix_hyper_local.cpp b/src/REPLICA/fix_hyper_local.cpp
index 4152bd3836..a7d384905d 100644
--- a/src/REPLICA/fix_hyper_local.cpp
+++ b/src/REPLICA/fix_hyper_local.cpp
@@ -316,7 +316,7 @@ void FixHyperLocal::init()
 
 /* ---------------------------------------------------------------------- */
 
-void FixHyperLocal::init_list(int id, NeighList *ptr)
+void FixHyperLocal::init_list(int /* id */, NeighList *ptr)
 {
   list = ptr;
 }
@@ -413,7 +413,7 @@ void FixHyperLocal::pre_neighbor()
 
 /* ---------------------------------------------------------------------- */
 
-void FixHyperLocal::pre_reverse(int eflag, int vflag)
+void FixHyperLocal::pre_reverse(int /* eflag */, int /* vflag */)
 {
   int i,j,m,ii,jj,inum,jnum,iold,jold,nbond,bondindex;
   tagint itag,jtag;
@@ -788,7 +788,6 @@ void FixHyperLocal::pre_reverse(int eflag, int vflag)
 
   if (checkcoeff && update->ntimestep % checkcoeff_every == 0) {
     int jb,jbonds;
-    double ibias,jbias;
     
     for (i = 0; i < nlocal; i++) {
       nbond = numbond[i];
@@ -998,9 +997,9 @@ void FixHyperLocal::build_bond_list(int natom)
 /* ---------------------------------------------------------------------- */
 
 int FixHyperLocal::pack_forward_comm(int n, int *list, double *buf, 
-                                     int pbc_flag, int *pbc)
+                                     int /* pbc_flag */, int * /* pbc */)
 {
-  int i,j,k,m,ibond,nbond,start;
+  int i,j,m;
 
   m = 0;
 
@@ -1039,7 +1038,7 @@ int FixHyperLocal::pack_forward_comm(int n, int *list, double *buf,
 
 void FixHyperLocal::unpack_forward_comm(int n, int first, double *buf)
 {
-  int i,j,k,m,last,ibond,nbond,jlocal,flag;
+  int i,m,last;
 
   m = 0;
   last = first + n;
@@ -1158,7 +1157,7 @@ void FixHyperLocal::grow_arrays(int nmax)
    copy values within local atom-based arrays
 ------------------------------------------------------------------------- */
 
-void FixHyperLocal::copy_arrays(int i, int j, int delflag)
+void FixHyperLocal::copy_arrays(int i, int j, int /* delflag */)
 {
   // avoid valgrind copy-to-self warning
 
diff --git a/src/REPLICA/hyper.cpp b/src/REPLICA/hyper.cpp
index 04ff43aa02..51490702fb 100644
--- a/src/REPLICA/hyper.cpp
+++ b/src/REPLICA/hyper.cpp
@@ -413,7 +413,7 @@ void Hyper::command(int narg, char **arg)
    short dynamics run
 ------------------------------------------------------------------------- */
 
-void Hyper::dynamics(int nsteps, double &time_category)
+void Hyper::dynamics(int nsteps, double & /* time_category */)
 {
   update->whichflag = 1;
   update->nsteps = nsteps;
@@ -470,7 +470,7 @@ void Hyper::quench(int flag)
   //update->minimize->setup_minimal(1);
 
   // NOTE: what doing with ncalls?
-  int ncalls = neighbor->ncalls;
+  // int ncalls = neighbor->ncalls;
 
   timer->barrier_start();
   update->minimize->run(maxiter);
-- 
GitLab