Andrej van der Zee wrote:
> First of all, thanks for this release (candidate)! I
> expected more effort for upgrading my project to
> mysqlpp 3.0, but it was done without pain in a few
Thanks for the report.
> Where volume is the SSQLS struct:
> sql_create_complete_5(volume, 1, 5,
> mysqlpp::sql_bigint_unsigned, _volume_id,
> mysqlpp::sql_smallint_unsigned, _session_id,
> mysqlpp::Null<mysqlpp::sql_int_unsigned>, _msr_id,
> _report_id, "report_id",
> mysqlpp::sql_varchar, _name, "name"
I see you're already using new MySQL++ features. Or, were you using the
Waba Null<T>-for-SSQLS patch against v2.0?
> error: passing ‘const mysqlpp::null_type’ as ‘this’
> argument of ‘mysqlpp::null_type::operator Type() [with
> Type = unsigned int]’ discards qualifiers
> Note that the following construct works perfectly
> volume vol(volume_id, session_id, mysqlpp::null,
> report_id, name);
It's clear what it wants. You just have to declare null_type::operator
Type() as const. There's no reason for it to be any other way. Good
thing you caught it when you did, though: the fix breaks the ABI, so it
might not have been possible to fix it after release.