From: Mark Abraham Date: Tue, 19 Jun 2018 11:47:40 +0000 (+0200) Subject: Remove some pieces from forcerec.h X-Git-Url: http://biod.pnpi.spb.ru/gitweb/?a=commitdiff_plain;h=5fb8015093ca9fca1c3d7410c302178cd808e54b;p=alexxy%2Fgromacs.git Remove some pieces from forcerec.h This makes it less of a global compilation dependency. Some new includes required because contents were no longer available via transitive inclusion. Used more forward declarations to avoid such transitive inclusion. Removed some C++ guards too now that some more pieces are no longer compiled by most/all of the group scheme kernels. Change-Id: I56a1bb290da639500dbc8c8baa04c1f32758713c --- diff --git a/src/gromacs/applied-forces/tests/electricfield.cpp b/src/gromacs/applied-forces/tests/electricfield.cpp index d721db2005..2bb8cedef1 100644 --- a/src/gromacs/applied-forces/tests/electricfield.cpp +++ b/src/gromacs/applied-forces/tests/electricfield.cpp @@ -48,6 +48,7 @@ #include "gromacs/gmxlib/network.h" #include "gromacs/math/vec.h" #include "gromacs/mdlib/forcerec.h" +#include "gromacs/mdtypes/enerdata.h" #include "gromacs/mdtypes/forceoutput.h" #include "gromacs/mdtypes/iforceprovider.h" #include "gromacs/mdtypes/imdmodule.h" diff --git a/src/gromacs/gmxana/gmx_enemat.cpp b/src/gromacs/gmxana/gmx_enemat.cpp index c58c92e4e9..f5dab5afbf 100644 --- a/src/gromacs/gmxana/gmx_enemat.cpp +++ b/src/gromacs/gmxana/gmx_enemat.cpp @@ -49,7 +49,8 @@ #include "gromacs/math/functions.h" #include "gromacs/math/units.h" #include "gromacs/math/vec.h" -#include "gromacs/mdtypes/forcerec.h" +#include "gromacs/mdlib/mdebin.h" +#include "gromacs/mdtypes/enerdata.h" #include "gromacs/mdtypes/md_enums.h" #include "gromacs/trajectory/energyframe.h" #include "gromacs/utility/arraysize.h" diff --git a/src/gromacs/gmxlib/nonbonded/nb_kernel.h b/src/gromacs/gmxlib/nonbonded/nb_kernel.h index 643ac97af7..c7786a7770 100644 --- a/src/gromacs/gmxlib/nonbonded/nb_kernel.h +++ b/src/gromacs/gmxlib/nonbonded/nb_kernel.h @@ -42,7 +42,6 @@ #include "gromacs/mdtypes/forcerec.h" #include "gromacs/mdtypes/mdatom.h" #include "gromacs/mdtypes/nblist.h" -#include "gromacs/topology/block.h" #include "gromacs/utility/real.h" #ifdef __cplusplus @@ -68,15 +67,17 @@ extern "C" { #define gmx_inline inline #endif +struct t_blocka; + /* Structure to collect kernel data not available in forcerec or mdatoms structures. * This is only used inside the nonbonded module. */ typedef struct { - int flags; - const t_blocka *exclusions; - real * lambda; - real * dvdl; + int flags; + const struct t_blocka *exclusions; + real *lambda; + real *dvdl; /* pointers to tables */ t_forcetable * table_elec; diff --git a/src/gromacs/gmxlib/nonbonded/nb_kernel_c/nb_kernel_allvsall.cpp b/src/gromacs/gmxlib/nonbonded/nb_kernel_c/nb_kernel_allvsall.cpp index 2b88ee7b8f..542795b165 100644 --- a/src/gromacs/gmxlib/nonbonded/nb_kernel_c/nb_kernel_allvsall.cpp +++ b/src/gromacs/gmxlib/nonbonded/nb_kernel_c/nb_kernel_allvsall.cpp @@ -44,6 +44,7 @@ #include "gromacs/gmxlib/nrnb.h" #include "gromacs/math/functions.h" +#include "gromacs/topology/block.h" #include "gromacs/utility/real.h" #include "gromacs/utility/smalloc.h" diff --git a/src/gromacs/gmxlib/nonbonded/nonbonded.cpp b/src/gromacs/gmxlib/nonbonded/nonbonded.cpp index e1a5344eaa..5aca8f316d 100644 --- a/src/gromacs/gmxlib/nonbonded/nonbonded.cpp +++ b/src/gromacs/gmxlib/nonbonded/nonbonded.cpp @@ -54,6 +54,7 @@ #include "gromacs/listed-forces/bonded.h" #include "gromacs/math/utilities.h" #include "gromacs/math/vec.h" +#include "gromacs/mdtypes/enerdata.h" #include "gromacs/mdtypes/forcerec.h" #include "gromacs/mdtypes/md_enums.h" #include "gromacs/mdtypes/mdatom.h" diff --git a/src/gromacs/gmxlib/nonbonded/nonbonded.h b/src/gromacs/gmxlib/nonbonded/nonbonded.h index 6dccff7c30..c690da7bd0 100644 --- a/src/gromacs/gmxlib/nonbonded/nonbonded.h +++ b/src/gromacs/gmxlib/nonbonded/nonbonded.h @@ -41,12 +41,14 @@ #include "gromacs/gmxlib/nrnb.h" #include "gromacs/math/vectypes.h" -#include "gromacs/mdtypes/forcerec.h" #include "gromacs/mdtypes/mdatom.h" #include "gromacs/mdtypes/nblist.h" #include "gromacs/topology/block.h" #include "gromacs/utility/basedefinitions.h" +struct gmx_grppairener_t; +struct t_forcerec; + void gmx_nonbonded_setup(t_forcerec *fr, gmx_bool bGenericKernelOnly); diff --git a/src/gromacs/listed-forces/listed-internal.h b/src/gromacs/listed-forces/listed-internal.h index 1681cdb5e0..87f7197255 100644 --- a/src/gromacs/listed-forces/listed-internal.h +++ b/src/gromacs/listed-forces/listed-internal.h @@ -44,7 +44,7 @@ #define GMX_LISTED_FORCES_LISTED_INTERNAL_H #include "gromacs/math/vectypes.h" -#include "gromacs/mdtypes/forcerec.h" +#include "gromacs/mdtypes/enerdata.h" #include "gromacs/topology/idef.h" #include "gromacs/topology/ifunc.h" #include "gromacs/utility/bitmask.h" diff --git a/src/gromacs/listed-forces/pairs.h b/src/gromacs/listed-forces/pairs.h index d3c4bc9b08..8d2ee0a5bc 100644 --- a/src/gromacs/listed-forces/pairs.h +++ b/src/gromacs/listed-forces/pairs.h @@ -45,12 +45,13 @@ #define GMX_LISTED_FORCES_PAIRS_H #include "gromacs/math/vec.h" -#include "gromacs/mdtypes/forcerec.h" #include "gromacs/mdtypes/mdatom.h" #include "gromacs/topology/ifunc.h" #include "gromacs/utility/basedefinitions.h" #include "gromacs/utility/real.h" +struct gmx_grppairener_t; +struct t_forcerec; struct t_graph; struct t_pbc; diff --git a/src/gromacs/listed-forces/position-restraints.cpp b/src/gromacs/listed-forces/position-restraints.cpp index d9a9fbef18..6ceebe5c7f 100644 --- a/src/gromacs/listed-forces/position-restraints.cpp +++ b/src/gromacs/listed-forces/position-restraints.cpp @@ -53,6 +53,7 @@ #include "gromacs/gmxlib/nrnb.h" #include "gromacs/math/functions.h" #include "gromacs/math/vec.h" +#include "gromacs/mdtypes/enerdata.h" #include "gromacs/mdtypes/forceoutput.h" #include "gromacs/mdtypes/forcerec.h" #include "gromacs/mdtypes/inputrec.h" diff --git a/src/gromacs/mdlib/expanded.cpp b/src/gromacs/mdlib/expanded.cpp index 9484d757cc..9744ed48ab 100644 --- a/src/gromacs/mdlib/expanded.cpp +++ b/src/gromacs/mdlib/expanded.cpp @@ -58,6 +58,7 @@ #include "gromacs/mdlib/constr.h" #include "gromacs/mdlib/force.h" #include "gromacs/mdlib/update.h" +#include "gromacs/mdtypes/enerdata.h" #include "gromacs/mdtypes/forcerec.h" #include "gromacs/mdtypes/inputrec.h" #include "gromacs/mdtypes/md_enums.h" diff --git a/src/gromacs/mdlib/force.cpp b/src/gromacs/mdlib/force.cpp index 788d9bf5ba..cbe4840ba9 100644 --- a/src/gromacs/mdlib/force.cpp +++ b/src/gromacs/mdlib/force.cpp @@ -64,7 +64,9 @@ #include "gromacs/mdlib/rf_util.h" #include "gromacs/mdlib/wall.h" #include "gromacs/mdtypes/commrec.h" +#include "gromacs/mdtypes/enerdata.h" #include "gromacs/mdtypes/forceoutput.h" +#include "gromacs/mdtypes/forcerec.h" #include "gromacs/mdtypes/inputrec.h" #include "gromacs/mdtypes/md_enums.h" #include "gromacs/pbcutil/ishift.h" diff --git a/src/gromacs/mdlib/forcerec-threading.h b/src/gromacs/mdlib/forcerec-threading.h index 070b476ec5..9bf01ceade 100644 --- a/src/gromacs/mdlib/forcerec-threading.h +++ b/src/gromacs/mdlib/forcerec-threading.h @@ -1,7 +1,7 @@ /* * This file is part of the GROMACS molecular simulation package. * - * Copyright (c) 2014,2015, by the GROMACS development team, led by + * Copyright (c) 2014,2015,2018, by the GROMACS development team, led by * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl, * and including many others, as listed in the AUTHORS file in the * top-level source directory and at http://www.gromacs.org. @@ -36,9 +36,8 @@ #ifndef GMX_MDLIB_FORCEREC_THREADING_H #define GMX_MDLIB_FORCEREC_THREADING_H -#ifdef __cplusplus -extern "C" { -#endif +#include "gromacs/math/vectypes.h" +#include "gromacs/mdtypes/md_enums.h" struct ewald_corr_thread_t { real Vcorr_q; @@ -48,8 +47,4 @@ struct ewald_corr_thread_t { tensor vir_lj; }; -#ifdef __cplusplus -} -#endif - #endif diff --git a/src/gromacs/mdlib/forcerec.cpp b/src/gromacs/mdlib/forcerec.cpp index 66bdd39819..f798d07f1b 100644 --- a/src/gromacs/mdlib/forcerec.cpp +++ b/src/gromacs/mdlib/forcerec.cpp @@ -106,11 +106,6 @@ #include "nbnxn_gpu_jit_support.h" -const char *egrp_nm[egNR+1] = { - "Coul-SR", "LJ-SR", "Buck-SR", - "Coul-14", "LJ-14", nullptr -}; - t_forcerec *mk_forcerec(void) { t_forcerec *fr; diff --git a/src/gromacs/mdlib/md_support.cpp b/src/gromacs/mdlib/md_support.cpp index f4561d0321..f6db75d091 100644 --- a/src/gromacs/mdlib/md_support.cpp +++ b/src/gromacs/mdlib/md_support.cpp @@ -57,6 +57,7 @@ #include "gromacs/mdtypes/commrec.h" #include "gromacs/mdtypes/df_history.h" #include "gromacs/mdtypes/energyhistory.h" +#include "gromacs/mdtypes/forcerec.h" #include "gromacs/mdtypes/group.h" #include "gromacs/mdtypes/inputrec.h" #include "gromacs/mdtypes/md_enums.h" diff --git a/src/gromacs/mdlib/mdebin.cpp b/src/gromacs/mdlib/mdebin.cpp index 42e8976b45..6c57df84f1 100644 --- a/src/gromacs/mdlib/mdebin.cpp +++ b/src/gromacs/mdlib/mdebin.cpp @@ -94,6 +94,11 @@ static const char *boxvel_nm[] = { #define NBOXS asize(boxs_nm) #define NTRICLBOXS asize(tricl_boxs_nm) +const char *egrp_nm[egNR+1] = { + "Coul-SR", "LJ-SR", "Buck-SR", + "Coul-14", "LJ-14", nullptr +}; + t_mdebin *init_mdebin(ener_file_t fp_ene, const gmx_mtop_t *mtop, const t_inputrec *ir, diff --git a/src/gromacs/mdlib/mdebin.h b/src/gromacs/mdlib/mdebin.h index 2257451305..151a59b35c 100644 --- a/src/gromacs/mdlib/mdebin.h +++ b/src/gromacs/mdlib/mdebin.h @@ -41,10 +41,11 @@ #include "gromacs/fileio/enxio.h" #include "gromacs/mdlib/ebin.h" -#include "gromacs/mdtypes/forcerec.h" +#include "gromacs/mdtypes/enerdata.h" class energyhistory_t; struct gmx_ekindata_t; +struct gmx_enerdata_t; struct gmx_mtop_t; struct gmx_output_env_t; struct t_expanded; @@ -59,6 +60,8 @@ class Awh; class Constraints; } +extern const char *egrp_nm[egNR+1]; + /* The functions & data structures here determine the content for outputting the .edr file; the file format and actual writing is done with functions defined in enxio.h */ diff --git a/src/gromacs/mdlib/ns.cpp b/src/gromacs/mdlib/ns.cpp index c24e28ac02..f0c1e111bc 100644 --- a/src/gromacs/mdlib/ns.cpp +++ b/src/gromacs/mdlib/ns.cpp @@ -57,6 +57,7 @@ #include "gromacs/mdlib/nsgrid.h" #include "gromacs/mdlib/qmmm.h" #include "gromacs/mdtypes/commrec.h" +#include "gromacs/mdtypes/forcerec.h" #include "gromacs/mdtypes/group.h" #include "gromacs/mdtypes/inputrec.h" #include "gromacs/mdtypes/md_enums.h" diff --git a/src/gromacs/mdlib/repl_ex.cpp b/src/gromacs/mdlib/repl_ex.cpp index 909587bddc..efd89e5c4f 100644 --- a/src/gromacs/mdlib/repl_ex.cpp +++ b/src/gromacs/mdlib/repl_ex.cpp @@ -51,7 +51,7 @@ #include "gromacs/math/vec.h" #include "gromacs/mdlib/main.h" #include "gromacs/mdtypes/commrec.h" -#include "gromacs/mdtypes/forcerec.h" // only for gmx_enerdata_t +#include "gromacs/mdtypes/enerdata.h" #include "gromacs/mdtypes/inputrec.h" #include "gromacs/mdtypes/md_enums.h" #include "gromacs/mdtypes/state.h" diff --git a/src/gromacs/mdlib/shellfc.cpp b/src/gromacs/mdlib/shellfc.cpp index e14c604103..693435a530 100644 --- a/src/gromacs/mdlib/shellfc.cpp +++ b/src/gromacs/mdlib/shellfc.cpp @@ -63,6 +63,7 @@ #include "gromacs/mdlib/sim_util.h" #include "gromacs/mdlib/vsite.h" #include "gromacs/mdtypes/commrec.h" +#include "gromacs/mdtypes/forcerec.h" #include "gromacs/mdtypes/inputrec.h" #include "gromacs/mdtypes/md_enums.h" #include "gromacs/mdtypes/state.h" diff --git a/src/gromacs/mdlib/sim_util.h b/src/gromacs/mdlib/sim_util.h index 9899648ef4..60825471c8 100644 --- a/src/gromacs/mdlib/sim_util.h +++ b/src/gromacs/mdlib/sim_util.h @@ -46,9 +46,11 @@ #include "gromacs/utility/arrayref.h" struct gmx_output_env_t; +struct gmx_pme_t; struct gmx_update_t; struct MdrunOptions; struct nonbonded_verlet_t; +struct t_forcerec; struct t_mdatoms; struct t_nrnb; diff --git a/src/gromacs/mdlib/trajectory_writing.cpp b/src/gromacs/mdlib/trajectory_writing.cpp index cb27b6a626..61bf1b96e5 100644 --- a/src/gromacs/mdlib/trajectory_writing.cpp +++ b/src/gromacs/mdlib/trajectory_writing.cpp @@ -45,6 +45,7 @@ #include "gromacs/mdlib/sim_util.h" #include "gromacs/mdlib/update.h" #include "gromacs/mdtypes/commrec.h" +#include "gromacs/mdtypes/forcerec.h" #include "gromacs/mdtypes/inputrec.h" #include "gromacs/mdtypes/observableshistory.h" #include "gromacs/mdtypes/state.h" diff --git a/src/gromacs/mdlib/trajectory_writing.h b/src/gromacs/mdlib/trajectory_writing.h index d925ffa79f..9bf1fcfec5 100644 --- a/src/gromacs/mdlib/trajectory_writing.h +++ b/src/gromacs/mdlib/trajectory_writing.h @@ -3,7 +3,7 @@ * * Copyright (c) 1991-2000, University of Groningen, The Netherlands. * Copyright (c) 2001-2004, The GROMACS development team. - * Copyright (c) 2013,2014,2015,2016,2017, by the GROMACS development team, led by + * Copyright (c) 2013,2014,2015,2016,2017,2018, by the GROMACS development team, led by * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl, * and including many others, as listed in the AUTHORS file in the * top-level source directory and at http://www.gromacs.org. @@ -48,6 +48,7 @@ struct gmx_mtop_t; struct ObservablesHistory; struct t_commrec; struct t_filenm; +struct t_forcerec; #ifdef __cplusplus extern "C" { diff --git a/src/gromacs/mdrun/tpi.cpp b/src/gromacs/mdrun/tpi.cpp index b3d28a63da..acbe8a1b52 100644 --- a/src/gromacs/mdrun/tpi.cpp +++ b/src/gromacs/mdrun/tpi.cpp @@ -74,6 +74,7 @@ #include "gromacs/mdlib/update.h" #include "gromacs/mdlib/vsite.h" #include "gromacs/mdtypes/commrec.h" +#include "gromacs/mdtypes/forcerec.h" #include "gromacs/mdtypes/group.h" #include "gromacs/mdtypes/inputrec.h" #include "gromacs/mdtypes/md_enums.h" diff --git a/src/gromacs/mdtypes/enerdata.h b/src/gromacs/mdtypes/enerdata.h new file mode 100644 index 0000000000..eccbe71c94 --- /dev/null +++ b/src/gromacs/mdtypes/enerdata.h @@ -0,0 +1,66 @@ +/* + * This file is part of the GROMACS molecular simulation package. + * + * Copyright (c) 2018, by the GROMACS development team, led by + * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl, + * and including many others, as listed in the AUTHORS file in the + * top-level source directory and at http://www.gromacs.org. + * + * GROMACS is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 + * of the License, or (at your option) any later version. + * + * GROMACS is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with GROMACS; if not, see + * http://www.gnu.org/licenses, or write to the Free Software Foundation, + * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + * + * If you want to redistribute modifications to GROMACS, please + * consider that scientific software is very special. Version + * control is crucial - bugs must be traceable. We will be happy to + * consider code for inclusion in the official distribution, but + * derived work must not be called official GROMACS. Details are found + * in the README & COPYING files - if they are missing, get the + * official version at http://www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the research papers on the package. Check out http://www.gromacs.org. + */ +#ifndef GMX_MDTYPES_TYPES_ENERDATA_H +#define GMX_MDTYPES_TYPES_ENERDATA_H + +#include "gromacs/mdtypes/md_enums.h" +#include "gromacs/topology/idef.h" +#include "gromacs/utility/real.h" + +enum { + egCOULSR, egLJSR, egBHAMSR, + egCOUL14, egLJ14, egNR +}; + +struct gmx_grppairener_t +{ + int nener; /* The number of energy group pairs */ + real *ener[egNR]; /* Energy terms for each pair of groups */ +}; + +struct gmx_enerdata_t +{ + real term[F_NRE]; /* The energies for all different interaction types */ + struct gmx_grppairener_t grpp; + double dvdl_lin[efptNR]; /* Contributions to dvdl with linear lam-dependence */ + double dvdl_nonlin[efptNR]; /* Idem, but non-linear dependence */ + int n_lambda; + int fep_state; /*current fep state -- just for printing */ + double *enerpart_lambda; /* Partial energy for lambda and flambda[] */ + real foreign_term[F_NRE]; /* alternate array for storing foreign lambda energies */ + struct gmx_grppairener_t foreign_grpp; /* alternate array for storing foreign lambda energies */ +}; + +#endif diff --git a/src/gromacs/mdtypes/forcerec.h b/src/gromacs/mdtypes/forcerec.h index 52878e380d..3d7b207860 100644 --- a/src/gromacs/mdtypes/forcerec.h +++ b/src/gromacs/mdtypes/forcerec.h @@ -43,7 +43,6 @@ #endif #include "gromacs/mdtypes/interaction_const.h" #include "gromacs/mdtypes/md_enums.h" -#include "gromacs/topology/idef.h" #include "gromacs/utility/basedefinitions.h" #include "gromacs/utility/real.h" @@ -110,36 +109,6 @@ enum { enbvdwNONE, enbvdwLJ, enbvdwBHAM, enbvdwTAB, enbvdwNR }; -enum { - egCOULSR, egLJSR, egBHAMSR, - egCOUL14, egLJ14, egNR -}; -extern const char *egrp_nm[egNR+1]; - -struct gmx_grppairener_t -{ - int nener; /* The number of energy group pairs */ - real *ener[egNR]; /* Energy terms for each pair of groups */ -}; - -struct gmx_enerdata_t -{ - real term[F_NRE]; /* The energies for all different interaction types */ - struct gmx_grppairener_t grpp; - double dvdl_lin[efptNR]; /* Contributions to dvdl with linear lam-dependence */ - double dvdl_nonlin[efptNR]; /* Idem, but non-linear dependence */ - int n_lambda; - int fep_state; /*current fep state -- just for printing */ - double *enerpart_lambda; /* Partial energy for lambda and flambda[] */ - real foreign_term[F_NRE]; /* alternate array for storing foreign lambda energies */ - struct gmx_grppairener_t foreign_grpp; /* alternate array for storing foreign lambda energies */ -}; -/* The idea is that dvdl terms with linear lambda dependence will be added - * automatically to enerpart_lambda. Terms with non-linear lambda dependence - * should explicitly determine the energies at foreign lambda points - * when n_lambda > 0. - */ - struct cginfo_mb_t { int cg_start; diff --git a/src/gromacs/topology/block.h b/src/gromacs/topology/block.h index fdd0010365..9b4f9bddfe 100644 --- a/src/gromacs/topology/block.h +++ b/src/gromacs/topology/block.h @@ -39,20 +39,11 @@ #include -#ifdef __cplusplus #include -#endif #include "gromacs/utility/basedefinitions.h" -#ifdef __cplusplus #include "gromacs/utility/gmxassert.h" -#endif - -#ifdef __cplusplus -extern "C" { -#endif -#ifdef __cplusplus namespace gmx { @@ -194,7 +185,6 @@ class RangePartitioning }; } // nsamespace gmx -#endif // __cplusplus /* Deprecated, C-style version of BlockRanges */ typedef struct t_block @@ -212,7 +202,7 @@ typedef struct t_block int nalloc_index; /* The allocation size for index */ } t_block; -typedef struct t_blocka +struct t_blocka { int nr; /* The number of blocks */ int *index; /* Array of indices in a (dim: nr+1) */ @@ -225,7 +215,7 @@ typedef struct t_blocka /* to terminate the table */ int nalloc_index; /* The allocation size for index */ int nalloc_a; /* The allocation size for a */ -} t_blocka; +}; void init_block(t_block *block); void init_blocka(t_blocka *block); @@ -253,8 +243,4 @@ void stupid_fill_blocka(t_blocka *grp, int natom); void pr_block(FILE *fp, int indent, const char *title, const t_block *block, gmx_bool bShowNumbers); void pr_blocka(FILE *fp, int indent, const char *title, const t_blocka *block, gmx_bool bShowNumbers); -#ifdef __cplusplus -} -#endif - #endif diff --git a/src/gromacs/topology/idef.h b/src/gromacs/topology/idef.h index a8ad52068d..096c16efa7 100644 --- a/src/gromacs/topology/idef.h +++ b/src/gromacs/topology/idef.h @@ -43,10 +43,6 @@ #include "gromacs/utility/basedefinitions.h" #include "gromacs/utility/real.h" -#ifdef __cplusplus -extern "C" { -#endif - /* check kernel/toppush.c when you change these numbers */ #define MAXATOMLIST 6 #define MAXFORCEPARAM 12 @@ -399,8 +395,4 @@ void pr_ffparams(FILE *fp, int indent, const char *title, void pr_idef(FILE *fp, int indent, const char *title, const t_idef *idef, gmx_bool bShowNumbers, gmx_bool bShowParameters); -#ifdef __cplusplus -} -#endif - #endif diff --git a/src/gromacs/topology/ifunc.h b/src/gromacs/topology/ifunc.h index 2d7fb69adc..8bca6ce563 100644 --- a/src/gromacs/topology/ifunc.h +++ b/src/gromacs/topology/ifunc.h @@ -3,7 +3,7 @@ * * Copyright (c) 1991-2000, University of Groningen, The Netherlands. * Copyright (c) 2001-2004, The GROMACS development team. - * Copyright (c) 2012,2014,2015,2016, by the GROMACS development team, led by + * Copyright (c) 2012,2014,2015,2016,2018, by the GROMACS development team, led by * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl, * and including many others, as listed in the AUTHORS file in the * top-level source directory and at http://www.gromacs.org. @@ -39,10 +39,6 @@ #include "gromacs/topology/idef.h" -#ifdef __cplusplus -extern "C" { -#endif - struct t_fcdata; struct t_graph; struct t_mdatoms; @@ -128,8 +124,4 @@ typedef struct extern const t_interaction_function interaction_function[F_NRE]; /* initialised interaction functions descriptor */ -#ifdef __cplusplus -} -#endif - #endif diff --git a/src/gromacs/topology/symtab.h b/src/gromacs/topology/symtab.h index 40213d9a5b..93bf954817 100644 --- a/src/gromacs/topology/symtab.h +++ b/src/gromacs/topology/symtab.h @@ -3,7 +3,7 @@ * * Copyright (c) 1991-2000, University of Groningen, The Netherlands. * Copyright (c) 2001-2004, The GROMACS development team. - * Copyright (c) 2010,2014,2017, by the GROMACS development team, led by + * Copyright (c) 2010,2014,2017,2018, by the GROMACS development team, led by * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl, * and including many others, as listed in the AUTHORS file in the * top-level source directory and at http://www.gromacs.org. @@ -39,10 +39,6 @@ #include -#ifdef __cplusplus -extern "C" { -#endif - typedef struct t_symbuf { int bufsize; @@ -124,8 +120,4 @@ void pr_symtab(FILE *fp, int indent, const char *title, t_symtab *symtab); * to print a header text. */ -#ifdef __cplusplus -} -#endif - #endif