piclist 2002\08\19\105434a >
Thread: C-18 pointers to global variables...
www.piclist.com/techref/index.htm?key=pointers+global
flavicon
face BY : mikeEraseME@KILLspambroadcastwarehouse.com



Can anyone help me - I'm trying to pass a pointer to a large-ish (312)
element global array variable and am getting a suspicious pointer
conversion warning.

The global variable is assigned like this at the top of the file:

Pragma udata graphics=0x300
Static unsigned gphParameters[312];
Pragma udata

And further into the code I do the following:-

lcdDrawText(gphParameters,paramstr);

Where the function prototype looks like this:-

Void lcdDrawText(char *dest,char *src);

It has no problem when gphParameters is a local variable, and I have
tried declaring *dest as a FAR variable but it didn't work either.

The code does actually work - but I don't like warnings!!

Best regards,

Mike Griffin.

--
http://www.piclist.com hint: To leave the PICList
spam_OUTpiclist-unsubscribe-requestSTOPspamspamspamBeGonemitvma.mit.edu


<000b01c2478e$210614d0$10fea8c0@mike> 7bit

In reply to: <008e01c2478c$a3e9d780$f6509ac8@brusque>
See also: www.piclist.com/techref/index.htm?key=pointers+global
Reply You must be a member of the piclist mailing list (not only a www.piclist.com member) to post to the piclist. This form requires JavaScript and a browser/email client that can handle form mailto: posts.
Subject (change) C-18 pointers to global variables...

month overview.

new search...