Gabriele Bartolini writes:
>
> I seem to remember that at first I made a comparison between a string and a
> char *. But later this has changed and the comparison was made between 2
> char pointers. It was obvious that the comparison never succeeded
> (logically speaking). It was very unlikely that 2 pointers were equal ... :-)
>
> Hope to have been clear ...
>
Yes. I strongly encourage you to use only String, not char*. Using
const objects and references, manipulating String instead of char* is
much safer and only occupies 4-8 bytes in addition to the string (length +
pre-allocate). Since it often saves unecessary strlen you may even win
performances.
A tempting but long taks would be to eliminate completely char* from
htdig, except for library calls. Encapsulate all str* functions in the
String class. And this will prepare the ground for Unicode ... maybe.
Cheers,
--
Loic Dachary
ECILA
100 av. du Gal Leclerc
93500 Pantin - France
Tel: 33 1 56 96 10 85
e-mail: [EMAIL PROTECTED]
URL: http://www.senga.org/
------------------------------------
To unsubscribe from the htdig3-dev mailing list, send a message to
[EMAIL PROTECTED] containing the single word "unsubscribe" in
the SUBJECT of the message.