it is NOT supported in standard C. this is: char a[10]="bbbb";
which makes an array on stack and fills it with ['b' 'b' 'b' 'b' 0 0 0 0 0 0] or char* a="bbbb" which makes a pointer on stack that points to a string stored in the global data section of the app, like this: a --> ['b' 'b' 'b' 'b' 0] On 11/22/06, victorp king <[EMAIL PROTECTED]> wrote:
another question about string op. code like below can't pass the compile, i want to know why? char a[10]; a = "bbbb"; this is supported in standard C ,why can't work under palm sdk? 2006/11/23, victorp king <[EMAIL PROTECTED]>: > > what's the different between these three declaration sentence: > 1.char *a; > 2,char a[10]; > 3,char a[]; > > as my opion , the first one is just a pointer which can point any allcoated string value. > the sencond one , it dose get ten bytes,these bytes filled with '\0'. > the third one ,it should be the same as the first. > > is this right? > > > 2006/11/23, victorp king <[EMAIL PROTECTED]>: > > > > > > my simulator is ver 5.4 ,then everytime when i execute the line 'StrCat(label, label0);' which i try to concat two strings, simulator crashes. > > Dose anybody know the reason? > > -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/ > > > -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/ -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
-- Best Regards, Dmitry Grinberg Software Engineer, http://PalmPowerups.com (847) 226 9295 AIM: DmitryGrinberg MSN: [EMAIL PROTECTED] ICQ: 165589894 Y! IM: dmitrygr2003 -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
