Yes, that's the behavior I intended (and the behavior the internal
code relies upon).  From Rexx code, the only mechanism that exists for
returning nothing is .nil....but .nil is also an object that can be
stored in a directory.  Returning NULL for the native APIs
disambiguates those two cases.  This will be true for the other
collections as well.  And also for things like GetContextVariable()
and GetObjectVariable(), rather than return the string value of the
name, NULLOBJECT will be returned to more easily check if the variable
has been set.

Rick

Rick

On Tue, Jul 29, 2008 at 3:52 PM, Mark Miesfeld <[EMAIL PROTECTED]> wrote:
> In the new native API this code:
>
> RexxObjectPtr o = context->DirectoryAt(constDir, symbol);
>
> returns NULLOBJECT when the RexxDirectoryObject 'constDir' does not
> have the index 'symbol'
>
> I expected it to return context->Nil().
>
> Returning NULL in the native API is fine for the DirectoryAt() method,
> it is easier to test for NULL than context->Nil().  I just wanted to
> check that this is the expected behavior.
>
> --
> Mark Miesfeld
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> Oorexx-devel mailing list
> Oorexx-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/oorexx-devel
>

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel

Reply via email to