deprecations on new dmd

This commit is contained in:
Adam D. Ruppe 2018-10-06 12:19:19 -04:00
parent ef5f86f8ca
commit 6508cbad3a
1 changed files with 3 additions and 3 deletions

View File

@ -197,10 +197,10 @@ class MySqlResult : ResultSet {
+/ +/
class MySql : Database { class MySql : Database {
this(string host, string user, string pass, string db, uint port = 0) { this(string host, string user, string pass, string db, uint port = 0) {
mysql = enforceEx!(DatabaseException)( mysql = enforce!(DatabaseException)(
mysql_init(null), mysql_init(null),
"Couldn't init mysql"); "Couldn't init mysql");
enforceEx!(DatabaseException)( enforce!(DatabaseException)(
mysql_real_connect(mysql, toCstring(host), toCstring(user), toCstring(pass), toCstring(db), port, null, 0), mysql_real_connect(mysql, toCstring(host), toCstring(user), toCstring(pass), toCstring(db), port, null, 0),
error()); error());
@ -371,7 +371,7 @@ class MySql : Database {
override ResultSet queryImpl(string sql, Variant[] args...) { override ResultSet queryImpl(string sql, Variant[] args...) {
sql = escapedVariants(this, sql, args); sql = escapedVariants(this, sql, args);
enforceEx!(DatabaseException)( enforce!(DatabaseException)(
!mysql_query(mysql, toCstring(sql)), !mysql_query(mysql, toCstring(sql)),
error() ~ " :::: " ~ sql); error() ~ " :::: " ~ sql);