List:MySQL++« Previous MessageNext Message »
From:Warren Young Date:January 11 2010 4:14pm
Subject:Re: mysqlpp::ScopedConnection
View as plain text  
On 1/11/2010 5:51 AM, Jonathan Wakely wrote:
>
> There's no need to make the default constructor private. Declaring any
> other user-defined constructor disables the implicit generation of a
> default constructor.

True, but declaring it gives us a place to hang a comment saying why we 
did it that way.  It also tells anyone tempted to add one in the future 
why they shouldn't do that.

> Making it private means attempting to use it
> will give a "constructor is private" error rather than a "no such
> constructor" error.  Personally I think the latter is preferable so I
> would remove the declaration of the private default constructor.

This is reasonable, too.

So, how to resolve the tension?  Can we expect people to understand why 
something is non-existent and be content with that?  It seems to be 
human nature to invent all kinds of crazy things to fill in the places 
where non-existent things ought to be. >:)

The second patch is checked in now, with minor changes, so you all can 
make patches against head to support your arguments.
Thread
Query::execute crashes without a connected driverJoel Fielder7 Jan
  • Re: Query::execute crashes without a connected driverWarren Young7 Jan
    • Re: Query::execute crashes without a connected driverJoel Fielder8 Jan
    • mysqlpp::ScopedConnectionJoel Fielder8 Jan
      • Re: mysqlpp::ScopedConnectionWarren Young9 Jan
        • Re: mysqlpp::ScopedConnectionJonathan Wakely9 Jan
          • Re: mysqlpp::ScopedConnectionJoel Fielder11 Jan
            • Re: mysqlpp::ScopedConnectionJonathan Wakely11 Jan
              • Re: mysqlpp::ScopedConnectionWarren Young11 Jan
                • Re: mysqlpp::ScopedConnectionJonathan Wakely11 Jan
    • Re: Query::execute crashes without a connected driverJoel Fielder13 Jan
      • Re: Query::execute crashes without a connected driverWarren Young13 Jan
Re: mysqlpp::ScopedConnectionJoel Fielder11 Jan
  • Re: mysqlpp::ScopedConnectionWarren Young11 Jan
    • Re: mysqlpp::ScopedConnectionJoel Fielder11 Jan
      • Re: mysqlpp::ScopedConnectionWarren Young11 Jan
        • Re: mysqlpp::ScopedConnectionJoel Fielder12 Jan