Permalink
Browse files

Rename hasMore() to valid() as discussed. (Part II)

  • Loading branch information...
1 parent b6b7c9e commit 6b0f57ee5022fd3062c594cd145da363dc723590 Marcus Boerger committed Mar 8, 2004
View
2 Zend/zend_execute.c
@@ -3756,7 +3756,7 @@ int zend_fe_fetch_handler(ZEND_OPCODE_HANDLER_ARGS)
* In case that ever happens we need an additional flag. */
iter->funcs->move_forward(iter TSRMLS_CC);
}
- if (!iter || iter->funcs->has_more(iter TSRMLS_CC) == FAILURE) {
+ if (!iter || iter->funcs->valid(iter TSRMLS_CC) == FAILURE) {
/* reached end of iteration */
SET_OPCODE(op_array->opcodes+opline->op2.u.opline_num);
return 0; /* CHECK_ME */
View
10 Zend/zend_interfaces.c
@@ -134,16 +134,16 @@ static void zend_user_it_dtor(zend_object_iterator *_iter TSRMLS_DC)
}
/* }}} */
-/* {{{ zend_user_it_has_more */
-static int zend_user_it_has_more(zend_object_iterator *_iter TSRMLS_DC)
+/* {{{ zend_user_it_valid */
+static int zend_user_it_valid(zend_object_iterator *_iter TSRMLS_DC)
{
if (_iter) {
zend_user_iterator *iter = (zend_user_iterator*)_iter;
zval *object = (zval*)iter->it.data;
zval *more;
int result;
- zend_call_method_with_0_params(&object, iter->ce, &iter->ce->iterator_funcs.zf_has_more, "valid", &more);
+ zend_call_method_with_0_params(&object, iter->ce, &iter->ce->iterator_funcs.zf_valid, "valid", &more);
if (more) {
result = i_zend_is_true(more);
zval_ptr_dtor(&more);
@@ -245,7 +245,7 @@ static void zend_user_it_rewind(zend_object_iterator *_iter TSRMLS_DC)
zend_object_iterator_funcs zend_interface_iterator_funcs_iterator = {
zend_user_it_dtor,
- zend_user_it_has_more,
+ zend_user_it_valid,
zend_user_it_get_current_data,
zend_user_it_get_current_key,
zend_user_it_move_forward,
@@ -339,7 +339,7 @@ static int zend_implement_iterator(zend_class_entry *interface, zend_class_entry
}
}
class_type->get_iterator = zend_user_it_get_iterator;
- class_type->iterator_funcs.zf_has_more = NULL;
+ class_type->iterator_funcs.zf_valid = NULL;
class_type->iterator_funcs.zf_current = NULL;
class_type->iterator_funcs.zf_key = NULL;
class_type->iterator_funcs.zf_next = NULL;
View
6 Zend/zend_iterators.h
@@ -32,8 +32,8 @@ typedef struct _zend_object_iterator_funcs {
/* release all resources associated with this iterator instance */
void (*dtor)(zend_object_iterator *iter TSRMLS_DC);
- /* check for end of iteration (FAILURE or SUCCESS for more data) */
- int (*has_more)(zend_object_iterator *iter TSRMLS_DC);
+ /* check for end of iteration (FAILURE or SUCCESS if data is valid) */
+ int (*valid)(zend_object_iterator *iter TSRMLS_DC);
/* fetch the item data for the current element */
void (*get_current_data)(zend_object_iterator *iter, zval ***data TSRMLS_DC);
@@ -60,7 +60,7 @@ typedef struct _zend_class_iterator_funcs {
zend_object_iterator_funcs *funcs;
zend_object_new_iterator_t new_iterator;
union _zend_function *zf_new_iterator;
- union _zend_function *zf_has_more;
+ union _zend_function *zf_valid;
union _zend_function *zf_current;
union _zend_function *zf_key;
union _zend_function *zf_next;
View
6 ext/simplexml/simplexml.c
@@ -1294,15 +1294,15 @@ typedef struct {
} php_sxe_iterator;
static void php_sxe_iterator_dtor(zend_object_iterator *iter TSRMLS_DC);
-static int php_sxe_iterator_has_more(zend_object_iterator *iter TSRMLS_DC);
+static int php_sxe_iterator_valid(zend_object_iterator *iter TSRMLS_DC);
static void php_sxe_iterator_current_data(zend_object_iterator *iter, zval ***data TSRMLS_DC);
static int php_sxe_iterator_current_key(zend_object_iterator *iter, char **str_key, uint *str_key_len, ulong *int_key TSRMLS_DC);
static void php_sxe_iterator_move_forward(zend_object_iterator *iter TSRMLS_DC);
static void php_sxe_iterator_rewind(zend_object_iterator *iter TSRMLS_DC);
zend_object_iterator_funcs php_sxe_iterator_funcs = {
php_sxe_iterator_dtor,
- php_sxe_iterator_has_more,
+ php_sxe_iterator_valid,
php_sxe_iterator_current_data,
php_sxe_iterator_current_key,
php_sxe_iterator_move_forward,
@@ -1388,7 +1388,7 @@ static void php_sxe_iterator_dtor(zend_object_iterator *iter TSRMLS_DC)
efree(iterator);
}
-static int php_sxe_iterator_has_more(zend_object_iterator *iter TSRMLS_DC)
+static int php_sxe_iterator_valid(zend_object_iterator *iter TSRMLS_DC)
{
php_sxe_iterator *iterator = (php_sxe_iterator *)iter;
View
10 ext/spl/spl_directory.c
@@ -506,7 +506,7 @@ typedef struct {
/* forward declarations to the iterator handlers */
static void spl_ce_dir_it_dtor(zend_object_iterator *iter TSRMLS_DC);
-static int spl_ce_dir_it_has_more(zend_object_iterator *iter TSRMLS_DC);
+static int spl_ce_dir_it_valid(zend_object_iterator *iter TSRMLS_DC);
static void spl_ce_dir_it_current_data(zend_object_iterator *iter, zval ***data TSRMLS_DC);
static int spl_ce_dir_it_current_key(zend_object_iterator *iter, char **str_key, uint *str_key_len, ulong *int_key TSRMLS_DC);
static void spl_ce_dir_it_move_forward(zend_object_iterator *iter TSRMLS_DC);
@@ -516,7 +516,7 @@ static void spl_ce_dir_it_rewind(zend_object_iterator *iter TSRMLS_DC);
/* iterator handler table */
zend_object_iterator_funcs spl_ce_dir_it_funcs = {
spl_ce_dir_it_dtor,
- spl_ce_dir_it_has_more,
+ spl_ce_dir_it_valid,
spl_ce_dir_it_current_data,
spl_ce_dir_it_current_key,
spl_ce_dir_it_move_forward,
@@ -555,8 +555,8 @@ static void spl_ce_dir_it_dtor(zend_object_iterator *iter TSRMLS_DC)
/* }}} */
-/* {{{ spl_ce_dir_it_has_more */
-static int spl_ce_dir_it_has_more(zend_object_iterator *iter TSRMLS_DC)
+/* {{{ spl_ce_dir_it_valid */
+static int spl_ce_dir_it_valid(zend_object_iterator *iter TSRMLS_DC)
{
spl_ce_dir_it *iterator = (spl_ce_dir_it *)iter;
spl_ce_dir_object *object = iterator->object;
@@ -677,7 +677,7 @@ static void spl_ce_dir_tree_it_rewind(zend_object_iterator *iter TSRMLS_DC)
/* iterator handler table */
zend_object_iterator_funcs spl_ce_dir_tree_it_funcs = {
spl_ce_dir_it_dtor,
- spl_ce_dir_it_has_more,
+ spl_ce_dir_it_valid,
spl_ce_dir_it_current_data,
spl_ce_dir_tree_it_current_key,
spl_ce_dir_tree_it_move_forward,
View
46 ext/spl/spl_iterators.c
@@ -137,26 +137,26 @@ static void spl_recursive_it_dtor(zend_object_iterator *_iter TSRMLS_DC)
efree(iter);
}
-static int spl_recursive_it_has_more_ex(spl_recursive_it_object *object TSRMLS_DC)
+static int spl_recursive_it_valid_ex(spl_recursive_it_object *object TSRMLS_DC)
{
zend_object_iterator *sub_iter;
int level = object->level;
while (level >=0) {
sub_iter = object->iterators[level].iterator;
- if (sub_iter->funcs->has_more(sub_iter TSRMLS_CC) == SUCCESS) {
+ if (sub_iter->funcs->valid(sub_iter TSRMLS_CC) == SUCCESS) {
return SUCCESS;
}
level--;
}
return FAILURE;
}
-static int spl_recursive_it_has_more(zend_object_iterator *iter TSRMLS_DC)
+static int spl_recursive_it_valid(zend_object_iterator *iter TSRMLS_DC)
{
spl_recursive_it_object *object = (spl_recursive_it_object*)iter->data;
- return spl_recursive_it_has_more_ex(object TSRMLS_CC);
+ return spl_recursive_it_valid_ex(object TSRMLS_CC);
}
static void spl_recursive_it_get_current_data(zend_object_iterator *iter, zval ***data TSRMLS_DC)
@@ -195,7 +195,7 @@ static void spl_recursive_it_move_forward_ex(spl_recursive_it_object *object TSR
case RS_NEXT:
iterator->funcs->move_forward(iterator TSRMLS_CC);
case RS_START:
- if (iterator->funcs->has_more(iterator TSRMLS_CC) == FAILURE) {
+ if (iterator->funcs->valid(iterator TSRMLS_CC) == FAILURE) {
break;
}
object->iterators[object->level].state = RS_TEST;
@@ -305,7 +305,7 @@ static zend_object_iterator *spl_recursive_it_get_iterator(zend_class_entry *ce,
zend_object_iterator_funcs spl_recursive_it_iterator_funcs = {
spl_recursive_it_dtor,
- spl_recursive_it_has_more,
+ spl_recursive_it_valid,
spl_recursive_it_get_current_data,
spl_recursive_it_get_current_key,
spl_recursive_it_move_forward,
@@ -352,7 +352,7 @@ SPL_METHOD(RecursiveIteratorIterator, valid)
{
spl_recursive_it_object *object = (spl_recursive_it_object*)zend_object_store_get_object(getThis() TSRMLS_CC);
- RETURN_BOOL(spl_recursive_it_has_more_ex(object TSRMLS_CC) == SUCCESS);
+ RETURN_BOOL(spl_recursive_it_valid_ex(object TSRMLS_CC) == SUCCESS);
}
SPL_METHOD(RecursiveIteratorIterator, key)
@@ -458,7 +458,7 @@ static zend_object_value spl_RecursiveIteratorIterator_new(zend_class_entry *cla
#if MBO_0
static int spl_dual_it_gets_implemented(zend_class_entry *interface, zend_class_entry *class_type TSRMLS_DC)
{
- class_type->iterator_funcs.zf_has_more = NULL;
+ class_type->iterator_funcs.zf_valid = NULL;
class_type->iterator_funcs.zf_current = NULL;
class_type->iterator_funcs.zf_key = NULL;
class_type->iterator_funcs.zf_next = NULL;
@@ -626,18 +626,18 @@ static INLINE void spl_dual_it_rewind(spl_dual_it_object *intern TSRMLS_DC)
}
}
-static INLINE int spl_dual_it_has_more(spl_dual_it_object *intern TSRMLS_DC)
+static INLINE int spl_dual_it_valid(spl_dual_it_object *intern TSRMLS_DC)
{
/* FAILURE / SUCCESS */
- return intern->inner.iterator->funcs->has_more(intern->inner.iterator TSRMLS_CC);
+ return intern->inner.iterator->funcs->valid(intern->inner.iterator TSRMLS_CC);
}
static INLINE int spl_dual_it_fetch(spl_dual_it_object *intern, int check_more TSRMLS_DC)
{
zval **data;
spl_dual_it_free(intern TSRMLS_CC);
- if (!check_more || spl_dual_it_has_more(intern TSRMLS_CC) == SUCCESS) {
+ if (!check_more || spl_dual_it_valid(intern TSRMLS_CC) == SUCCESS) {
intern->inner.iterator->funcs->get_current_data(intern->inner.iterator, &data TSRMLS_CC);
intern->current.data = *data;
intern->current.data->refcount++;
@@ -863,13 +863,13 @@ static zend_function_entry spl_funcs_ParentIterator[] = {
{NULL, NULL, NULL}
};
-static INLINE int spl_limit_it_has_more(spl_dual_it_object *intern TSRMLS_DC)
+static INLINE int spl_limit_it_valid(spl_dual_it_object *intern TSRMLS_DC)
{
/* FAILURE / SUCCESS */
if (intern->u.limit.count != -1 && intern->current.pos >= intern->u.limit.offset + intern->u.limit.count) {
return FAILURE;
} else {
- return spl_dual_it_has_more(intern TSRMLS_CC);
+ return spl_dual_it_valid(intern TSRMLS_CC);
}
}
@@ -894,7 +894,7 @@ static INLINE void spl_limit_it_seek(spl_dual_it_object *intern, long pos TSRMLS
spl_dual_it_free(intern TSRMLS_CC);
zend_user_it_free_current(intern->inner.iterator TSRMLS_CC);
intern->current.pos = pos;
- if (spl_limit_it_has_more(intern TSRMLS_CC) == SUCCESS) {
+ if (spl_limit_it_valid(intern TSRMLS_CC) == SUCCESS) {
spl_dual_it_fetch(intern, 0 TSRMLS_CC);
}
} else {
@@ -903,10 +903,10 @@ static INLINE void spl_limit_it_seek(spl_dual_it_object *intern, long pos TSRMLS
if (pos < intern->current.pos) {
spl_dual_it_rewind(intern TSRMLS_CC);
}
- while (pos > intern->current.pos && spl_dual_it_has_more(intern TSRMLS_CC) == SUCCESS) {
+ while (pos > intern->current.pos && spl_dual_it_valid(intern TSRMLS_CC) == SUCCESS) {
spl_dual_it_next(intern, 1 TSRMLS_CC);
}
- if (spl_dual_it_has_more(intern TSRMLS_CC) == SUCCESS) {
+ if (spl_dual_it_valid(intern TSRMLS_CC) == SUCCESS) {
spl_dual_it_fetch(intern, 1 TSRMLS_CC);
}
}
@@ -932,7 +932,7 @@ SPL_METHOD(LimitIterator, valid)
intern = (spl_dual_it_object*)zend_object_store_get_object(getThis() TSRMLS_CC);
-/* RETURN_BOOL(spl_limit_it_has_more(intern TSRMLS_CC) == SUCCESS);*/
+/* RETURN_BOOL(spl_limit_it_valid(intern TSRMLS_CC) == SUCCESS);*/
RETURN_BOOL((intern->u.limit.count == -1 || intern->current.pos < intern->u.limit.offset + intern->u.limit.count) && intern->current.data);
}
@@ -1003,20 +1003,20 @@ static zend_function_entry spl_funcs_LimitIterator[] = {
{NULL, NULL, NULL}
};
-static INLINE int spl_caching_it_has_more(spl_dual_it_object *intern TSRMLS_DC)
+static INLINE int spl_caching_it_valid(spl_dual_it_object *intern TSRMLS_DC)
{
- return intern->u.caching.flags & CIT_HAS_MORE ? SUCCESS : FAILURE;
+ return intern->u.caching.flags & CIT_VALID ? SUCCESS : FAILURE;
}
static INLINE int spl_caching_it_has_next(spl_dual_it_object *intern TSRMLS_DC)
{
- return spl_dual_it_has_more(intern TSRMLS_CC);
+ return spl_dual_it_valid(intern TSRMLS_CC);
}
static INLINE void spl_caching_it_next(spl_dual_it_object *intern TSRMLS_DC)
{
if (spl_dual_it_fetch(intern, 1 TSRMLS_CC) == SUCCESS) {
- intern->u.caching.flags |= CIT_HAS_MORE;
+ intern->u.caching.flags |= CIT_VALID;
if (intern->dit_type == DIT_CachingRecursiveIterator) {
zval *retval, *zchildren, zflags;
zend_call_method_with_0_params(&intern->inner.zobject, intern->inner.ce, NULL, "haschildren", &retval);
@@ -1051,7 +1051,7 @@ static INLINE void spl_caching_it_next(spl_dual_it_object *intern TSRMLS_DC)
}
spl_dual_it_next(intern, 0 TSRMLS_CC);
} else {
- intern->u.caching.flags &= ~CIT_HAS_MORE;
+ intern->u.caching.flags &= ~CIT_VALID;
}
}
@@ -1081,7 +1081,7 @@ SPL_METHOD(CachingIterator, valid)
intern = (spl_dual_it_object*)zend_object_store_get_object(getThis() TSRMLS_CC);
- RETURN_BOOL(spl_caching_it_has_more(intern TSRMLS_CC) == SUCCESS);
+ RETURN_BOOL(spl_caching_it_valid(intern TSRMLS_CC) == SUCCESS);
}
SPL_METHOD(CachingIterator, next)
View
4 ext/spl/spl_iterators.h
@@ -48,7 +48,7 @@ enum {
CIT_CATCH_GET_CHILD = 2,
CIT_PUBLIC = CIT_CALL_TOSTRING|CIT_CATCH_GET_CHILD,
/* private */
- CIT_HAS_MORE = 4,
+ CIT_VALID = 4,
CIT_HAS_CHILDREN = 8
};
@@ -75,7 +75,7 @@ typedef struct _spl_dual_it_object {
long count;
} limit;
struct {
- int flags; /* CIT_HAS_MORE, CIT_CALL_TOSTRING, CIT_CATCH_GET_CHILD */
+ int flags; /* CIT_VALID, CIT_CALL_TOSTRING, CIT_CATCH_GET_CHILD */
zval *zstr;
zval *zchildren;
} caching;
View
2 ext/sqlite/php_sqlite.h
@@ -65,7 +65,7 @@ PHP_FUNCTION(sqlite_rewind);
PHP_FUNCTION(sqlite_next);
PHP_FUNCTION(sqlite_prev);
-PHP_FUNCTION(sqlite_has_more);
+PHP_FUNCTION(sqlite_valid);
PHP_FUNCTION(sqlite_has_prev);
PHP_FUNCTION(sqlite_libversion);
View
17 ext/sqlite/sqlite.c
@@ -171,7 +171,8 @@ function_entry sqlite_functions[] = {
PHP_FE(sqlite_rewind, NULL)
PHP_FE(sqlite_next, NULL)
PHP_FE(sqlite_prev, NULL)
- PHP_FE(sqlite_has_more, NULL)
+ PHP_FE(sqlite_valid, NULL)
+ PHP_FALIAS(sqlite_has_more, sqlite_valid, NULL)
PHP_FE(sqlite_has_prev, NULL)
PHP_FE(sqlite_escape_string, NULL)
PHP_FE(sqlite_busy_timeout, NULL)
@@ -217,7 +218,7 @@ function_entry sqlite_funcs_query[] = {
/* spl_forward */
PHP_ME_MAPPING(current, sqlite_current, NULL)
PHP_ME_MAPPING(next, sqlite_next, NULL)
- PHP_ME_MAPPING(valid, sqlite_has_more, NULL)
+ PHP_ME_MAPPING(valid, sqlite_valid, NULL)
/* spl_sequence */
PHP_ME_MAPPING(rewind, sqlite_rewind, NULL)
/* additional */
@@ -239,7 +240,7 @@ function_entry sqlite_funcs_ub_query[] = {
/* spl_forward */
PHP_ME_MAPPING(current, sqlite_current, NULL)
PHP_ME_MAPPING(next, sqlite_next, NULL)
- PHP_ME_MAPPING(valid, sqlite_has_more, NULL)
+ PHP_ME_MAPPING(valid, sqlite_valid, NULL)
{NULL, NULL, NULL}
};
@@ -888,7 +889,7 @@ void sqlite_iterator_rewind(zend_object_iterator *iter TSRMLS_DC)
}
}
-int sqlite_iterator_has_more(zend_object_iterator *iter TSRMLS_DC)
+int sqlite_iterator_valid(zend_object_iterator *iter TSRMLS_DC)
{
struct php_sqlite_result *res = ((sqlite_object_iterator*)iter)->res;
@@ -944,7 +945,7 @@ void sqlite_iterator_move_forward(zend_object_iterator *iter TSRMLS_DC)
zend_object_iterator_funcs sqlite_ub_query_iterator_funcs = {
sqlite_iterator_dtor,
- sqlite_iterator_has_more,
+ sqlite_iterator_valid,
sqlite_iterator_get_current_data,
sqlite_iterator_get_current_key,
sqlite_iterator_move_forward,
@@ -953,7 +954,7 @@ zend_object_iterator_funcs sqlite_ub_query_iterator_funcs = {
zend_object_iterator_funcs sqlite_query_iterator_funcs = {
sqlite_iterator_dtor,
- sqlite_iterator_has_more,
+ sqlite_iterator_valid,
sqlite_iterator_get_current_data,
sqlite_iterator_get_current_key,
sqlite_iterator_move_forward,
@@ -2346,9 +2347,9 @@ PHP_FUNCTION(sqlite_num_rows)
}
/* }}} */
-/* {{{ proto bool sqlite_has_more(resource result)
+/* {{{ proto bool sqlite_valid(resource result)
Returns whether more rows are available. */
-PHP_FUNCTION(sqlite_has_more)
+PHP_FUNCTION(sqlite_valid)
{
zval *zres;
struct php_sqlite_result *res;
View
6 ext/sqlite/tests/sqlite_010.phpt
@@ -22,17 +22,17 @@ foreach ($data as $str) {
}
$r = sqlite_unbuffered_query("SELECT a from strings", $db);
-while (sqlite_has_more($r)) {
+while (sqlite_valid($r)) {
var_dump(sqlite_current($r, SQLITE_NUM));
sqlite_next($r);
}
$r = sqlite_query("SELECT a from strings", $db);
-while (sqlite_has_more($r)) {
+while (sqlite_valid($r)) {
var_dump(sqlite_current($r, SQLITE_NUM));
sqlite_next($r);
}
sqlite_rewind($r);
-while (sqlite_has_more($r)) {
+while (sqlite_valid($r)) {
var_dump(sqlite_current($r, SQLITE_NUM));
sqlite_next($r);
}
View
4 ext/sqlite/tests/sqlite_013.phpt
@@ -22,7 +22,7 @@ foreach ($data as $str) {
echo "====BUFFERED====\n";
$r = sqlite_query("SELECT a, b from strings", $db);
-while (sqlite_has_more($r)) {
+while (sqlite_valid($r)) {
var_dump(sqlite_current($r, SQLITE_NUM));
var_dump(sqlite_column($r, 0));
var_dump(sqlite_column($r, 1));
@@ -32,7 +32,7 @@ while (sqlite_has_more($r)) {
}
echo "====UNBUFFERED====\n";
$r = sqlite_unbuffered_query("SELECT a, b from strings", $db);
-while (sqlite_has_more($r)) {
+while (sqlite_valid($r)) {
var_dump(sqlite_column($r, 0));
var_dump(sqlite_column($r, 'b'));
var_dump(sqlite_column($r, 1));
View
4 ext/sqlite/tests/sqlite_016.phpt
@@ -22,12 +22,12 @@ foreach ($data as $str) {
echo "====BUFFERED====\n";
$r = sqlite_query("SELECT a, b from strings", $db);
-while (sqlite_has_more($r)) {
+while (sqlite_valid($r)) {
var_dump(sqlite_fetch_single($r));
}
echo "====UNBUFFERED====\n";
$r = sqlite_unbuffered_query("SELECT a, b from strings", $db);
-while (sqlite_has_more($r)) {
+while (sqlite_valid($r)) {
var_dump(sqlite_fetch_single($r));
}
View
4 ext/sqlite/tests/sqlite_023.phpt
@@ -24,7 +24,7 @@ foreach ($data as $str) {
$r = sqlite_query("SELECT a FROM strings", $db, SQLITE_NUM);
echo "====TRAVERSE====\n";
-for(sqlite_rewind($r); sqlite_has_more($r); sqlite_next($r)) {
+for(sqlite_rewind($r); sqlite_valid($r); sqlite_next($r)) {
var_dump(sqlite_current($r));
}
@@ -39,7 +39,7 @@ echo "====UNBUFFERED====\n";
$r = sqlite_unbuffered_query("SELECT a FROM strings", $db, SQLITE_NUM);
echo "====TRAVERSE====\n";
-for(sqlite_rewind($r); sqlite_has_more($r); sqlite_next($r)) {
+for(sqlite_rewind($r); sqlite_valid($r); sqlite_next($r)) {
var_dump(sqlite_current($r));
}
View
4 ext/sqlite/tests/sqlite_024.phpt
@@ -29,13 +29,13 @@ foreach ($data as $str) {
echo "====class24====\n";
$res = sqlite_query($db, "SELECT a FROM strings", SQLITE_ASSOC);
-while (sqlite_has_more($res)) {
+while (sqlite_valid($res)) {
var_dump(sqlite_fetch_object($res, 'class24'));
}
echo "====stdclass====\n";
$res = sqlite_query($db, "SELECT a FROM strings", SQLITE_ASSOC);
-while (sqlite_has_more($res)) {
+while (sqlite_valid($res)) {
var_dump(sqlite_fetch_object($res));
}

0 comments on commit 6b0f57e

Please sign in to comment.