realbasic-plugins
[Top] [All Lists]

Re: Does REALUnlockObject work on a REALobjectArray?

To: REALbasic Plugins <realbasic-plugins at lists dot realsoftware dot com>
Subject: Re: Does REALUnlockObject work on a REALobjectArray?
From: Alfred Van Hoek <vanhoek at mac dot com>
Date: Mon, 30 Jan 2006 14:16:08 -0500
Delivered-to: realbasic-plugins at lists dot realsoftware dot com
References: <ea5840a251d79cca2705b7f4ac966092 at mac dot com> <849E1004-16A9-4F68-BA8E-564AB66858CD at realsoftware dot com> <e87d1e73e9aa8321062d259ece964a1d at mac dot com> <4CA159EC-7012-4D3E-B61B-22F99E051A91 at haranbanjo dot com> <4428b5baee037d0532d3629981ae3877 at great-white-software dot com> <9D3DF51C-D492-44E0-BCBA-D49E35890BD8 at haranbanjo dot com> <3374e0d5c70dd0dc88f836b2813a55ae at great-white-software dot com>

On Jan 30, 2006, at 1:17 PM, Norman Palardy wrote:

But I know you can't put arrays into arrays and variants cannot hold arrays so I think what he's after may simply not exist.


No, Given that the byref declaration: "Items(Byref vars() As MyVariant" is working as expected, i.e. We can get an array of type MyVariant (super = Object, not Variant), RB does not understand the declaration:

"Items() As MyVariant()". According to the LR the critical point is the "()" after the type declaration. RB does not parse correctly from such a declaration,

Nor does this lead to a valid function pointer:

REALobjectArray Dictionary_Values(REALobject self)
{
        static REALobjectArray (*_fp)(REALobject) = nil;
        if (!_fp)
_fp = (REALobjectArray(*)(REALobject))REALLoadObjectMethod(self, "Values() As Variant()");
        if (_fp)
                return _fp(self);
        return 0;
}

While using an unsupported entry point (I know, I shouldn't):

        if (!_fp)
_fp = (REALobjectArray(*)(REALobject))CallResolver("dictionaryValues");
        if (_fp)
                return _fp(self);

It returns a REALobjectArray, but wish I wouldn't need an entry point for this.


All I am hoping is a rapid release of a novel sdk to sanction locking and unlocking of a REALobjectArray (here I use unsupported entry points that show valid function pointers, and refCounts going up or down, but still a memory leak) in addition to the fix of the REALmethodDefinition parser...

Alfred

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>


<Prev in Thread] Current Thread [Next in Thread>