diff options
author | Pablo Galindo <Pablogsal@gmail.com> | 2021-05-19 18:10:23 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-19 18:10:23 (GMT) |
commit | 95d04710c5fb0df5393b5add2c5c2de2412673eb (patch) | |
tree | 4ddc67c01e56a361490b0c8cb36e619bd0aa3eee /config.guess | |
parent | be93f81e58ba3742589259ef84325a95b547e424 (diff) | |
download | cpython-95d04710c5fb0df5393b5add2c5c2de2412673eb.zip cpython-95d04710c5fb0df5393b5add2c5c2de2412673eb.tar.gz cpython-95d04710c5fb0df5393b5add2c5c2de2412673eb.tar.bz2 |
Fix compiler warning for misleading guarding in the tkinter (GH-26244)
The newest gcc emmits this warning:
```
/Modules/_tkinter.c:272:9: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
272 | if(tcl_lock)PyThread_acquire_lock(tcl_lock, 1); tcl_tstate = tstate; }
| ^~
/Modules/_tkinter.c:2869:5: note: in expansion of macro ‘LEAVE_PYTHON’
2869 | LEAVE_PYTHON
| ^~~~~~~~~~~~
/Modules/_tkinter.c:243:5: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
243 | (*(PyThreadState**)Tcl_GetThreadData(&state_key, sizeof(PyThreadState*)))
| ^
/Modules/_tkinter.c:272:57: note: in expansion of macro ‘tcl_tstate’
272 | if(tcl_lock)PyThread_acquire_lock(tcl_lock, 1); tcl_tstate = tstate; }
| ^~~~~~~~~~
/Modules/_tkinter.c:2869:5: note: in expansion of macro ‘LEAVE_PYTHON’
2869 | LEAVE_PYTHON
```
that's because the macro packs together two statements at the same level
as the "if". The warning is misleading but is very noisy so it makes
sense to fix it.
Diffstat (limited to 'config.guess')
0 files changed, 0 insertions, 0 deletions