realbasic-nug
[Top] [All Lists]

Re: Constructors for Modules

To: REALbasic Network Users Group <realbasic-nug at lists dot realsoftware dot com>
Subject: Re: Constructors for Modules
From: Will Leshner <leshner at ljug dot com>
Date: Wed, 30 Jul 2003 11:28:25 -0700
Ok. Too much C++ for me. Obviously that's not what my Think() method looks like. How about:

function Thing() as CThing
        if mThing = nil then mThing = new CThing
        return mThing
end function

That'll teach me not to do these things from (my poor) memory!

Will Leshner wrote:

function Thing() as CThing
    if not mThing then mThing = new CThing
    return mThing
end function




---
A searchable archive of this list is available at:
<http://support.realsoftware.com/listarchives/search.php>

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


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