1752777 Members
6082 Online
108789 Solutions
New Discussion

strcpy in Digital and HP

 
anup1890
Occasional Advisor

strcpy in Digital and HP

what is the significance of __restrict in strcpy and strncpy under HP UX

char *strcpy(char *__restrict s1, const char *__restrict s2);

char *strncpy(char *__restrict s1, const char *__restrict s2, size_t n);



In Digital machines it is
char *strcpy( char *s1,const char *s2);
char *strncpy(char *s1,const char *s2,size_t n);




1 REPLY 1
Dennis Handly
Acclaimed Contributor

Re: strcpy in Digital and HP

11.31 on Integrity supports the restrict keyword from the C99 Standard.
Basically the source and target mustn't overlap.