comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Where
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: WHERE [message #73370 is a reply to message #63098] Fri, 05 November 2010 08:20 Go to previous messageGo to previous message
penteado is currently offline  penteado
Messages: 866
Registered: February 2018
Senior Member
Administrator
On Nov 5, 11:44 am, Paul <paulsta...@gmail.com> wrote:
> Now that -1 is a valid array index, does it make sense for WHERE to
> return it as a null result?

This was discussed at length last year, before the choices in 8.0 were
made. It absolutely has to keep returning -1 if called the same way,
or it would break a lot of old code - many tests are made comparing
the result with -1, instead of using the count argument. Living with
the consequences of the past, as David said.

New code can make use of the (new, obviously) null keyword, that makes
it return !null instead of -1. And the use of !null as index was made
to go nicely with that, so that doing assigning with a !null index
does nothing, with no errors, and retrieving with a !null index
returns !null, also with no errors.
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: a question regarding idl path
Next Topic: Re: expanded 2d matching

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 14:11:21 PDT 2025

Total time taken to generate the page: 0.00254 seconds