diff --git a/src/ASPHERE/atom_vec_ellipsoid.cpp b/src/ASPHERE/atom_vec_ellipsoid.cpp
index e48e7ae30358bd2b6805455aee171ad4cfc742eb..5d85e01ef138eebe201b1c390073e7a916972e56 100755
--- a/src/ASPHERE/atom_vec_ellipsoid.cpp
+++ b/src/ASPHERE/atom_vec_ellipsoid.cpp
@@ -15,9 +15,9 @@
    Contributing author: Mike Brown (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "atom_vec_ellipsoid.h"
-#include "lmptype.h"
 #include "math_extra.h"
 #include "atom.h"
 #include "force.h"
diff --git a/src/CLASS2/dihedral_class2.cpp b/src/CLASS2/dihedral_class2.cpp
index 9b43673da571d12e3a9aebfa10cd4450e7c9d004..df80d249a3a00bd7c0a4645dc7afd7d08f1dfb54 100644
--- a/src/CLASS2/dihedral_class2.cpp
+++ b/src/CLASS2/dihedral_class2.cpp
@@ -15,11 +15,11 @@
    Contributing author: Eric Simon (Cray)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "string.h"
 #include "stdlib.h"
 #include "dihedral_class2.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "neighbor.h"
 #include "update.h"
diff --git a/src/CLASS2/improper_class2.cpp b/src/CLASS2/improper_class2.cpp
index 7f0f31bc1fc0194832ccdfb20b858ce2fe10b2cc..57ada4cfc3a66cef018f0c4213fbd85bc4061e07 100644
--- a/src/CLASS2/improper_class2.cpp
+++ b/src/CLASS2/improper_class2.cpp
@@ -15,11 +15,11 @@
    Contributing author: Eric Simon (Cray)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "string.h"
 #include "stdlib.h"
 #include "improper_class2.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "neighbor.h"
 #include "update.h"
diff --git a/src/COLLOID/atom_vec_colloid.cpp b/src/COLLOID/atom_vec_colloid.cpp
index 0ba21a735609036afe052fa8d239cdd85ba5a99b..d35bfe7de8214112a72e91fad37e3c8bebfc6679 100644
--- a/src/COLLOID/atom_vec_colloid.cpp
+++ b/src/COLLOID/atom_vec_colloid.cpp
@@ -11,9 +11,9 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "atom_vec_colloid.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "force.h"
 #include "domain.h"
diff --git a/src/DIPOLE/atom_vec_dipole.cpp b/src/DIPOLE/atom_vec_dipole.cpp
index cc81711b4dd08610c5995e50faf44f8202ae15ec..bc254cbb61e01c1c181e7519e23b0a5833349064 100644
--- a/src/DIPOLE/atom_vec_dipole.cpp
+++ b/src/DIPOLE/atom_vec_dipole.cpp
@@ -11,9 +11,9 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "atom_vec_dipole.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "domain.h"
 #include "modify.h"
diff --git a/src/GPU/pair_cg_cmm_coul_long_gpu.cpp b/src/GPU/pair_cg_cmm_coul_long_gpu.cpp
index 3a5a58c5b2487f4c5c565e15b2347c8b08428b99..6d11692d5c7d96a78c88420351f7897bafe4cd18 100644
--- a/src/GPU/pair_cg_cmm_coul_long_gpu.cpp
+++ b/src/GPU/pair_cg_cmm_coul_long_gpu.cpp
@@ -15,11 +15,11 @@
    Contributing author: Mike Brown (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdio.h"
 #include "stdlib.h"
 #include "pair_cg_cmm_coul_long_gpu.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "atom_vec.h"
 #include "comm.h"
diff --git a/src/GPU/pair_cg_cmm_gpu.cpp b/src/GPU/pair_cg_cmm_gpu.cpp
index a49464fd58500d67ebce79052abf04cb761d3159..638815f367a551911d048edc4fdd9dd9d0258b96 100644
--- a/src/GPU/pair_cg_cmm_gpu.cpp
+++ b/src/GPU/pair_cg_cmm_gpu.cpp
@@ -15,11 +15,11 @@
    Contributing author: Mike Brown (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdio.h"
 #include "stdlib.h"
 #include "pair_cg_cmm_gpu.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "atom_vec.h"
 #include "comm.h"
diff --git a/src/GPU/pair_gayberne_gpu.cpp b/src/GPU/pair_gayberne_gpu.cpp
index b0e8af1df687a0e900f87f81bf1504e6c0cfeda0..eea45ad9786b91d979228fa85606ebf55174be9a 100644
--- a/src/GPU/pair_gayberne_gpu.cpp
+++ b/src/GPU/pair_gayberne_gpu.cpp
@@ -15,11 +15,11 @@
    Contributing author: Mike Brown (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdio.h"
 #include "stdlib.h"
 #include "pair_gayberne_gpu.h"
-#include "lmptype.h"
 #include "math_extra.h"
 #include "atom.h"
 #include "atom_vec.h"
diff --git a/src/GPU/pair_lj96_cut_gpu.cpp b/src/GPU/pair_lj96_cut_gpu.cpp
index e36ea857f207afb640b1786165cc66009cc9fc02..8da2391068ac85ef2d96c6a6edebcda9a6f57df8 100644
--- a/src/GPU/pair_lj96_cut_gpu.cpp
+++ b/src/GPU/pair_lj96_cut_gpu.cpp
@@ -15,11 +15,11 @@
    Contributing author: Mike Brown (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdio.h"
 #include "stdlib.h"
 #include "pair_lj96_cut_gpu.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "atom_vec.h"
 #include "comm.h"
diff --git a/src/GPU/pair_lj_charmm_coul_long_gpu.cpp b/src/GPU/pair_lj_charmm_coul_long_gpu.cpp
index a02d7018c998e592e8442c4494695db9299244a2..7be632c0017ff03bd98fcabdd61f47400411140b 100644
--- a/src/GPU/pair_lj_charmm_coul_long_gpu.cpp
+++ b/src/GPU/pair_lj_charmm_coul_long_gpu.cpp
@@ -15,11 +15,11 @@
    Contributing author: Mike Brown (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdio.h"
 #include "stdlib.h"
 #include "pair_lj_charmm_coul_long_gpu.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "atom_vec.h"
 #include "comm.h"
diff --git a/src/GPU/pair_lj_cut_coul_cut_gpu.cpp b/src/GPU/pair_lj_cut_coul_cut_gpu.cpp
index 3c8b1271f5c4a4066b184d75f233f7808f645427..2cb4027bc5aebe3723b5ae19fe63342ed0e6bd76 100644
--- a/src/GPU/pair_lj_cut_coul_cut_gpu.cpp
+++ b/src/GPU/pair_lj_cut_coul_cut_gpu.cpp
@@ -15,11 +15,11 @@
    Contributing author: Mike Brown (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdio.h"
 #include "stdlib.h"
 #include "pair_lj_cut_coul_cut_gpu.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "atom_vec.h"
 #include "comm.h"
diff --git a/src/GPU/pair_lj_cut_coul_long_gpu.cpp b/src/GPU/pair_lj_cut_coul_long_gpu.cpp
index 9782317d73dfd3fea815d9d3f292008e69f36fa1..86cba807047f9d82a58da24797eccee12018950e 100644
--- a/src/GPU/pair_lj_cut_coul_long_gpu.cpp
+++ b/src/GPU/pair_lj_cut_coul_long_gpu.cpp
@@ -15,11 +15,11 @@
    Contributing author: Mike Brown (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdio.h"
 #include "stdlib.h"
 #include "pair_lj_cut_coul_long_gpu.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "atom_vec.h"
 #include "comm.h"
diff --git a/src/GPU/pair_lj_cut_gpu.cpp b/src/GPU/pair_lj_cut_gpu.cpp
index 4c12e7d9f6a205168f3c2d3b627d882b61dd3b82..612a8e918d44fd5b637b50bfee16e4f5ba0bb0cf 100644
--- a/src/GPU/pair_lj_cut_gpu.cpp
+++ b/src/GPU/pair_lj_cut_gpu.cpp
@@ -15,11 +15,11 @@
    Contributing author: Mike Brown (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdio.h"
 #include "stdlib.h"
 #include "pair_lj_cut_gpu.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "atom_vec.h"
 #include "comm.h"
diff --git a/src/GRANULAR/atom_vec_granular.cpp b/src/GRANULAR/atom_vec_granular.cpp
index 0ebb38d8f2e2903d3ef64d85f3ba1b51b1a133dc..d70b4051da91171d9c539da3f8863b6ccd1de36e 100644
--- a/src/GRANULAR/atom_vec_granular.cpp
+++ b/src/GRANULAR/atom_vec_granular.cpp
@@ -11,11 +11,11 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdlib.h"
 #include "string.h"
 #include "atom_vec_granular.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "domain.h"
 #include "modify.h"
diff --git a/src/KSPACE/pppm.cpp b/src/KSPACE/pppm.cpp
index 306efb8ea2601cc048d2ba2653e0c492228d809e..ad43ff312051de258697f82ae371eafc8d9f16bd 100644
--- a/src/KSPACE/pppm.cpp
+++ b/src/KSPACE/pppm.cpp
@@ -15,13 +15,13 @@
    Contributing authors: Roy Pollock (LLNL), Paul Crozier (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "string.h"
 #include "stdio.h"
 #include "stdlib.h"
 #include "math.h"
 #include "pppm.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "comm.h"
 #include "neighbor.h"
diff --git a/src/KSPACE/pppm.h b/src/KSPACE/pppm.h
index 9ca04a754094875310822fd49bf10a6dbce38920..cb02853983b961b8dda5ebf76e622d76ef3cc412 100644
--- a/src/KSPACE/pppm.h
+++ b/src/KSPACE/pppm.h
@@ -20,8 +20,8 @@ KSpaceStyle(pppm,PPPM)
 #ifndef LMP_PPPM_H
 #define LMP_PPPM_H
 
-#include "kspace.h"
 #include "lmptype.h"
+#include "kspace.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/MANYBODY/fix_qeq_comb.cpp b/src/MANYBODY/fix_qeq_comb.cpp
index b734c5a1c2ae2866817c3029aeae4e3b0b9d850f..3552519ffe31b81c03760d05ee0352adc418648b 100644
--- a/src/MANYBODY/fix_qeq_comb.cpp
+++ b/src/MANYBODY/fix_qeq_comb.cpp
@@ -15,12 +15,12 @@
    Contributing author: Tzu-Ray Shan (U Florida, rayshan@ufl.edu)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "stdlib.h"
 #include "string.h"
 #include "fix_qeq_comb.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "force.h"
 #include "group.h"
diff --git a/src/MANYBODY/fix_qeq_comb.h b/src/MANYBODY/fix_qeq_comb.h
index 235b4c9c3edb9ca1101292fa39ec915a8b08078c..be3d6b227be20f6236d97af5a1ace1e7bcfd85d7 100644
--- a/src/MANYBODY/fix_qeq_comb.h
+++ b/src/MANYBODY/fix_qeq_comb.h
@@ -20,9 +20,9 @@ FixStyle(qeq/comb,FixQEQComb)
 #ifndef LMP_FIX_QEQ_COMB_H
 #define LMP_FIX_QEQ_COMB_H
 
+#include "lmptype.h"
 #include "stdio.h"
 #include "fix.h"
-#include "lmptype.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/MOLECULE/atom_vec_angle.cpp b/src/MOLECULE/atom_vec_angle.cpp
index 33390ee34d7118b92f38da8ebbc505d7e5f9f18f..13688b002fc26d5cee7aa80733a6b127020aeefd 100644
--- a/src/MOLECULE/atom_vec_angle.cpp
+++ b/src/MOLECULE/atom_vec_angle.cpp
@@ -11,9 +11,9 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "atom_vec_angle.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "domain.h"
 #include "modify.h"
diff --git a/src/MOLECULE/atom_vec_bond.cpp b/src/MOLECULE/atom_vec_bond.cpp
index 13ea1e5e2ba94867406a6529eb1949c663d2992f..bda7cb97cb70400618188697c7e33271c0fbd641 100644
--- a/src/MOLECULE/atom_vec_bond.cpp
+++ b/src/MOLECULE/atom_vec_bond.cpp
@@ -11,9 +11,9 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "atom_vec_bond.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "domain.h"
 #include "modify.h"
diff --git a/src/MOLECULE/atom_vec_full.cpp b/src/MOLECULE/atom_vec_full.cpp
index 2d733ebf410ba7c71f116022ca61edf568470c00..1fe0d4fda963e5ca28842713c7ebd7d62f9d5093 100644
--- a/src/MOLECULE/atom_vec_full.cpp
+++ b/src/MOLECULE/atom_vec_full.cpp
@@ -11,9 +11,9 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "atom_vec_full.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "domain.h"
 #include "modify.h"
diff --git a/src/MOLECULE/atom_vec_molecular.cpp b/src/MOLECULE/atom_vec_molecular.cpp
index 07c46724aabaf84acf50479b587d6fa35f1fedc7..a2ff7c19c80aec439f41cef9d2f53f0e172bd739 100644
--- a/src/MOLECULE/atom_vec_molecular.cpp
+++ b/src/MOLECULE/atom_vec_molecular.cpp
@@ -11,9 +11,9 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "atom_vec_molecular.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "domain.h"
 #include "modify.h"
diff --git a/src/MOLECULE/bond_fene.cpp b/src/MOLECULE/bond_fene.cpp
index a2ac3edcf633370ce0baf0b6b21757c318313859..6c2f53cc84416ad8dceea8322d6f5872d2643256 100644
--- a/src/MOLECULE/bond_fene.cpp
+++ b/src/MOLECULE/bond_fene.cpp
@@ -11,10 +11,10 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdlib.h"
 #include "bond_fene.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "neighbor.h"
 #include "domain.h"
diff --git a/src/MOLECULE/bond_fene_expand.cpp b/src/MOLECULE/bond_fene_expand.cpp
index e62894102562143c2066ab3d66eeae9b826d1ebb..cb2fc5d723994d5d255721a886d8125ef843d80c 100644
--- a/src/MOLECULE/bond_fene_expand.cpp
+++ b/src/MOLECULE/bond_fene_expand.cpp
@@ -11,10 +11,10 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdlib.h"
 #include "bond_fene_expand.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "neighbor.h"
 #include "domain.h"
diff --git a/src/MOLECULE/dihedral_charmm.cpp b/src/MOLECULE/dihedral_charmm.cpp
index 5bfbd69aac37127b73b0d5c606e641ce90b7434f..57248ff1488558ff95c110a2550dcd3300a324bc 100644
--- a/src/MOLECULE/dihedral_charmm.cpp
+++ b/src/MOLECULE/dihedral_charmm.cpp
@@ -15,11 +15,11 @@
    Contributing author: Paul Crozier (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "stdlib.h"
 #include "dihedral_charmm.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "comm.h"
 #include "neighbor.h"
diff --git a/src/MOLECULE/dihedral_harmonic.cpp b/src/MOLECULE/dihedral_harmonic.cpp
index f4dad74653b6a2f130eee298578749c1b07996d2..e4effc6f24c2aef7237cf50b965120474d74c0bb 100644
--- a/src/MOLECULE/dihedral_harmonic.cpp
+++ b/src/MOLECULE/dihedral_harmonic.cpp
@@ -15,11 +15,11 @@
    Contributing author: Paul Crozier (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "stdlib.h"
 #include "dihedral_harmonic.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "comm.h"
 #include "neighbor.h"
diff --git a/src/MOLECULE/dihedral_helix.cpp b/src/MOLECULE/dihedral_helix.cpp
index d9c4b78f72fec5fa129f93e5e0566e50f778aeb5..42c4d5eb4a9f8a9326157be9361b12dfa303cd95 100644
--- a/src/MOLECULE/dihedral_helix.cpp
+++ b/src/MOLECULE/dihedral_helix.cpp
@@ -16,11 +16,11 @@
                          Mark Stevens (Sandia)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdlib.h"
 #include "mpi.h"
 #include "dihedral_helix.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "neighbor.h"
 #include "domain.h"
diff --git a/src/MOLECULE/dihedral_multi_harmonic.cpp b/src/MOLECULE/dihedral_multi_harmonic.cpp
index 4636089e4e4cb0a1b46c9c15e197461b381d2fc1..4d4dd429db56290154bde1bfec7f195582838e8d 100644
--- a/src/MOLECULE/dihedral_multi_harmonic.cpp
+++ b/src/MOLECULE/dihedral_multi_harmonic.cpp
@@ -15,10 +15,10 @@
    Contributing author: Mathias Puetz (SNL) and friends
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdlib.h"
 #include "dihedral_multi_harmonic.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "neighbor.h"
 #include "domain.h"
diff --git a/src/MOLECULE/dihedral_opls.cpp b/src/MOLECULE/dihedral_opls.cpp
index 5ef2d0b7ce1995e570282fe550bf2e1e189183a9..6750d3b157a2db84a9dd711f347592f5b8126759 100644
--- a/src/MOLECULE/dihedral_opls.cpp
+++ b/src/MOLECULE/dihedral_opls.cpp
@@ -15,10 +15,10 @@
    Contributing author: Mark Stevens (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdlib.h"
 #include "dihedral_opls.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "comm.h"
 #include "neighbor.h"
diff --git a/src/MOLECULE/improper_cvff.cpp b/src/MOLECULE/improper_cvff.cpp
index b688a599899e4b24d20611ed99b14797c0660708..4fdb71094828c61e8335e14d2fb0baaa468d110a 100644
--- a/src/MOLECULE/improper_cvff.cpp
+++ b/src/MOLECULE/improper_cvff.cpp
@@ -11,11 +11,11 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "stdlib.h"
 #include "improper_cvff.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "comm.h"
 #include "neighbor.h"
diff --git a/src/MOLECULE/improper_harmonic.cpp b/src/MOLECULE/improper_harmonic.cpp
index 527fbf19b81019f454233d5d9a83ebc6e10d50bd..feae8a38696b369f8cb73f5d58673bc7fb6fbb76 100644
--- a/src/MOLECULE/improper_harmonic.cpp
+++ b/src/MOLECULE/improper_harmonic.cpp
@@ -11,11 +11,11 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "stdlib.h"
 #include "improper_harmonic.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "comm.h"
 #include "neighbor.h"
diff --git a/src/PERI/atom_vec_peri.cpp b/src/PERI/atom_vec_peri.cpp
index d20809e6bd8ca8a9ef04126ab9bf99b51f171437..a674ab3bcdedfdf9b3ea7283c73d78e124da46bc 100644
--- a/src/PERI/atom_vec_peri.cpp
+++ b/src/PERI/atom_vec_peri.cpp
@@ -15,10 +15,10 @@
    Contributing author: Mike Parks (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "float.h"
 #include "stdlib.h"
 #include "atom_vec_peri.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "domain.h"
 #include "modify.h"
diff --git a/src/REAX/fix_reax_bonds.cpp b/src/REAX/fix_reax_bonds.cpp
index 0607acc5b684c828863fccc333f3aa0ede74c551..3d3698b77bda48e4ad6eff4f59542028b0ba2836 100644
--- a/src/REAX/fix_reax_bonds.cpp
+++ b/src/REAX/fix_reax_bonds.cpp
@@ -15,10 +15,10 @@
    Contributing author: Aidan Thompson (Sandia)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "string.h"
 #include "fix_reax_bonds.h"
-#include "lmptype.h"
 #include "pair_reax_fortran.h"
 #include "atom.h"
 #include "update.h"
diff --git a/src/REAX/fix_reax_bonds.h b/src/REAX/fix_reax_bonds.h
index 42bc6ea060e4604530f05fb8205dc93a7adac3ac..678984f022dfb3f7ffab6dc6d3069ce14fb35678 100644
--- a/src/REAX/fix_reax_bonds.h
+++ b/src/REAX/fix_reax_bonds.h
@@ -20,9 +20,9 @@ FixStyle(reax/bonds,FixReaxBonds)
 #ifndef LMP_FIX_REAX_BONDS_H
 #define LMP_FIX_REAX_BONDS_H
 
+#include "lmptype.h"
 #include "stdio.h"
 #include "fix.h"
-#include "lmptype.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/REPLICA/fix_event_prd.cpp b/src/REPLICA/fix_event_prd.cpp
index 3fba4da909389545c09db9ddc91915387512a5af..ac428f3713a635df579f14c6ef8741e43ec81d28 100644
--- a/src/REPLICA/fix_event_prd.cpp
+++ b/src/REPLICA/fix_event_prd.cpp
@@ -15,10 +15,10 @@
    Contributing author: Mike Brown (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "string.h"
 #include "fix_event_prd.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "update.h"
 #include "domain.h"
diff --git a/src/REPLICA/fix_event_prd.h b/src/REPLICA/fix_event_prd.h
index 18f77b324ac549c3bd5c575ae31676ea10ded86d..e5aaa8ccdc6b6d9de24d75882a13ddb3ca0d16b3 100644
--- a/src/REPLICA/fix_event_prd.h
+++ b/src/REPLICA/fix_event_prd.h
@@ -20,8 +20,8 @@ FixStyle(EVENT/PRD,FixEventPRD)
 #ifndef LMP_FIX_EVENT_PRD_H
 #define LMP_FIX_EVENT_PRD_H
 
-#include "fix_event.h"
 #include "lmptype.h"
+#include "fix_event.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/REPLICA/fix_event_tad.cpp b/src/REPLICA/fix_event_tad.cpp
index 8968ec8b7a5dc57755c36ba9a34464eb76be7562..950fcd6b80308fdaa22dd593feef5bcc2f098cea 100644
--- a/src/REPLICA/fix_event_tad.cpp
+++ b/src/REPLICA/fix_event_tad.cpp
@@ -15,10 +15,10 @@
    Contributing author: Mike Brown (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "string.h"
 #include "fix_event_tad.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "update.h"
 #include "domain.h"
diff --git a/src/REPLICA/fix_event_tad.h b/src/REPLICA/fix_event_tad.h
index 2b6067e9e2531106d1439348d5a0831122a06355..ccd3c1cd4b0c75445889d284e04e7cfb0cc88c2a 100644
--- a/src/REPLICA/fix_event_tad.h
+++ b/src/REPLICA/fix_event_tad.h
@@ -20,8 +20,8 @@ FixStyle(EVENT/TAD,FixEventTAD)
 #ifndef LMP_FIX_EVENT_TAD_H
 #define LMP_FIX_EVENT_TAD_H
 
-#include "fix_event.h"
 #include "lmptype.h"
+#include "fix_event.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/REPLICA/neb.cpp b/src/REPLICA/neb.cpp
index fe5e74a1d460bfb62f0f889fb4a88386c2b52718..ebe45eeeeb4ab3a6027f0dedf5496042d6bff87d 100644
--- a/src/REPLICA/neb.cpp
+++ b/src/REPLICA/neb.cpp
@@ -11,12 +11,12 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "stdlib.h"
 #include "string.h"
 #include "neb.h"
-#include "lmptype.h"
 #include "universe.h"
 #include "atom.h"
 #include "update.h"
diff --git a/src/REPLICA/prd.cpp b/src/REPLICA/prd.cpp
index 28ec841d4daecd6fdffb2ecadc8809d16d6000f1..84d711270580bb5b94ce8c3a60bdc38c9bc45269 100644
--- a/src/REPLICA/prd.cpp
+++ b/src/REPLICA/prd.cpp
@@ -15,12 +15,12 @@
    Contributing author: Mike Brown (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "stdlib.h"
 #include "string.h"
 #include "prd.h"
-#include "lmptype.h"
 #include "universe.h"
 #include "update.h"
 #include "atom.h"
diff --git a/src/REPLICA/temper.cpp b/src/REPLICA/temper.cpp
index 4befb443b35730965741dedab2dfe7253fd5c950..ea8fcfaab67aba909a3e300957c2965b5ecb2237 100644
--- a/src/REPLICA/temper.cpp
+++ b/src/REPLICA/temper.cpp
@@ -15,11 +15,11 @@
    Contributing author: Mark Sears (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdlib.h"
 #include "string.h"
 #include "temper.h"
-#include "lmptype.h"
 #include "universe.h"
 #include "domain.h"
 #include "atom.h"
diff --git a/src/SRD/fix_wall_srd.h b/src/SRD/fix_wall_srd.h
index ed5afcde3ba23f9f313ff3dbd7ddae02b4d50d49..2ad5fdcdfca615596d11528378eccef4477e7e1a 100644
--- a/src/SRD/fix_wall_srd.h
+++ b/src/SRD/fix_wall_srd.h
@@ -20,8 +20,8 @@ FixStyle(wall/srd,FixWallSRD)
 #ifndef LMP_FIX_WALL_SRD_H
 #define LMP_FIX_WALL_SRD_H
 
-#include "fix.h"
 #include "lmptype.h"
+#include "fix.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/USER-EFF/atom_vec_electron.cpp b/src/USER-EFF/atom_vec_electron.cpp
index ceba59846b9adedd7c1f194309fcba04fc45bda8..20e33a091958f353ae93011de5d590a3b1e2728d 100644
--- a/src/USER-EFF/atom_vec_electron.cpp
+++ b/src/USER-EFF/atom_vec_electron.cpp
@@ -15,9 +15,9 @@
    Contributing author: Andres Jaramillo-Botero (Caltech)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "atom_vec_electron.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "domain.h"
 #include "modify.h"
diff --git a/src/atom.h b/src/atom.h
index 563bc9b1c0aa2241d68aa7c618a92465d8297333..8821e7c48c5737e406220b9673f438cad087d6cf 100644
--- a/src/atom.h
+++ b/src/atom.h
@@ -14,8 +14,8 @@
 #ifndef LMP_ATOM_H
 #define LMP_ATOM_H
 
-#include "pointers.h"
 #include "lmptype.h"
+#include "pointers.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/atom_vec_atomic.cpp b/src/atom_vec_atomic.cpp
index 13dd6b4a9bec7b721b0b553f31fad393dffe740b..e574c387a573b1706812a2d8bf28fc7a1d053d78 100644
--- a/src/atom_vec_atomic.cpp
+++ b/src/atom_vec_atomic.cpp
@@ -11,9 +11,9 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "atom_vec_atomic.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "domain.h"
 #include "modify.h"
diff --git a/src/atom_vec_charge.cpp b/src/atom_vec_charge.cpp
index 69a918562fb9f3238217ffcb69ab5a2be1196345..ed2053a52f4c5b4d263980289ac009531c04c586 100644
--- a/src/atom_vec_charge.cpp
+++ b/src/atom_vec_charge.cpp
@@ -11,9 +11,9 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "atom_vec_charge.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "domain.h"
 #include "modify.h"
diff --git a/src/atom_vec_hybrid.cpp b/src/atom_vec_hybrid.cpp
index 8be54a1029e559e70e3bfa919b6963680e66300d..12b1591589856d59cd2c53cbf3e06c7467978522 100644
--- a/src/atom_vec_hybrid.cpp
+++ b/src/atom_vec_hybrid.cpp
@@ -11,10 +11,10 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "string.h"
 #include "atom_vec_hybrid.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "domain.h"
 #include "modify.h"
diff --git a/src/compute.cpp b/src/compute.cpp
index 27e7ff564cab44a7931d1a4f2fdc7884230fc6f6..44c628e27ad9532004e410b3bc5fb771626c948c 100644
--- a/src/compute.cpp
+++ b/src/compute.cpp
@@ -11,12 +11,12 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "stdlib.h"
 #include "string.h"
 #include "ctype.h"
 #include "compute.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "domain.h"
 #include "comm.h"
diff --git a/src/compute.h b/src/compute.h
index cb7c3152fc71cb6dd3eff40e07fa726405872346..f7ece5d38add294b6f0e7f77aef93a8773667aec 100644
--- a/src/compute.h
+++ b/src/compute.h
@@ -14,8 +14,8 @@
 #ifndef LMP_COMPUTE_H
 #define LMP_COMPUTE_H
 
-#include "pointers.h"
 #include "lmptype.h"
+#include "pointers.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/compute_reduce.cpp b/src/compute_reduce.cpp
index da1ff6bcbd186593881f09e90db419895686845f..149517ae35824708f43b923fa7027392b4f236e9 100644
--- a/src/compute_reduce.cpp
+++ b/src/compute_reduce.cpp
@@ -11,10 +11,10 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "string.h"
 #include "stdlib.h"
 #include "compute_reduce.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "update.h"
 #include "domain.h"
diff --git a/src/compute_reduce.h b/src/compute_reduce.h
index c0d6a597654ed50dd50654b1ee74849e9a416f86..04ffd40c63516fbf2edc75e9807adb9909257173 100644
--- a/src/compute_reduce.h
+++ b/src/compute_reduce.h
@@ -20,8 +20,8 @@ ComputeStyle(reduce,ComputeReduce)
 #ifndef LMP_COMPUTE_REDUCE_H
 #define LMP_COMPUTE_REDUCE_H
 
-#include "compute.h"
 #include "lmptype.h"
+#include "compute.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/compute_reduce_region.h b/src/compute_reduce_region.h
index 55249b0ef6b790fa3d300a648b563840d2bfe181..a1b9ee169557c3c4272799ee10a32039a1329176 100644
--- a/src/compute_reduce_region.h
+++ b/src/compute_reduce_region.h
@@ -20,8 +20,8 @@ ComputeStyle(reduce/region,ComputeReduceRegion)
 #ifndef LMP_COMPUTE_REDUCE_REGION_H
 #define LMP_COMPUTE_REDUCE_REGION_H
 
-#include "compute_reduce.h"
 #include "lmptype.h"
+#include "compute_reduce.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/create_atoms.cpp b/src/create_atoms.cpp
index 11eda7d7ede8bf975d706fa6803f30e5d9b56208..1f7d3ef655bbe485fea7c40482e228613aca7a76 100644
--- a/src/create_atoms.cpp
+++ b/src/create_atoms.cpp
@@ -11,11 +11,11 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdlib.h"
 #include "string.h"
 #include "create_atoms.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "atom_vec.h"
 #include "comm.h"
diff --git a/src/delete_atoms.cpp b/src/delete_atoms.cpp
index d92085ffe0d604efcdfb582536af1a5e044a3738..ecddab700edb2c6e04e24cee6a04761e6a1b4d2d 100644
--- a/src/delete_atoms.cpp
+++ b/src/delete_atoms.cpp
@@ -11,10 +11,10 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "string.h"
 #include "delete_atoms.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "atom_vec.h"
 #include "comm.h"
diff --git a/src/displace_atoms.cpp b/src/displace_atoms.cpp
index 64cb195df6e825a5c42a90d79c16ac4ad44d956b..f433541d9ef90c5568f9d0dbb4d31a62089e45a3 100644
--- a/src/displace_atoms.cpp
+++ b/src/displace_atoms.cpp
@@ -11,11 +11,11 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "stdlib.h"
 #include "string.h"
 #include "displace_atoms.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "modify.h"
 #include "domain.h"
diff --git a/src/displace_box.cpp b/src/displace_box.cpp
index e8b88fb3142cb6ebc5e70667763a0df131298c55..f2e3363a6d2454f480a49e349cff71912a2ad740 100644
--- a/src/displace_box.cpp
+++ b/src/displace_box.cpp
@@ -11,12 +11,12 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "stdlib.h"
 #include "string.h"
 #include "displace_box.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "modify.h"
 #include "domain.h"
diff --git a/src/dump.cpp b/src/dump.cpp
index 6bd3018a0f4ba19d4ffa48edb925928befa303ba..d082ac29d6cc49ea96b4be55142a4602893e58bc 100644
--- a/src/dump.cpp
+++ b/src/dump.cpp
@@ -11,12 +11,12 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "stdlib.h"
 #include "string.h"
 #include "stdio.h"
 #include "dump.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "irregular.h"
 #include "update.h"
diff --git a/src/dump.h b/src/dump.h
index 4b4aeb289d367019b3e21aec0423f96d1353c75f..0f50c20bfaa28c6acc0d52f24d02b62761eef591 100644
--- a/src/dump.h
+++ b/src/dump.h
@@ -14,9 +14,9 @@
 #ifndef LMP_DUMP_H
 #define LMP_DUMP_H
 
+#include "lmptype.h"
 #include "stdio.h"
 #include "pointers.h"
-#include "lmptype.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/dump_dcd.cpp b/src/dump_dcd.cpp
index 5235ccdf899635c9590d4821754d734c1e2d5bef..ebf9e72e915e9ac5fa6f434a0f2ff0e9bbc2afe2 100644
--- a/src/dump_dcd.cpp
+++ b/src/dump_dcd.cpp
@@ -16,13 +16,13 @@
                         Axel Kohlmeyer (Temple U), support for groups
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "inttypes.h"
 #include "stdio.h"
 #include "time.h"
 #include "string.h"
 #include "dump_dcd.h"
-#include "lmptype.h"
 #include "domain.h"
 #include "atom.h"
 #include "update.h"
diff --git a/src/fix.h b/src/fix.h
index c44cccfa2875de1f644e07b5675c0b5f13649753..4cd938e05b3251d7d1cb0ad08200dcb272a1cace 100644
--- a/src/fix.h
+++ b/src/fix.h
@@ -14,8 +14,8 @@
 #ifndef LMP_FIX_H
 #define LMP_FIX_H
 
-#include "pointers.h"
 #include "lmptype.h"
+#include "pointers.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/fix_ave_atom.cpp b/src/fix_ave_atom.cpp
index ef7de11d3ec5b6dd725a8e7140c2f414fe318db5..ee2cf2b2d0cb2188a6557028546ef8494bf43cb3 100644
--- a/src/fix_ave_atom.cpp
+++ b/src/fix_ave_atom.cpp
@@ -11,10 +11,10 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "string.h"
 #include "fix_ave_atom.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "domain.h"
 #include "update.h"
diff --git a/src/fix_ave_atom.h b/src/fix_ave_atom.h
index 409b78cc25e51ffc6e3552125c276f087fa56a15..790b6252fd6ef7931ed3a52cea1bcf8eb55e5350 100644
--- a/src/fix_ave_atom.h
+++ b/src/fix_ave_atom.h
@@ -20,9 +20,9 @@ FixStyle(ave/atom,FixAveAtom)
 #ifndef LMP_FIX_AVE_ATOM_H
 #define LMP_FIX_AVE_ATOM_H
 
+#include "lmptype.h"
 #include "stdio.h"
 #include "fix.h"
-#include "lmptype.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/fix_ave_correlate.cpp b/src/fix_ave_correlate.cpp
index 4984c587cf07e604ffe41a1fe814731bbb2913b0..4660662e04d1de24c21d2ad3747e1d878a55e58d 100644
--- a/src/fix_ave_correlate.cpp
+++ b/src/fix_ave_correlate.cpp
@@ -17,10 +17,10 @@
      Reese Jones (Sandia)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "string.h"
 #include "fix_ave_correlate.h"
-#include "lmptype.h"
 #include "update.h"
 #include "modify.h"
 #include "compute.h"
diff --git a/src/fix_ave_correlate.h b/src/fix_ave_correlate.h
index e5dc5046c98648a95b48d1b5b0459b55564a9c7c..ea8a5cb4ef48d64a14cf46f9776245fc954763d5 100644
--- a/src/fix_ave_correlate.h
+++ b/src/fix_ave_correlate.h
@@ -20,9 +20,9 @@ FixStyle(ave/correlate,FixAveCorrelate)
 #ifndef LMP_FIX_AVE_CORRELATE_H
 #define LMP_FIX_AVE_CORRELATE_H
 
+#include "lmptype.h"
 #include "stdio.h"
 #include "fix.h"
-#include "lmptype.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/fix_ave_histo.cpp b/src/fix_ave_histo.cpp
index c90c5a0fef1a9171342fa383eaf3c92bb927efb4..b5f94b3e7b2a02d78b9ce0dfc61eeb73059e9a1b 100644
--- a/src/fix_ave_histo.cpp
+++ b/src/fix_ave_histo.cpp
@@ -11,10 +11,10 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "string.h"
 #include "fix_ave_histo.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "update.h"
 #include "modify.h"
diff --git a/src/fix_ave_histo.h b/src/fix_ave_histo.h
index 7dc63220b071e02e925c5380d993c7cec61a0783..c2c870223334c7c91b172143f3bebcabe07b3d7a 100644
--- a/src/fix_ave_histo.h
+++ b/src/fix_ave_histo.h
@@ -20,9 +20,9 @@ FixStyle(ave/histo,FixAveHisto)
 #ifndef LMP_FIX_AVE_HISTO_H
 #define LMP_FIX_AVE_HISTO_H
 
+#include "lmptype.h"
 #include "stdio.h"
 #include "fix.h"
-#include "lmptype.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/fix_ave_spatial.cpp b/src/fix_ave_spatial.cpp
index 511e429faa6ac225f530aa1f60acf50a027f3c36..734425b3abfb0cd1f11d313581c51df33a0f421d 100644
--- a/src/fix_ave_spatial.cpp
+++ b/src/fix_ave_spatial.cpp
@@ -15,10 +15,10 @@
    Contributing author: Pieter in 't Veld (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "string.h"
 #include "fix_ave_spatial.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "update.h"
 #include "force.h"
diff --git a/src/fix_ave_spatial.h b/src/fix_ave_spatial.h
index eefd20347eb8fce2c51ed1650a44bc2504ec0b84..80dcee0049fcf9099f6dd9f91c38cefc9ea2254b 100644
--- a/src/fix_ave_spatial.h
+++ b/src/fix_ave_spatial.h
@@ -20,9 +20,9 @@ FixStyle(ave/spatial,FixAveSpatial)
 #ifndef LMP_FIX_AVE_SPATIAL_H
 #define LMP_FIX_AVE_SPATIAL_H
 
+#include "lmptype.h"
 #include "stdio.h"
 #include "fix.h"
-#include "lmptype.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/fix_ave_time.cpp b/src/fix_ave_time.cpp
index d3c4f3207badb9590121c64f2cc6774bc8d48301..8a72d054a2bda4efb3c12cfcd7243b5e9618db73 100644
--- a/src/fix_ave_time.cpp
+++ b/src/fix_ave_time.cpp
@@ -15,10 +15,10 @@
    Contributing author: Pieter in 't Veld (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "string.h"
 #include "fix_ave_time.h"
-#include "lmptype.h"
 #include "update.h"
 #include "modify.h"
 #include "compute.h"
diff --git a/src/fix_ave_time.h b/src/fix_ave_time.h
index a8c118d39f6ee8f1d0fb7fd6f0511fa668a7fca9..fafd21e509ee00cbd8e771e3874ff88ff4b6616b 100644
--- a/src/fix_ave_time.h
+++ b/src/fix_ave_time.h
@@ -20,9 +20,9 @@ FixStyle(ave/time,FixAveTime)
 #ifndef LMP_FIX_AVE_TIME_H
 #define LMP_FIX_AVE_TIME_H
 
+#include "lmptype.h"
 #include "stdio.h"
 #include "fix.h"
-#include "lmptype.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/fix_dt_reset.h b/src/fix_dt_reset.h
index ddba09c73de64211a3e274107c0c1607a8d47638..095f8c9cac07513997ff1aa93a7a477853e07597 100644
--- a/src/fix_dt_reset.h
+++ b/src/fix_dt_reset.h
@@ -20,8 +20,8 @@ FixStyle(dt/reset,FixDtReset)
 #ifndef LMP_FIX_DT_RESET_H
 #define LMP_FIX_DT_RESET_H
 
-#include "fix.h"
 #include "lmptype.h"
+#include "fix.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/fix_shake.cpp b/src/fix_shake.cpp
index 70e1fbb4e63b81eecab9175e394f8d4d4a69a8a9..83ff409112bf508fcc180d73f461caa2f78b5075 100644
--- a/src/fix_shake.cpp
+++ b/src/fix_shake.cpp
@@ -11,13 +11,13 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "stdlib.h"
 #include "string.h"
 #include "stdio.h"
 #include "fix_shake.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "atom_vec.h"
 #include "update.h"
diff --git a/src/fix_shake.h b/src/fix_shake.h
index fc919aaa11f36ee23e9e3def33756cce16dbe440..ef061dc9df300d144408f8db098f65bf380a3512 100644
--- a/src/fix_shake.h
+++ b/src/fix_shake.h
@@ -20,8 +20,8 @@ FixStyle(shake,FixShake)
 #ifndef LMP_FIX_SHAKE_H
 #define LMP_FIX_SHAKE_H
 
-#include "fix.h"
 #include "lmptype.h"
+#include "fix.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/fix_tmd.cpp b/src/fix_tmd.cpp
index 24cb8bc8fc503a73ef7d41c54999fb2c84a66694..496b508619e32531354b5c00a8b692fd7bead63f 100644
--- a/src/fix_tmd.cpp
+++ b/src/fix_tmd.cpp
@@ -16,12 +16,12 @@
                          Christian Burisch (Bochum Univeristy, Germany)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "stdlib.h"
 #include "string.h"
 #include "fix_tmd.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "update.h"
 #include "modify.h"
diff --git a/src/fix_ttm.cpp b/src/fix_ttm.cpp
index 4edfba1bba212c1775450a0add5f4e68224112d1..d486cf49e61d34f8fd373f5cec05feea9a442bcd 100644
--- a/src/fix_ttm.cpp
+++ b/src/fix_ttm.cpp
@@ -16,12 +16,12 @@
                          Carolyn Phillips (University of Michigan)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "string.h"
 #include "stdlib.h"
 #include "fix_ttm.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "force.h"
 #include "update.h"
diff --git a/src/group.cpp b/src/group.cpp
index 79a526b5b763bb31e27dfaa63c0a6da9d49fa155..b5803ccdb568b1bf924c77d5964c00c8c7c0b501 100644
--- a/src/group.cpp
+++ b/src/group.cpp
@@ -11,13 +11,13 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "mpi.h"
 #include "stdio.h"
 #include "string.h"
 #include "stdlib.h"
 #include "group.h"
-#include "lmptype.h"
 #include "domain.h"
 #include "atom.h"
 #include "force.h"
diff --git a/src/group.h b/src/group.h
index cc0938f4a0ce230bf342b42dedd2b45deada27f1..9621aa850f278ac611497c08bf603d72663eafcf 100644
--- a/src/group.h
+++ b/src/group.h
@@ -14,9 +14,9 @@
 #ifndef LMP_GROUP_H
 #define LMP_GROUP_H
 
+#include "lmptype.h"
 #include "stdio.h"
 #include "pointers.h"
-#include "lmptype.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/integrate.cpp b/src/integrate.cpp
index 5b7d8df198b7ac40a91fe97df5615da6615ba3cb..80bf89f676e611ec991d850e94350753988a8e1f 100644
--- a/src/integrate.cpp
+++ b/src/integrate.cpp
@@ -11,9 +11,9 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "integrate.h"
-#include "lmptype.h"
 #include "update.h"
 #include "modify.h"
 #include "compute.h"
diff --git a/src/integrate.h b/src/integrate.h
index bcbc7119218a45ff6856b8a2a6a3be2824042e07..d869ceac239258e3992b0868f957263c9530adc5 100644
--- a/src/integrate.h
+++ b/src/integrate.h
@@ -14,8 +14,8 @@
 #ifndef LMP_INTEGRATE_H
 #define LMP_INTEGRATE_H
 
-#include "pointers.h"
 #include "lmptype.h"
+#include "pointers.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/library.cpp b/src/library.cpp
index 2b2cc3977801e9590bef134a4fdb594b89e70245..fd58515d29eaf84b0f78b359a4a9257e7306880c 100644
--- a/src/library.cpp
+++ b/src/library.cpp
@@ -14,11 +14,11 @@
 // C or Fortran style library interface to LAMMPS
 // customize by adding new LAMMPS-specific functions
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "string.h"
 #include "stdlib.h"
 #include "library.h"
-#include "lmptype.h"
 #include "lammps.h"
 #include "input.h"
 #include "atom.h"
diff --git a/src/lmptype.h b/src/lmptype.h
index af2bf465d3c2876c0c8678033039b975f923fb46..a1f6662fe6a875d77bd3542f978e0b36af4f9c31 100644
--- a/src/lmptype.h
+++ b/src/lmptype.h
@@ -13,7 +13,7 @@
 
 // define integer data types used by LAMMPS and associated size limits
 
-// smallint = variables for system on 1 processor (nlocal, nmax, etc)
+// smallint = variables for on-procesor system (nlocal, nmax, etc)
 // tagint = variables for atom IDs (tag)
 // bigint = variables for total system (natoms, ntimestep, etc)
 
@@ -22,24 +22,21 @@
 // NOTE: 64-bit tagint is not yet supported
 // bigint can be 32-bit or 64-bit int, must be >= tagint
 
-// MAXSMALLINT = max value of a smallint
-// MAXTAGINT = max value of a tagint
-// MAXBIGINT = max value of a bigint
-
-// MPI_LMP_TAGINT = MPI data type corresponding to tagint
-// MPI_LMP_BIGINT = MPI data type corresponding to bigint
+// MPI_LMP_TAGINT = MPI data type corresponding to a tagint
+// MPI_LMP_BIGINT = MPI data type corresponding to a bigint
 
 // NOTE: if your machine/MPI does not support "long long" ints,
-//       but only "long" ints, then you will need to set
-//       MPI_LONG_LONG to MPI_LONG and atoll to atol
+//       but only "long" ints, then you will need to change
+//       MPI_LONG_LONG to MPI_LONG, and atoll to atol
 
 #ifndef LMP_LMPTYPE_H
 #define LMP_LMPTYPE_H
 
-#include "limits.h"
 #define __STDC_LIMIT_MACROS
-#include "stdint.h"
 #define __STDC_FORMAT_MACROS
+
+#include "limits.h"
+#include "stdint.h"
 #include "inttypes.h"
 
 namespace LAMMPS_NS {
diff --git a/src/memory.cpp b/src/memory.cpp
index df8cff685d8ba524ccd3837f3116844b4cf09a64..b7e4c4dc4b85d1cb058fe4ae17ae8d2a1923ff73 100644
--- a/src/memory.cpp
+++ b/src/memory.cpp
@@ -11,12 +11,12 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "stdio.h"
 #include "stdlib.h"
 #include "string.h"
 #include "memory.h"
-#include "lmptype.h"
 #include "error.h"
 
 using namespace LAMMPS_NS;
diff --git a/src/min.cpp b/src/min.cpp
index 255bdfb605abb9c63144fe7458b603f651ffc225..b7c51cb48ac7263235e3f0a03af786ab138e867c 100644
--- a/src/min.cpp
+++ b/src/min.cpp
@@ -19,11 +19,11 @@
             JR Shewchuk, http://www-2.cs.cmu.edu/~jrs/jrspapers.html#cg
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "stdlib.h"
 #include "string.h"
 #include "min.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "domain.h"
 #include "comm.h"
diff --git a/src/min.h b/src/min.h
index 7b0990333212d489b6c2faaf17a0b158a337acfc..de0d596c3702e7e81a053c6ffcc0ece9fe5cf548 100644
--- a/src/min.h
+++ b/src/min.h
@@ -14,8 +14,8 @@
 #ifndef LMP_MIN_H
 #define LMP_MIN_H
 
-#include "pointers.h"
 #include "lmptype.h"
+#include "pointers.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/min_cg.cpp b/src/min_cg.cpp
index 9ad87904fb1fa60dc654ad16fd84dbc8c1732d3b..9ef3c8c4a702dd47bd77ac5f77f090d99d4d7186 100644
--- a/src/min_cg.cpp
+++ b/src/min_cg.cpp
@@ -11,11 +11,11 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "string.h"
 #include "min_cg.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "update.h"
 #include "output.h"
diff --git a/src/min_quickmin.cpp b/src/min_quickmin.cpp
index 6fb15b175c358d395e7e88eb4f134e617ae566cf..ec59fd20f85cd93143ee132fd24b4d9f459f09a5 100644
--- a/src/min_quickmin.cpp
+++ b/src/min_quickmin.cpp
@@ -11,10 +11,10 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "min_quickmin.h"
-#include "lmptype.h"
 #include "universe.h"
 #include "atom.h"
 #include "force.h"
diff --git a/src/modify.h b/src/modify.h
index f211167a111fef5e32266e0bf8055f19cfcc0718..56d94d63b99e54b4d297457010a8c60ef77c9008 100644
--- a/src/modify.h
+++ b/src/modify.h
@@ -14,9 +14,9 @@
 #ifndef LMP_MODIFY_H
 #define LMP_MODIFY_H
 
+#include "lmptype.h"
 #include "stdio.h"
 #include "pointers.h"
-#include "lmptype.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/neigh_bond.cpp b/src/neigh_bond.cpp
index e89c31cf37dd897a9319813637e2504e1f6cf13e..2ef6b89507dec96334989efae55568a5b746e3c9 100644
--- a/src/neigh_bond.cpp
+++ b/src/neigh_bond.cpp
@@ -11,8 +11,8 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
-#include "neighbor.h"
 #include "lmptype.h"
+#include "neighbor.h"
 #include "atom.h"
 #include "force.h"
 #include "update.h"
diff --git a/src/neighbor.cpp b/src/neighbor.cpp
index e97a11d64b6513ee9ade7ffd99d8adc96d6da9e7..7240fde4240e31bf79fd0ae834275aa282488304 100644
--- a/src/neighbor.cpp
+++ b/src/neighbor.cpp
@@ -15,12 +15,12 @@
    Contributing author (triclinic and multi-neigh) : Pieter in 't Veld (SNL)
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "stdlib.h"
 #include "string.h"
 #include "neighbor.h"
-#include "lmptype.h"
 #include "neigh_list.h"
 #include "neigh_request.h"
 #include "atom.h"
diff --git a/src/output.h b/src/output.h
index 9e0c72acbc86d95f897db62655b5cd94061448c8..d8ce61e529e4a9775a397406e8518ffbfe30f3c0 100644
--- a/src/output.h
+++ b/src/output.h
@@ -14,8 +14,8 @@
 #ifndef LMP_OUTPUT_H
 #define LMP_OUTPUT_H
 
-#include "pointers.h"
 #include "lmptype.h"
+#include "pointers.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/read_data.cpp b/src/read_data.cpp
index c1a3f010e5d311e61165e9553692d581db039132..50a5f347dbf9acd25babebfee08ceec5d74a8a4e 100644
--- a/src/read_data.cpp
+++ b/src/read_data.cpp
@@ -11,12 +11,12 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "math.h"
 #include "mpi.h"
 #include "string.h"
 #include "stdlib.h"
 #include "read_data.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "atom_vec.h"
 #include "comm.h"
diff --git a/src/read_restart.cpp b/src/read_restart.cpp
index 51b47830691b51ba1b28bfa9620b107480c47338..6c34cf896076ed534e1253267bfc11e9f579ec29 100644
--- a/src/read_restart.cpp
+++ b/src/read_restart.cpp
@@ -11,13 +11,13 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "string.h"
 #include "stdlib.h"
 #include "sys/types.h"
 #include "dirent.h"
 #include "read_restart.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "atom_vec.h"
 #include "domain.h"
diff --git a/src/read_restart.h b/src/read_restart.h
index d5364a144761c021800cda251f95f570a208bc75..16d2e675d51f296fe96f5b348996c356780cc527 100644
--- a/src/read_restart.h
+++ b/src/read_restart.h
@@ -20,9 +20,9 @@ CommandStyle(read_restart,ReadRestart)
 #ifndef LMP_READ_RESTART_H
 #define LMP_READ_RESTART_H
 
+#include "lmptype.h"
 #include "stdio.h"
 #include "pointers.h"
-#include "lmptype.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/region.h b/src/region.h
index c4a1e18a753618537425f9fa4af035c289ca86fd..e32d7ff1c7edfc886fa21b0353365d209dc409e3 100644
--- a/src/region.h
+++ b/src/region.h
@@ -14,8 +14,8 @@
 #ifndef LMP_REGION_H
 #define LMP_REGION_H
 
-#include "pointers.h"
 #include "lmptype.h"
+#include "pointers.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/replicate.cpp b/src/replicate.cpp
index d0a15af91866239eb1d269cb8aa79a140a32ff93..503f59c2672bb9dad00730a18c19456f242276f2 100644
--- a/src/replicate.cpp
+++ b/src/replicate.cpp
@@ -11,10 +11,10 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "string.h"
 #include "replicate.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "atom_vec.h"
 #include "atom_vec_hybrid.h"
diff --git a/src/run.cpp b/src/run.cpp
index e5a1b318ea63e4cce441aeb04307658be77619d6..7ed02bd2ba23408da1426013515eaafe49149ec1 100644
--- a/src/run.cpp
+++ b/src/run.cpp
@@ -11,10 +11,10 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "stdlib.h"
 #include "string.h"
 #include "run.h"
-#include "lmptype.h"
 #include "domain.h"
 #include "update.h"
 #include "integrate.h"
diff --git a/src/thermo.h b/src/thermo.h
index 8b954ebb893c1f839e03461816b5eae0048f48ff..0d000b0e12135cc4d246cc0544e7e1df70c23cc2 100644
--- a/src/thermo.h
+++ b/src/thermo.h
@@ -14,8 +14,8 @@
 #ifndef LMP_THERMO_H
 #define LMP_THERMO_H
 
-#include "pointers.h"
 #include "lmptype.h"
+#include "pointers.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/update.h b/src/update.h
index 75edc7e2fe43cb527379c19b2a6a8597c7a05b7d..b713c4c113d1aa635a2ee48db82991633226261e 100644
--- a/src/update.h
+++ b/src/update.h
@@ -14,8 +14,8 @@
 #ifndef LMP_UPDATE_H
 #define LMP_UPDATE_H
 
-#include "pointers.h"
 #include "lmptype.h"
+#include "pointers.h"
 
 namespace LAMMPS_NS {
 
diff --git a/src/velocity.cpp b/src/velocity.cpp
index 06032e64804862feac58969593495d079e350ca5..77545a86fc873b45f9ff3ce4cf92b9c0a9fab017 100644
--- a/src/velocity.cpp
+++ b/src/velocity.cpp
@@ -11,13 +11,13 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "math.h"
 #include "stdio.h"
 #include "stdlib.h"
 #include "string.h"
 #include "velocity.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "update.h"
 #include "domain.h"
diff --git a/src/write_restart.cpp b/src/write_restart.cpp
index 2f2f73a200fb0a925a7d640f4dc98acd62c94a2c..0b8bfac436d0f7e20ca8bfed0c388a04718a21b8 100644
--- a/src/write_restart.cpp
+++ b/src/write_restart.cpp
@@ -11,10 +11,10 @@
    See the README file in the top-level LAMMPS directory.
 ------------------------------------------------------------------------- */
 
+#include "lmptype.h"
 #include "mpi.h"
 #include "string.h"
 #include "write_restart.h"
-#include "lmptype.h"
 #include "atom.h"
 #include "atom_vec.h"
 #include "atom_vec_hybrid.h"
diff --git a/src/write_restart.h b/src/write_restart.h
index db729ec01047f4e55afe0c049f1e292a49f21eab..8a849e82568db85bb62e8923b8cc08e73525a1e4 100644
--- a/src/write_restart.h
+++ b/src/write_restart.h
@@ -20,9 +20,9 @@ CommandStyle(write_restart,WriteRestart)
 #ifndef LMP_WRITE_RESTART_H
 #define LMP_WRITE_RESTART_H
 
+#include "lmptype.h"
 #include "stdio.h"
 #include "pointers.h"
-#include "lmptype.h"
 
 namespace LAMMPS_NS {