mirror of
https://github.com/cc65/cc65.git
synced 2025-01-11 11:30:13 +00:00
Pass chars as ints
git-svn-id: svn://svn.cc65.org/cc65/trunk@2890 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
parent
e47ed98aa7
commit
9bf337a37b
@ -195,14 +195,14 @@ void SB_Copy (StrBuf* Target, const StrBuf* Source)
|
||||
|
||||
|
||||
|
||||
void SB_AppendChar (StrBuf* B, char C)
|
||||
void SB_AppendChar (StrBuf* B, int C)
|
||||
/* Append a character to a string buffer */
|
||||
{
|
||||
unsigned NewLen = B->Len + 1;
|
||||
if (NewLen > B->Allocated) {
|
||||
SB_Realloc (B, NewLen);
|
||||
}
|
||||
B->Buf[B->Len] = C;
|
||||
B->Buf[B->Len] = (char) C;
|
||||
B->Len = NewLen;
|
||||
}
|
||||
|
||||
@ -286,7 +286,7 @@ void SB_Slice (StrBuf* Target, const StrBuf* Source, unsigned Start, unsigned Le
|
||||
void SB_Move (StrBuf* Target, StrBuf* Source)
|
||||
/* Move the complete contents of Source to target. This will delete the old
|
||||
* contents of Target, and Source will be empty after the call.
|
||||
*/
|
||||
*/
|
||||
{
|
||||
/* Free the target string */
|
||||
if (Target->Buf) {
|
||||
|
@ -286,7 +286,7 @@ void SB_Copy (StrBuf* Target, const StrBuf* Source);
|
||||
/* Copy Source to Target, discarding the old contents of Target */
|
||||
#endif
|
||||
|
||||
void SB_AppendChar (StrBuf* B, char C);
|
||||
void SB_AppendChar (StrBuf* B, int C);
|
||||
/* Append a character to a string buffer */
|
||||
|
||||
void SB_AppendBuf (StrBuf* B, const char* S, unsigned Size);
|
||||
|
Loading…
x
Reference in New Issue
Block a user