I believe that statics within the scope of a function are also not allowed.
That is:
void SomeFunction(int arg)
{
static int staticVarWithinFunctionScope;
staticVarWithinFunctionScope = arg;
}
When I execute the above code, when in a Palm OS Shared Library, it crashes my
Tungsten T.
Neil Whitworth <[EMAIL PROTECTED]> wrote:
>Paul Reger wrote:
>> I understand that we can not have Global Variables in a Palm OS Shared
>> Library. Are file statics allowed? How about function statics?
>>
>>
>Static Variables are Globals, that the compiler limits access to, so can
>not be used in a shared library.
>
>Static Functions are fine. In C they limit the scope of the function to
>that source file, so can not be called from another file.
>
>If you need to hold 'Global' data, you can store this in the fake
>globals handle that is generated for your project by CW. Look at the
>PrvLockGlobals function.
>
>> __________________________________________________________________
>> Switch to Netscape Internet Service.
>> As low as $9.95 a month -- Sign up today at http://isp.netscape.com/register
>>
>> Netscape. Just the Net You Need.
>>
>> New! Netscape Toolbar for Internet Explorer
>> Search from anywhere on the Web and block those annoying pop-ups.
>> Download now at http://channels.netscape.com/ns/search/install.jsp
>>
>
>--
>For information on using the PalmSource Developer Forums, or to unsubscribe,
>please see http://www.palmos.com/dev/support/forums/
>
--
Thanks,
Paul Reger
[EMAIL PROTECTED]
503.690.4669 (home)
503.880.7583 (cell)
__________________________________________________________________
Switch to Netscape Internet Service.
As low as $9.95 a month -- Sign up today at http://isp.netscape.com/register
Netscape. Just the Net You Need.
New! Netscape Toolbar for Internet Explorer
Search from anywhere on the Web and block those annoying pop-ups.
Download now at http://channels.netscape.com/ns/search/install.jsp
--
For information on using the PalmSource Developer Forums, or to unsubscribe,
please see http://www.palmos.com/dev/support/forums/