aboutsummaryrefslogtreecommitdiff
path: root/odb/generator.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2017-11-07 10:37:53 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2017-11-07 10:37:53 +0200
commit6e374de9ae2f2978f2fca3390aba4ea3f72bfade (patch)
treea603c240f79494e0139445c20f63f32db04d5277 /odb/generator.cxx
parentfde4431ec608b467de6ab205e3f73848fe9efbdf (diff)
Switch to C++11, get rid of auto_ptr use
Diffstat (limited to 'odb/generator.cxx')
-rw-r--r--odb/generator.cxx18
1 files changed, 9 insertions, 9 deletions
diff --git a/odb/generator.cxx b/odb/generator.cxx
index 74de7d1..bb8e12f 100644
--- a/odb/generator.cxx
+++ b/odb/generator.cxx
@@ -4,7 +4,7 @@
#include <cctype> // std::toupper, std::is{alpha,upper,lower}
#include <string>
-#include <memory> // std::auto_ptr
+#include <memory> // std::unique_ptr
#include <iomanip>
#include <fstream>
#include <sstream>
@@ -166,7 +166,7 @@ generate (options const& ops,
if (gen_schema)
{
- auto_ptr<context> ctx (create_context (cerr, unit, ops, fts, 0));
+ unique_ptr<context> ctx (create_context (cerr, unit, ops, fts, 0));
switch (db)
{
@@ -496,7 +496,7 @@ generate (options const& ops,
//
if (gen_cxx)
{
- auto_ptr<context> ctx (
+ unique_ptr<context> ctx (
create_context (hxx, unit, ops, fts, model.get ()));
sloc_filter sloc (ctx->os);
@@ -606,7 +606,7 @@ generate (options const& ops,
//
if (gen_cxx)
{
- auto_ptr<context> ctx (
+ unique_ptr<context> ctx (
create_context (ixx, unit, ops, fts, model.get ()));
sloc_filter sloc (ctx->os);
@@ -666,7 +666,7 @@ generate (options const& ops,
//
if (gen_cxx && (db != database::common || md == multi_database::dynamic))
{
- auto_ptr<context> ctx (
+ unique_ptr<context> ctx (
create_context (cxx, unit, ops, fts, model.get ()));
sloc_filter sloc (ctx->os);
@@ -759,7 +759,7 @@ generate (options const& ops,
//
if (gen_sep_schema)
{
- auto_ptr<context> ctx (
+ unique_ptr<context> ctx (
create_context (sch, unit, ops, fts, model.get ()));
sloc_filter sloc (ctx->os);
@@ -824,7 +824,7 @@ generate (options const& ops,
//
if (gen_sql_schema)
{
- auto_ptr<context> ctx (
+ unique_ptr<context> ctx (
create_context (sql, unit, ops, fts, model.get ()));
switch (db)
@@ -890,7 +890,7 @@ generate (options const& ops,
//
{
ofstream& mig (*mig_pre[i]);
- auto_ptr<context> ctx (create_context (mig, unit, ops, fts, 0));
+ unique_ptr<context> ctx (create_context (mig, unit, ops, fts, 0));
switch (db)
{
@@ -933,7 +933,7 @@ generate (options const& ops,
//
{
ofstream& mig (*mig_post[i]);
- auto_ptr<context> ctx (create_context (mig, unit, ops, fts, 0));
+ unique_ptr<context> ctx (create_context (mig, unit, ops, fts, 0));
switch (db)
{