diff options
author | oehhar <harald.oehlmann@elmicron.de> | 2014-05-29 14:53:45 (GMT) |
---|---|---|
committer | oehhar <harald.oehlmann@elmicron.de> | 2014-05-29 14:53:45 (GMT) |
commit | 99881838a7e2f2f15331858f6654beb534bfccc8 (patch) | |
tree | 9be3430887ad5943e0fe6308e10daaf21569c76a /generic/tclCmdMZ.c | |
parent | b5277efde02115a99b120d3a90fb1471c6aee409 (diff) | |
parent | d344208a62df4671dac9a66fa4589979bc68d7bb (diff) | |
download | tcl-99881838a7e2f2f15331858f6654beb534bfccc8.zip tcl-99881838a7e2f2f15331858f6654beb534bfccc8.tar.gz tcl-99881838a7e2f2f15331858f6654beb534bfccc8.tar.bz2 |
merge core-8-5-branch
Diffstat (limited to 'generic/tclCmdMZ.c')
-rw-r--r-- | generic/tclCmdMZ.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/generic/tclCmdMZ.c b/generic/tclCmdMZ.c index 6fd468c..70943e9 100644 --- a/generic/tclCmdMZ.c +++ b/generic/tclCmdMZ.c @@ -1345,7 +1345,7 @@ StringIndexCmd( * Unicode string rep to get the index'th char. */ - if (objv[1]->typePtr == &tclByteArrayType) { + if (TclIsPureByteArray(objv[1])) { const unsigned char *string = Tcl_GetByteArrayFromObj(objv[1], &length); @@ -2086,7 +2086,7 @@ StringRangeCmd( * Unicode string rep to get the range. */ - if (objv[1]->typePtr == &tclByteArrayType) { + if (TclIsPureByteArray(objv[1])) { string = Tcl_GetByteArrayFromObj(objv[1], &length); length--; } else { @@ -2537,8 +2537,8 @@ StringEqualCmd( return TCL_OK; } - if (!nocase && objv[0]->typePtr == &tclByteArrayType && - objv[1]->typePtr == &tclByteArrayType) { + if (!nocase && TclIsPureByteArray(objv[0]) && + TclIsPureByteArray(objv[1])) { /* * Use binary versions of comparisons since that won't cause undue * type conversions and it is much faster. Only do this if we're @@ -2684,8 +2684,8 @@ StringCmpCmd( return TCL_OK; } - if (!nocase && objv[0]->typePtr == &tclByteArrayType && - objv[1]->typePtr == &tclByteArrayType) { + if (!nocase && TclIsPureByteArray(objv[0]) && + TclIsPureByteArray(objv[1])) { /* * Use binary versions of comparisons since that won't cause undue * type conversions and it is much faster. Only do this if we're |