Skip to content

Commit 543ba29

Browse files
committed
cleanup: Remove unused flag
1 parent 79ab6db commit 543ba29

File tree

5 files changed

+18
-23
lines changed

5 files changed

+18
-23
lines changed
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
diff --git a/src/gromacs/applied_forces/colvars/colvarproxygromacs.cpp b/src/gromacs/applied_forces/colvars/colvarproxygromacs.cpp
2+
index 76b350c611..37e5b53647 100644
3+
--- a/src/gromacs/applied_forces/colvars/colvarproxygromacs.cpp
4+
+++ b/src/gromacs/applied_forces/colvars/colvarproxygromacs.cpp
5+
@@ -79,9 +79,6 @@ ColvarProxyGromacs::ColvarProxyGromacs(const std::string& colvarsConfigString,
6+
// Retrieve masses and charges from input file
7+
updated_masses_ = updated_charges_ = true;
8+
9+
- // User-scripted forces are not available in GROMACS
10+
- have_scripts = false;
11+
-
12+
angstrom_value_ = 0.1;
13+
14+
// From Gnu units

namd/src/colvarproxy_namd.C

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -134,12 +134,6 @@ colvarproxy_namd::colvarproxy_namd(GlobalMasterColvars *gm)
134134
// save to Node for Tcl script access
135135
Node::Object()->colvars = colvars;
136136

137-
#ifdef NAMD_TCL
138-
have_scripts = true;
139-
#else
140-
have_scripts = false;
141-
#endif
142-
143137
if (simparams->firstTimestep != 0) {
144138
colvars->set_initial_step(static_cast<cvm::step_number>(simparams->firstTimestep));
145139
}

src/colvarproxy.cpp

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -416,18 +416,14 @@ int colvarproxy_smp::smp_unlock()
416416

417417

418418

419-
colvarproxy_script::colvarproxy_script()
420-
{
421-
script = NULL;
422-
have_scripts = false;
423-
}
419+
colvarproxy_script::colvarproxy_script() {}
424420

425421

426422
colvarproxy_script::~colvarproxy_script()
427423
{
428-
if (script != NULL) {
424+
if (script) {
429425
delete script;
430-
script = NULL;
426+
script = nullptr;
431427
}
432428
}
433429

src/colvarproxy.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -529,10 +529,7 @@ class colvarproxy_script {
529529

530530
/// Pointer to the scripting interface object
531531
/// (does not need to be allocated in a new interface)
532-
colvarscript *script;
533-
534-
/// Do we have a scripting interface?
535-
bool have_scripts;
532+
colvarscript *script = nullptr;
536533

537534
/// Run a user-defined colvar forces script
538535
virtual int run_force_callback();

vmd/src/colvarproxy_vmd.C

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -85,15 +85,9 @@ colvarproxy_vmd::colvarproxy_vmd(Tcl_Interp *interp, VMDApp *v, int molid)
8585
// both fields are taken from data structures already available
8686
updated_masses_ = updated_charges_ = true;
8787

88-
// Do we have scripts?
89-
// For now colvars depend on Tcl, but this may not always be the case
90-
// in the future
9188
#if defined(VMDTCL)
92-
have_scripts = true;
9389
// Need to set this before constructing colvarmodule, which creates colvarscript object
9490
set_tcl_interp(interp);
95-
#else
96-
have_scripts = false;
9791
#endif
9892

9993
colvars = new colvarmodule(this);

0 commit comments

Comments
 (0)