They are not allowed.
as mentioned all static variables are forbidden.
static functions (not static variables in a function) are ok.
Benoit
Paul Reger wrote:
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/
___________________________________________________________________________
Appel audio GRATUIT partout dans le monde avec le nouveau Yahoo! Messenger
Téléchargez cette version sur http://fr.messenger.yahoo.com
--
For information on using the PalmSource Developer Forums, or to unsubscribe,
please see http://www.palmos.com/dev/support/forums/