From 0e6355329f241a3e3c8b38cb4146fda4470e6ed0 Mon Sep 17 00:00:00 2001 From: Kelly Rauchenberger Date: Mon, 26 Mar 2018 15:33:06 -0400 Subject: Whitespace changes --- generator/database.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'generator/database.cpp') diff --git a/generator/database.cpp b/generator/database.cpp index f326f46..b46a0d1 100644 --- a/generator/database.cpp +++ b/generator/database.cpp @@ -73,19 +73,19 @@ namespace cadence { { sqlite3_close_v2(ppdb_); } - + void database::runQuery(std::string query) { // This can only happen when doing bad things with move semantics. assert(ppdb_ != nullptr); - + sqlite3_stmt* ppstmt; if (sqlite3_prepare_v2(ppdb_, query.c_str(), query.length(), &ppstmt, NULL) != SQLITE_OK) { throw sqlite3_error("Error writing to database", sqlite3_errmsg(ppdb_)); } - + int result = sqlite3_step(ppstmt); sqlite3_finalize(ppstmt); @@ -99,10 +99,10 @@ namespace cadence { { // This can only happen when doing bad things with move semantics. assert(ppdb_ != nullptr); - + // This shouldn't happen. assert(!fields.empty()); - + std::list fieldNames; std::list qs; for (field& f : fields) @@ -110,7 +110,7 @@ namespace cadence { fieldNames.push_back(f.getName()); qs.push_back("?"); } - + std::ostringstream query; query << "INSERT INTO "; query << table; @@ -119,7 +119,7 @@ namespace cadence { query << ") VALUES ("; query << implode(std::begin(qs), std::end(qs), ", "); query << ")"; - + std::string query_str = query.str(); sqlite3_stmt* ppstmt; -- cgit 1.4.1