summaryrefslogtreecommitdiffstats
path: root/generic/tclInt.h
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2022-03-16 23:08:28 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2022-03-16 23:08:28 (GMT)
commit17098d70c767e79c2deb65981af371cb209cd159 (patch)
treee7f309ada6cf0f56695900638d4b6015bb5269b1 /generic/tclInt.h
parent459642686539ca9da0448167dbbf7fef7435f864 (diff)
downloadtcl-17098d70c767e79c2deb65981af371cb209cd159.zip
tcl-17098d70c767e79c2deb65981af371cb209cd159.tar.gz
tcl-17098d70c767e79c2deb65981af371cb209cd159.tar.bz2
Handle Tcl_UtfAtIndex
Diffstat (limited to 'generic/tclInt.h')
-rw-r--r--generic/tclInt.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/generic/tclInt.h b/generic/tclInt.h
index 2d828e8..0705c1d 100644
--- a/generic/tclInt.h
+++ b/generic/tclInt.h
@@ -3327,6 +3327,7 @@ MODULE_SCOPE int TclZipfs_Init(Tcl_Interp *interp);
MODULE_SCOPE int TclUniCharNcasecmp(const int *, const int *, unsigned long);
MODULE_SCOPE int TclUniCharCaseMatch(const int *, const int *, int);
MODULE_SCOPE int TclUniCharNcmp(const int *, const int *, unsigned long);
+ MODULE_SCOPE const char *TclUtfAtIndex(const char *, int);
#else
# define TclGetUnicodeFromObj_ Tcl_GetUnicodeFromObj
# define TclNewUnicodeObj Tcl_NewUnicodeObj
@@ -3335,6 +3336,7 @@ MODULE_SCOPE int TclZipfs_Init(Tcl_Interp *interp);
# define TclUniCharNcasecmp Tcl_UniCharNcasecmp
# define TclUniCharCaseMatch Tcl_UniCharCaseMatch
# define TclUniCharNcmp Tcl_UniCharNcmp
+# define TclUtfAtIndex Tcl_UtfAtIndex
#endif
@@ -4741,8 +4743,8 @@ MODULE_SCOPE const TclFileAttrProcs tclpFileAttrProcs[];
: Tcl_UtfToUniChar(str, chPtr))
#else
#define TclUtfToUniChar(str, chPtr) \
- ((((unsigned char) *(str)) < 0x80) ? \
- ((*(chPtr) = (unsigned char) *(str)), 1) \
+ (((UCHAR(*(str))) < 0x80) ? \
+ ((*(chPtr) = UCHAR(*(str))), 1) \
: Tcl_UtfToChar16(str, chPtr))
#endif