mirror of
https://github.com/cc65/cc65.git
synced 2025-03-04 00:30:35 +00:00
Add stpcpy().
Like strcpy() but returning pointer to ending zero of copied string.
This commit is contained in:
parent
0541b65aa4
commit
581b79e0b9
@ -52,6 +52,7 @@ char* __fastcall__ strchr (const char* s, int c);
|
||||
int __fastcall__ strcmp (const char* s1, const char* s2);
|
||||
int __fastcall__ strcoll (const char* s1, const char* s2);
|
||||
char* __fastcall__ strcpy (char* dest, const char* src);
|
||||
char* __fastcall__ stpcpy (char* dest, const char* src);
|
||||
size_t __fastcall__ strcspn (const char* s1, const char* s2);
|
||||
char* __fastcall__ strerror (int errcode);
|
||||
size_t __fastcall__ strlen (const char* s);
|
||||
|
8
libsrc/common/stpcpy.c
Normal file
8
libsrc/common/stpcpy.c
Normal file
@ -0,0 +1,8 @@
|
||||
#include <string.h>
|
||||
|
||||
char * __fastcall__
|
||||
stpcpy (char * dst, const char * src)
|
||||
{
|
||||
strcpy (dst, src);
|
||||
return dst + strlen (src);
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user