diff options
| author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-08-11 05:39:08 (GMT) |
|---|---|---|
| committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-08-11 05:39:08 (GMT) |
| commit | d73c6dbd81c0537e3d6df60dc145af1b6539d6d2 (patch) | |
| tree | 21937654dd120ae841ab47a05d1d792b30ffc187 /generic/tclObj.c | |
| parent | 36d06e1e0b240999e478c750f746a86dbd63caae (diff) | |
| download | tcl-d73c6dbd81c0537e3d6df60dc145af1b6539d6d2.zip tcl-d73c6dbd81c0537e3d6df60dc145af1b6539d6d2.tar.gz tcl-d73c6dbd81c0537e3d6df60dc145af1b6539d6d2.tar.bz2 | |
Eliminate many unnecessary type-casts, mostly (size_t) when value is already size_t or int
Diffstat (limited to 'generic/tclObj.c')
| -rw-r--r-- | generic/tclObj.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/generic/tclObj.c b/generic/tclObj.c index a4df3e7..28fb3da 100644 --- a/generic/tclObj.c +++ b/generic/tclObj.c @@ -2059,25 +2059,25 @@ ParseBoolean( /* * Checking the 'y' is redundant, but makes the code clearer. */ - if (strncmp(lowerCase, "yes", (size_t) length) == 0) { + if (strncmp(lowerCase, "yes", length) == 0) { newBool = 1; goto goodBoolean; } return TCL_ERROR; case 'n': - if (strncmp(lowerCase, "no", (size_t) length) == 0) { + if (strncmp(lowerCase, "no", length) == 0) { newBool = 0; goto goodBoolean; } return TCL_ERROR; case 't': - if (strncmp(lowerCase, "true", (size_t) length) == 0) { + if (strncmp(lowerCase, "true", length) == 0) { newBool = 1; goto goodBoolean; } return TCL_ERROR; case 'f': - if (strncmp(lowerCase, "false", (size_t) length) == 0) { + if (strncmp(lowerCase, "false", length) == 0) { newBool = 0; goto goodBoolean; } @@ -2086,10 +2086,10 @@ ParseBoolean( if (length < 2) { return TCL_ERROR; } - if (strncmp(lowerCase, "on", (size_t) length) == 0) { + if (strncmp(lowerCase, "on", length) == 0) { newBool = 1; goto goodBoolean; - } else if (strncmp(lowerCase, "off", (size_t) length) == 0) { + } else if (strncmp(lowerCase, "off", length) == 0) { newBool = 0; goto goodBoolean; } |
