FindValue return values

Ed Kleban Ed at Kleban.com
Wed Dec 21 01:44:21 CST 2005




On 12/21/05 1:27 AM, "Ruslan Zasukhin" <sunshine at public.kherson.ua> wrote:

> On 12/21/05 5:08 AM, "Ed Kleban" <Ed at Kleban.com> wrote:
> 
>> Well, the code check I put in to validate this just produced a counter
>> example proving that this is not in fact the case.
>> 
>> So... what should I conclude?  Is this a bug in Valentina?
> 
> Ed, 
> 
> Another advice. V4RB have a lots of examples.
> We have examples for sets also.
> 
> So you can take example, and correct 1-2 lines to get search similar to you.
> 
> Then you can EASY and CLEAR show us how to reproduce problem.
> 
> MAY BE you will find that you cannot reproduce in example, so this means bug
> can be in your code.
> 

That is very good advice.

Before I submit a bug to Mantis that is typically exactly what I would do:
Either make a small simple program that replicates the error, or if
necessary for a horrible bug slice away everything from my program until
nothing but the bug is left.

But I'm not at that point yet.  And my best guess right now is that there
are hundreds of calls where nil is returned properly and I just happen to
have one specific case I discovered in which nil is not returned but a
VArraySet with count=0 is returned.

Eventually I'll take the time to investigate more.  For right now I'm
offering a "first alert".  I may end up being incorrect.

In the meantime I have turned off breakpoints when this occurs but continue
to log them in my error log.  I'll have to revisit all of this code again
soon anyway in January if and when you start tinkering with
FindValueAsArraySet to take a VArraySet argument (and hopefully use it as an
ordered set).

I'll let you know more when I do.

Thanks
--Ed.





More information about the Valentina mailing list