mirror of
https://github.com/adamdruppe/arsd.git
synced 2025-04-27 22:00:13 +03:00
Range API needs size_t for .length.
This commit is contained in:
parent
61f0e5ed48
commit
47bacf0456
5 changed files with 6 additions and 6 deletions
|
@ -147,7 +147,7 @@ interface ResultSet {
|
||||||
bool empty() @property;
|
bool empty() @property;
|
||||||
Row front() @property;
|
Row front() @property;
|
||||||
void popFront() ;
|
void popFront() ;
|
||||||
int length() @property;
|
size_t length() @property;
|
||||||
|
|
||||||
/* deprecated */ final ResultSet byAssoc() { return this; }
|
/* deprecated */ final ResultSet byAssoc() { return this; }
|
||||||
}
|
}
|
||||||
|
|
2
mssql.d
2
mssql.d
|
@ -111,7 +111,7 @@ class MsSqlResult : ResultSet {
|
||||||
fetchNext;
|
fetchNext;
|
||||||
}
|
}
|
||||||
|
|
||||||
int length()
|
override size_t length()
|
||||||
{
|
{
|
||||||
return 1; //FIX ME
|
return 1; //FIX ME
|
||||||
}
|
}
|
||||||
|
|
2
mysql.d
2
mysql.d
|
@ -72,7 +72,7 @@ class MySqlResult : ResultSet {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
override int length() {
|
override size_t length() {
|
||||||
if(result is null)
|
if(result is null)
|
||||||
return 0;
|
return 0;
|
||||||
return cast(int) mysql_num_rows(result);
|
return cast(int) mysql_num_rows(result);
|
||||||
|
|
|
@ -126,7 +126,7 @@ class PostgresResult : ResultSet {
|
||||||
fetchNext();
|
fetchNext();
|
||||||
}
|
}
|
||||||
|
|
||||||
int length() {
|
override size_t length() {
|
||||||
return numRows;
|
return numRows;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
4
sqlite.d
4
sqlite.d
|
@ -227,8 +227,8 @@ class SqliteResult : ResultSet {
|
||||||
position++;
|
position++;
|
||||||
}
|
}
|
||||||
|
|
||||||
int length() {
|
override size_t length() {
|
||||||
return cast(int) rows.length;
|
return rows.length;
|
||||||
}
|
}
|
||||||
|
|
||||||
this(Variant[][] rows, char[][] columnNames) {
|
this(Variant[][] rows, char[][] columnNames) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue