Re: Pointers as values. Was: Re: [Harbour] TMYSQLSERVER error ...

2008-06-25 Thread Viktor Szakáts
Okey. I had a similar feeling about it. Let's leave it then, and update the code to use EMPTY(). (Notice that this also means that _application code_ directly using these MySQL API calls will also need to be updated, since we will have to break compatibility.) Brgds, Viktor On Wed, Jun 25, 2008

Re: Pointers as values. Was: Re: [Harbour] TMYSQLSERVER error ...

2008-06-25 Thread Mindaugas Kavaliauskas
Szakáts Viktor wrote: One possible solution is to allow to compare pointers to zero using operators (p != 0, p = 0, p == 0, and even p > 0, p < 0). Comparison with any other values would return .F., also, maybe NIL should be also allowed in place of 0, and we may allow such construct too: IF p ;

Re: Pointers as values. Was: Re: [Harbour] TMYSQLSERVER error ...

2008-06-25 Thread Szakáts Viktor
Hi Przemek, Welcome back on board :) I hope you had a nice time. as .T., non-0, non-NIL and a NULL as .F., 0, NIL on .prg level. EMPTY() function can be used for such testes, f.e.: return iif( !empty(::nSocket), sqlGetErr(::nSocket), ; "No connection to ser

Re: Pointers as values. Was: Re: [Harbour] TMYSQLSERVER error ...

2008-06-25 Thread Przemyslaw Czerpak
On Wed, 25 Jun 2008, Szakáts Viktor wrote: Hi Viktor, > I'd prefer a solution which won't break existing > .prg level code, yet allows to switch from longs > to pointers on the .c level. > One possible solution is to allow to compare > pointers to zero using operators (p != 0, > p = 0, p == 0, an

Re: Pointers as values. Was: Re: [Harbour] TMYSQLSERVER error ...

2008-06-25 Thread Ernad Husremovic
Hi Victor, at moment, I am learning harbour through the conversion process of our clipper applications. I have tested mysql, because we have plan to change database backend with an standard RDBMS. You suggest changes in harbour core, which is at this moment beyond my competence :). Regards, E

Pointers as values. Was: Re: [Harbour] TMYSQLSERVER error ...

2008-06-24 Thread Szakáts Viktor
Hi Ernad, I'd prefer a solution which won't break existing .prg level code, yet allows to switch from longs to pointers on the .c level. One possible solution is to allow to compare pointers to zero using operators (p != 0, p = 0, p == 0, and even p > 0, p < 0). Comparison with any other values