Import Tcl 8.6.10

This commit is contained in:
Steve Dower
2020-09-24 22:53:56 +01:00
parent 0343d03b22
commit 3bb8e3e086
1005 changed files with 593700 additions and 41637 deletions

View File

@@ -613,7 +613,7 @@ Tcl_ParseCommand(
int
TclIsSpaceProc(
char byte)
int byte)
{
return CHAR_TYPE(byte) & (TYPE_SPACE) || byte == '\n';
}
@@ -642,7 +642,7 @@ TclIsSpaceProc(
int
TclIsBareword(
char byte)
int byte)
{
if (byte < '0' || byte > 'z') {
return 0;
@@ -844,7 +844,7 @@ TclParseBackslash(
Tcl_UniChar unichar = 0;
int result;
int count;
char buf[TCL_UTF_MAX];
char buf[TCL_UTF_MAX] = "";
if (numBytes == 0) {
if (readPtr != NULL) {
@@ -991,7 +991,13 @@ TclParseBackslash(
if (readPtr != NULL) {
*readPtr = count;
}
return Tcl_UniCharToUtf(result, dst);
count = Tcl_UniCharToUtf(result, dst);
#if TCL_UTF_MAX > 3
if ((result >= 0xD800) && (count < 3)) {
count += Tcl_UniCharToUtf(-1, dst + count);
}
#endif
return count;
}
/*
@@ -2211,7 +2217,7 @@ TclSubstTokens(
Tcl_Obj *appendObj = NULL;
const char *append = NULL;
int appendByteLength = 0;
char utfCharBytes[TCL_UTF_MAX];
char utfCharBytes[TCL_UTF_MAX] = "";
switch (tokenPtr->type) {
case TCL_TOKEN_TEXT: