From 6f6e3b37cf49ab6c832511eb1d7510dc27cfa08d Mon Sep 17 00:00:00 2001
From: Elias Pipping <elias.pipping@fu-berlin.de>
Date: Thu, 29 Aug 2013 22:59:13 +0200
Subject: [PATCH] [Cleanup] Move declarations

---
 src/one-body-sample.cc | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/src/one-body-sample.cc b/src/one-body-sample.cc
index 4d28c36d..d97fcce4 100644
--- a/src/one-body-sample.cc
+++ b/src/one-body-sample.cc
@@ -490,9 +490,6 @@ int main(int argc, char *argv[]) {
       if (printProgress)
         (std::cout << boost::format("%7d ") % run << " ").flush();
 
-      VectorType u;
-      double lastCorrection;
-
       stateUpdater->nextTimeStep();
       timeSteppingScheme->nextTimeStep();
 
@@ -532,7 +529,9 @@ int main(int argc, char *argv[]) {
       // Since the velocity explodes in the quasistatic case, use the
       // displacement as a convergence criterion
       // Q: is this reasonable?
+      VectorType u;
       VectorType u_saved;
+      double lastCorrection;
       for (size_t state_fpi = 1; state_fpi <= state_fpi_max; ++state_fpi) {
         stateUpdater->solve(v);
         {
-- 
GitLab