Fixed a bunch of missing initializations

This commit is contained in:
rbock
2015-12-27 22:25:05 +01:00
parent 0957775202
commit b89e4c3e4f
26 changed files with 57 additions and 57 deletions

View File

@@ -29,10 +29,10 @@
int insert(int, char**)
{
MockDb db;
MockDb db{};
test::TabPerson p;
test::TabFeature f;
const auto p = test::TabPerson{};
const auto f = test::TabFeature{};
db(insert_into(f).set(f.name = "loves c++", f.fatal = false));

View File

@@ -65,9 +65,9 @@ SQLPP_DECLARE_TABLE(
int ppgen(int, char**)
{
MockDb db;
tab_person::tab_person p;
tab_feature::tab_feature f;
MockDb db{};
const auto p = tab_person::tab_person{};
const auto f = tab_feature::tab_feature{};
db(insert_into(f).set(f.name = "loves c++", f.fatal = false));

View File

@@ -29,10 +29,10 @@
int remove(int, char**)
{
MockDb db;
MockDb db{};
test::TabPerson p;
test::TabFeature q;
const auto p = test::TabPerson{};
const auto q = test::TabFeature{};
db(remove_from(p).using_(p, q).where(p.feature == q.id and q.fatal == true));
return 0;

View File

@@ -29,10 +29,10 @@
int main()
{
MockDb db;
MockDb db{};
test::TabPerson p;
test::TabFeature f;
const auto p = test::TabPerson{};
const auto f = test::TabFeature{};
db(insert_into(f).set(f.name = "Loves C++", p.fatal = false));

View File

@@ -41,10 +41,12 @@ int select(int, char**)
static constexpr bool some_condition = true;
static constexpr bool some_other_condition = false;
MockDb db;
MockDb db{};
test::TabPerson p;
test::TabFeature f;
const auto p = test::TabPerson{};
#if 0
const auto f = test::TabFeature{};
#endif
for (const auto& row : db(select(all_of(p)).from(p).where(p.id > 7)))
{

View File

@@ -29,10 +29,9 @@
int update(int, char**)
{
MockDb db;
MockDb db{};
test::TabPerson p;
// test::TabFeature q;
const auto p = test::TabPerson{};
db(update(p).set(p.feature = 7).where(p.id == 23));
return 0;