Hi All,
I wanted to share a little bit of knowledge I figured out. I could be silly for even posting this but I've been playing around with C, creating several projects for fun. When working with strings I had been using:
STRPTR = "Insert Text here";
But this will throw a compiler error:
app.c:###: warning: initialization discards qualifiers from pointer target type
What I learned is the right way to do this is to use
CONST_STRPTR = "Insert Text here";
If your a newbie like me this might help if you need to create any string constances in your projects.
Cheers,
Bill "tekmage" Borsari
And - as always - it helps to have no typos in your code! (Spotted, anyone?) :-) Nevertheless I'm a C newbie as well, so any tips like this are very helpful and welcome! Thanks!
X1000|II/G4|440ep|2000/060|2000/040|1000
STRPRT but maybe is only a typo..
Thanks! fixed that bug and added line termination ;)
Nice.
Don't we usually add a name when declaring variables/constants?
CONST_STRPTR mytext = "Insert Text here";
Otherwise it's hard to make references to it later.
Merry Christmas
:)
LyleHaze