Overview
| Artifact ID: | d300e1dce470e1e06da9070f7b9aeffda1a041b84494ae08cdf3fcc70ec5dbd1 |
|---|---|
| Ticket: | aa6624c6292064e76efe93bfb810545a82ad1d3d
tclExecute.c: Avoid false-positive warning |
| User & Date: | chrstphrchvz on 2024-02-16 12:13:26 |
Changes
- comment changed to:
LLVM.org Clang 17 emits is a false positive <tt>-Wconstant-logical-operand</tt> warning when using <tt>-std=c2x</tt> (reported at [https://github.com/llvm/llvm-project/issues/64356]): <pre> tcl86/generic/tclExecute.c:9192:4: warning: use of logical '||' with constant operand [-Wconstant-logical-operand] 9192 | || (sizeof(Tcl_WideInt) < 2*sizeof(long))) { | ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ tcl86/generic/tclExecute.c:9192:4: note: use '|' for a bitwise operation 9192 | || (sizeof(Tcl_WideInt) < 2*sizeof(long))) { | ^~ | | </pre> This will be fixed in future Clang, but I would suggest reordering affected expressions as a workaround to avoid anyone else complaining about this. See attached patch. - login: "chrstphrchvz"
- mimetype: "text/plain"